Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
   
   package org.jibx.schema.org.opentravel._2012A.rail;
   
   import java.util.ArrayList;
   import java.util.List;
The Rail Shop response message contains pricing and availability details for the requested search criteria, including origin/ destination location, accommodations and departure/ return dates and times. For each specified O/D pair, train options may be specified that include: - Origin/Destination location code and optional code context - Journey segment availability detail information, which may be for a train or a bus segment, and includes: Specific inventory-controlled service class code or detailed accommodation information Class and passenger type fares Other service-related information including reservation class, reservation type, different class codes and auto train vehicle type Pricing details may be specified at the origin/ destination pair and/ or segment level, and include basic fare, alternate currency with exchange rate details, terms and conditions, adjustments, discounts, fees, taxes and ancillary charges. Developer Notes: ยป This message may also include Warnings from business processing rules or Errors if the request did not succeed. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="OTA_RailShopRS">
   <xs:complexType>
     <xs:choice>
       <xs:sequence>
         <xs:element type="ns:SuccessType" name="Success"/>
         <xs:element type="ns:WarningsType" name="Warnings" minOccurs="0"/>
         <xs:element name="OriginDestinationInformation" minOccurs="0" maxOccurs="99">
           <!-- Reference to inner class OriginDestinationInformation -->
         </xs:element>
       </xs:sequence>
       <xs:element type="ns:ErrorsType" name="Errors"/>
     </xs:choice>
     <xs:attributeGroup ref="ns:OTA_PayloadStdAttributes"/>
   </xs:complexType>
 </xs:element>
 
  
  public class ShopRS
  {
      private int choiceSelect = -1;
      private static final int SUCCESS_CHOICE = 0;
      private static final int ERRORS_CHOICE = 1;
      private Success success;
      private Warnings warnings;
      private Errors errors;
  
      private void setChoiceSelect(int choice) {
          if ( == -1) {
               = choice;
          } else if ( != choice) {
              throw new IllegalStateException(
                      "Need to call clearChoiceSelect() before changing existing choice");
          }
      }

    
Clear the choice selection.
  
      public void clearChoiceSelect() {
           = -1;
      }

    
Check if Success is current selection for choice.

Returns:
true if selection, false if not
  
      public boolean ifSuccess() {
          return  == ;
      }

    
Get the 'Success' element value. An element that is not intended to contain any data. The mere presence of a success element within the response message indicates that the incoming request message was processed successfully.

Returns:
value
  
      public Success getSuccess() {
          return ;
      }

    
Set the 'Success' element value. An element that is not intended to contain any data. The mere presence of a success element within the response message indicates that the incoming request message was processed successfully.

Parameters:
success
 
     public void setSuccess(Success success) {
         this. = success;
     }

    
Get the 'Warnings' element value. Indicates that the recipient of the request message identified one or more business-level warnings/errors, but the message itself was successfully processed.

Returns:
value
 
     public Warnings getWarnings() {
         return ;
     }

    
Set the 'Warnings' element value. Indicates that the recipient of the request message identified one or more business-level warnings/errors, but the message itself was successfully processed.

Parameters:
warnings
 
     public void setWarnings(Warnings warnings) {
         this. = warnings;
     }

    
Get the list of 'OriginDestinationInformation' element items.

Returns:
list
 
         return ;
     }

    
Set the list of 'OriginDestinationInformation' element items.

Parameters:
list
 
             List<OriginDestinationInformationlist) {
          = list;
     }

    
Get the number of 'OriginDestinationInformation' element items.

Returns:
count
 
     public int sizeOriginDestinationInformationList() {
         return .size();
     }

    
Add a 'OriginDestinationInformation' element item.

Parameters:
item
 
     public void addOriginDestinationInformation(
             OriginDestinationInformation item) {
         .add(item);
     }

    
Get 'OriginDestinationInformation' element item by position.

Parameters:
index
Returns:
item
 
             int index) {
         return .get(index);
     }

    
Remove all 'OriginDestinationInformation' element items.
 
     public void clearOriginDestinationInformationList() {
     }

    
Check if Errors is current selection for choice.

Returns:
true if selection, false if not
 
     public boolean ifErrors() {
         return  == ;
     }

    
Get the 'Errors' element value. Indicates that an error occurred in the processing of the incoming request message. An error is defined as a malformed XML message that could not be processed.

Returns:
value
 
     public Errors getErrors() {
         return ;
     }

    
Set the 'Errors' element value. Indicates that an error occurred in the processing of the incoming request message. An error is defined as a malformed XML message that could not be processed.

Parameters:
errors
 
     public void setErrors(Errors errors) {
         setChoiceSelect();
         this. = errors;
     }

    
Get the 'OTA_PayloadStdAttributes' attributeGroup value.

Returns:
value
 
         return ;
     }

    
Set the 'OTA_PayloadStdAttributes' attributeGroup value.

Parameters:
OTAPayloadStdAttributes
 
     public void setOTAPayloadStdAttributes(
             OTAPayloadStdAttributes OTAPayloadStdAttributes) {
         this. = OTAPayloadStdAttributes;
     }
    
Information on the locations between which availability and pricing was requested. This provides for multiple origin/destination pairs in one request message. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="OriginDestinationInformation" minOccurs="0" maxOccurs="99">
   <xs:complexType>
     <xs:complexContent>
       <xs:extension base="ns:RailOriginDestinationInformationType">
         <xs:sequence>
           <xs:element name="OriginDestinationOption" maxOccurs="999">
             <!-- Reference to inner class OriginDestinationOption -->
           </xs:element>
         </xs:sequence>
       </xs:extension>
     </xs:complexContent>
   </xs:complexType>
 </xs:element>
 
 
     public static class OriginDestinationInformation
             extends
                 RailOriginDestinationInformation
     {
         private List<OriginDestinationOptionoriginDestinationOptionList = new ArrayList<OriginDestinationOption>();

        
Get the list of 'OriginDestinationOption' element items.

Returns:
list
 
             return ;
         }

        
Set the list of 'OriginDestinationOption' element items.

Parameters:
list
 
         public void setOriginDestinationOptionList(
                 List<OriginDestinationOptionlist) {
              = list;
         }

        
Get the number of 'OriginDestinationOption' element items.

Returns:
count
 
         public int sizeOriginDestinationOptionList() {
             return .size();
         }

        
Add a 'OriginDestinationOption' element item.

Parameters:
item
 
         public void addOriginDestinationOption(OriginDestinationOption item) {
             .add(item);
         }

        
Get 'OriginDestinationOption' element item by position.

Parameters:
index
Returns:
item
 
         public OriginDestinationOption getOriginDestinationOption(int index) {
             return .get(index);
         }

        
Remove all 'OriginDestinationOption' element items.
 
         public void clearOriginDestinationOptionList() {
             .clear();
         }
        
A collection of train options for the specified origin-destination pair. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="OriginDestinationOption" maxOccurs="999">
   <xs:complexType>
     <xs:sequence>
       <xs:element type="ns:LocationType" name="OriginLocation" minOccurs="0"/>
       <xs:element type="ns:LocationType" name="DestinationLocation" minOccurs="0"/>
       <xs:element name="JourneySegment" maxOccurs="10">
         <!-- Reference to inner class JourneySegment -->
       </xs:element>
       <xs:element type="ns:RailPriceType" name="Pricing" minOccurs="0" maxOccurs="99"/>
       <xs:element type="ns:WarningType" name="Remark" minOccurs="0" maxOccurs="5"/>
     </xs:sequence>
     <xs:attribute type="xs:date" use="optional" name="LastHoldDate"/>
     <xs:attribute type="xs:string" use="optional" name="JourneyDuration"/>
     <xs:attribute type="xs:boolean" use="optional" name="AlternativeInd"/>
   </xs:complexType>
 </xs:element>
 
 
         public static class OriginDestinationOption
         {
             private Location originLocation;
             private Location destinationLocation;
             private List<JourneySegmentjourneySegmentList = new ArrayList<JourneySegment>();
             private List<RailPricepricingList = new ArrayList<RailPrice>();
             private List<WarningremarkList = new ArrayList<Warning>();
             private LocalDate lastHoldDate;
             private String journeyDuration;
             private Boolean alternativeInd;

            
Get the 'OriginLocation' element value. The origin location code and optional code context.

Returns:
value
 
             public Location getOriginLocation() {
                 return ;
             }

            
Set the 'OriginLocation' element value. The origin location code and optional code context.

Parameters:
originLocation
 
             public void setOriginLocation(Location originLocation) {
                 this. = originLocation;
             }

            
Get the 'DestinationLocation' element value. The destination location code and optional code context.

Returns:
value
 
             public Location getDestinationLocation() {
                 return ;
             }

            
Set the 'DestinationLocation' element value. The destination location code and optional code context.

Parameters:
destinationLocation
 
             public void setDestinationLocation(Location destinationLocation) {
                 this. = destinationLocation;
             }

            
Get the list of 'JourneySegment' element items.

Returns:
list
 
             public List<JourneySegmentgetJourneySegmentList() {
                 return ;
             }

            
Set the list of 'JourneySegment' element items.

Parameters:
list
 
             public void setJourneySegmentList(List<JourneySegmentlist) {
                  = list;
             }

            
Get the number of 'JourneySegment' element items.

Returns:
count
 
             public int sizeJourneySegmentList() {
                 return .size();
             }

            
Add a 'JourneySegment' element item.

Parameters:
item
 
             public void addJourneySegment(JourneySegment item) {
                 .add(item);
             }

            
Get 'JourneySegment' element item by position.

Parameters:
index
Returns:
item
 
             public JourneySegment getJourneySegment(int index) {
                 return .get(index);
             }

            
Remove all 'JourneySegment' element items.
 
             public void clearJourneySegmentList() {
                 .clear();
             }

            
Get the list of 'Pricing' element items. Pricing details for one origin/ destination pair, including basic fare, alternate currency with exchange rate details, terms and conditions, adjustments, discounts, fees, taxes and ancillary charges.

Returns:
list
 
             public List<RailPricegetPricingList() {
                 return ;
             }

            
Set the list of 'Pricing' element items. Pricing details for one origin/ destination pair, including basic fare, alternate currency with exchange rate details, terms and conditions, adjustments, discounts, fees, taxes and ancillary charges.

Parameters:
list
 
             public void setPricingList(List<RailPricelist) {
                  = list;
             }

            
Get the number of 'Pricing' element items.

Returns:
count
 
             public int sizePricingList() {
                 return .size();
             }

            
Add a 'Pricing' element item.

Parameters:
item
 
             public void addPricing(RailPrice item) {
                 .add(item);
             }

            
Get 'Pricing' element item by position.

Parameters:
index
Returns:
item
 
             public RailPrice getPricing(int index) {
                 return .get(index);
             }

            
Remove all 'Pricing' element items.
 
             public void clearPricingList() {
                 .clear();
             }

            
Get the list of 'Remark' element items. Remarks about the specified origin-destination pair.

Returns:
list
 
             public List<WarninggetRemarkList() {
                 return ;
             }

            
Set the list of 'Remark' element items. Remarks about the specified origin-destination pair.

Parameters:
list
 
             public void setRemarkList(List<Warninglist) {
                  = list;
             }

            
Get the number of 'Remark' element items.

Returns:
count
 
             public int sizeRemarkList() {
                 return .size();
             }

            
Add a 'Remark' element item.

Parameters:
item
 
             public void addRemark(Warning item) {
                 .add(item);
             }

            
Get 'Remark' element item by position.

Parameters:
index
Returns:
item
 
             public Warning getRemark(int index) {
                 return .get(index);
             }

            
Remove all 'Remark' element items.
 
             public void clearRemarkList() {
                 .clear();
             }

            
Get the 'LastHoldDate' attribute value. The last date after which the priced journey will be cancelled if not ticketed.

Returns:
value
 
             public LocalDate getLastHoldDate() {
                 return ;
             }

            
Set the 'LastHoldDate' attribute value. The last date after which the priced journey will be cancelled if not ticketed.

Parameters:
lastHoldDate
 
             public void setLastHoldDate(LocalDate lastHoldDate) {
                 this. = lastHoldDate;
             }

            
Get the 'JourneyDuration' attribute value. The duration of the journey plus stop over time.

Returns:
value
 
             public String getJourneyDuration() {
                 return ;
             }

            
Set the 'JourneyDuration' attribute value. The duration of the journey plus stop over time.

Parameters:
journeyDuration
 
             public void setJourneyDuration(String journeyDuration) {
                 this. = journeyDuration;
             }

            
Get the 'AlternativeInd' attribute value. When TRUE, indicates that the returned journey was not the same as the requested journey.

Returns:
value
 
             public Boolean getAlternativeInd() {
                 return ;
             }

            
Set the 'AlternativeInd' attribute value. When TRUE, indicates that the returned journey was not the same as the requested journey.

Parameters:
alternativeInd
 
             public void setAlternativeInd(Boolean alternativeInd) {
                 this. = alternativeInd;
             }
            
Journey Segment information which may be a train or a bus segment. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="JourneySegment" maxOccurs="10">
   <xs:complexType>
     <xs:sequence>
       <xs:element name="AvailabilityDetail" minOccurs="0" maxOccurs="99">
         <!-- Reference to inner class AvailabilityDetail -->
       </xs:element>
       <xs:choice>
         <xs:element name="TrainSegment" minOccurs="0">
           <!-- Reference to inner class TrainSegment -->
         </xs:element>
         <xs:element name="BusSegment" minOccurs="0">
           <!-- Reference to inner class BusSegment -->
         </xs:element>
       </xs:choice>
     </xs:sequence>
   </xs:complexType>
 </xs:element>
 
 
             public static class JourneySegment
             {
                 private List<AvailabilityDetailavailabilityDetailList = new ArrayList<AvailabilityDetail>();
                 private int choiceSelect = -1;
                 private static final int TRAIN_SEGMENT_CHOICE = 0;
                 private static final int BUS_SEGMENT_CHOICE = 1;
                 private TrainSegment trainSegment;
                 private BusSegment busSegment;

                
Get the list of 'AvailabilityDetail' element items.

Returns:
list
 
                 public List<AvailabilityDetailgetAvailabilityDetailList() {
                     return ;
                 }

                
Set the list of 'AvailabilityDetail' element items.

Parameters:
list
 
                 public void setAvailabilityDetailList(
                         List<AvailabilityDetaillist) {
                      = list;
                 }

                
Get the number of 'AvailabilityDetail' element items.

Returns:
count
 
                 public int sizeAvailabilityDetailList() {
                     return .size();
                 }

                
Add a 'AvailabilityDetail' element item.

Parameters:
item
 
                 public void addAvailabilityDetail(AvailabilityDetail item) {
                     .add(item);
                 }

                
Get 'AvailabilityDetail' element item by position.

Parameters:
index
Returns:
item
 
                 public AvailabilityDetail getAvailabilityDetail(int index) {
                     return .get(index);
                 }

                
Remove all 'AvailabilityDetail' element items.
 
                 public void clearAvailabilityDetailList() {
                     .clear();
                 }
 
                 private void setChoiceSelect(int choice) {
                     if ( == -1) {
                          = choice;
                     } else if ( != choice) {
                         throw new IllegalStateException(
                                 "Need to call clearChoiceSelect() before changing existing choice");
                     }
                 }

                
Clear the choice selection.
 
                 public void clearChoiceSelect() {
                      = -1;
                 }

                
Check if TrainSegment is current selection for choice.

Returns:
true if selection, false if not
 
                 public boolean ifTrainSegment() {
                     return  == ;
                 }

                
Get the 'TrainSegment' element value.

Returns:
value
 
                 public TrainSegment getTrainSegment() {
                     return ;
                 }

                
Set the 'TrainSegment' element value.

Parameters:
trainSegment
 
                 public void setTrainSegment(TrainSegment trainSegment) {
                     setChoiceSelect();
                     this. = trainSegment;
                 }

                
Check if BusSegment is current selection for choice.

Returns:
true if selection, false if not
 
                 public boolean ifBusSegment() {
                     return  == ;
                 }

                
Get the 'BusSegment' element value.

Returns:
value
 
                 public BusSegment getBusSegment() {
                     return ;
                 }

                
Set the 'BusSegment' element value.

Parameters:
busSegment
 
                 public void setBusSegment(BusSegment busSegment) {
                     setChoiceSelect();
                     this. = busSegment;
                 }
                
Specific inventory-controlled service class code or detailed accommodation information, class and passenger type fares, and other service-related information including reservation class, reservation type, different class codes and auto train vehicle type. This information collectively represents one or more specific classes of service, such as "First class" and/or a seat and berth accommodation. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="AvailabilityDetail" minOccurs="0" maxOccurs="99">
   <xs:complexType>
     <xs:sequence>
       <xs:element type="ns:RailPriceType" name="Pricing" minOccurs="0"/>
       <xs:element type="ns:ClassCodeType" name="ClassCode" minOccurs="0"/>
       <xs:element type="xs:string" name="Reference" minOccurs="0"/>
       <xs:element name="Accommodation" minOccurs="0">
         <!-- Reference to inner class Accommodation -->
       </xs:element>
       <xs:element ref="ns:AncillaryService" minOccurs="0"/>
     </xs:sequence>
     <xs:attribute type="xs:string" use="optional" name="ReservationClass"/>
     <xs:attribute use="optional" name="ReservationType">
       <xs:simpleType>
         <!-- Reference to inner class Reservation -->
       </xs:simpleType>
     </xs:attribute>
     <xs:attribute type="xs:string" use="optional" name="VehicleType"/>
     <xs:attribute type="xs:boolean" use="optional" name="IsBicycleInd"/>
     <xs:attribute type="xs:boolean" use="optional" name="AlternativeInd"/>
   </xs:complexType>
 </xs:element>
 
 
                 public static class AvailabilityDetail
                 {
                     private RailPrice pricing;
                     private ClassCode classCode;
                     private String reference;
                     private Accommodation accommodation;
                     private AncillaryService ancillaryService;
                     private String reservationClass;
                     private Reservation reservation;
                     private String vehicle;
                     private Boolean isBicycleInd;
                     private Boolean alternativeInd;

                    
Get the 'Pricing' element value. Pricing details for one origin/ destination pair, including basic fare, alternate currency with exchange rate details, terms and conditions, adjustments, discounts, fees, taxes and ancillary charges.

Returns:
value
 
                     public RailPrice getPricing() {
                         return ;
                     }

                    
Set the 'Pricing' element value. Pricing details for one origin/ destination pair, including basic fare, alternate currency with exchange rate details, terms and conditions, adjustments, discounts, fees, taxes and ancillary charges.

Parameters:
pricing
 
                     public void setPricing(RailPrice pricing) {
                         this. = pricing;
                     }

                    
Get the 'ClassCode' element value. The class of inventory controlled services available.

Returns:
value
 
                     public ClassCode getClassCode() {
                         return ;
                     }

                    
Set the 'ClassCode' element value. The class of inventory controlled services available.

Parameters:
classCode
 
                     public void setClassCode(ClassCode classCode) {
                         this. = classCode;
                     }

                    
Get the 'Reference' element value. A reference code for the available service(s) returned in this message that may be used in a booking message. This is used as a reference number in the booking request so availability service details do not need to be replicated in the booking request message.

Returns:
value
 
                     public String getReference() {
                         return ;
                     }

                    
Set the 'Reference' element value. A reference code for the available service(s) returned in this message that may be used in a booking message. This is used as a reference number in the booking request so availability service details do not need to be replicated in the booking request message.

Parameters:
reference
 
                     public void setReference(String reference) {
                         this. = reference;
                     }

                    
Get the 'Accommodation' element value.

Returns:
value
 
                     public Accommodation getAccommodation() {
                         return ;
                     }

                    
Set the 'Accommodation' element value.

Parameters:
accommodation
 
                     public void setAccommodation(Accommodation accommodation) {
                         this. = accommodation;
                     }

                    
Get the 'AncillaryService' element value.

Returns:
value
 
                     public AncillaryService getAncillaryService() {
                         return ;
                     }

                    
Set the 'AncillaryService' element value.

Parameters:
ancillaryService
 
                     public void setAncillaryService(
                             AncillaryService ancillaryService) {
                         this. = ancillaryService;
                     }

                    
Get the 'ReservationClass' attribute value. Specifies class, such as Coach, Premium and Sleeper.

Returns:
value
 
                     public String getReservationClass() {
                         return ;
                     }

                    
Set the 'ReservationClass' attribute value. Specifies class, such as Coach, Premium and Sleeper.

Parameters:
reservationClass
 
                     public void setReservationClass(String reservationClass) {
                         this. = reservationClass;
                     }

                    
Get the 'ReservationType' attribute value. Specifies if the class code is reserved or unreserved.

Returns:
value
 
                     public Reservation getReservation() {
                         return ;
                     }

                    
Set the 'ReservationType' attribute value. Specifies if the class code is reserved or unreserved.

Parameters:
reservation
 
                     public void setReservation(Reservation reservation) {
                         this. = reservation;
                     }

                    
Get the 'VehicleType' attribute value. The vehicle type for autotrains, such as a Channel Tunnel, including car, van, motorcycle, etc.

Returns:
value
 
                     public String getVehicle() {
                         return ;
                     }

                    
Set the 'VehicleType' attribute value. The vehicle type for autotrains, such as a Channel Tunnel, including car, van, motorcycle, etc.

Parameters:
vehicle
 
                     public void setVehicle(String vehicle) {
                         this. = vehicle;
                     }

                    
Get the 'IsBicycleInd' attribute value. When true, the class code is for a bicycle which many types of trains accommodate.

Returns:
value
 
                     public Boolean getIsBicycleInd() {
                         return ;
                     }

                    
Set the 'IsBicycleInd' attribute value. When true, the class code is for a bicycle which many types of trains accommodate.

Parameters:
isBicycleInd
 
                     public void setIsBicycleInd(Boolean isBicycleInd) {
                         this. = isBicycleInd;
                     }

                    
Get the 'AlternativeInd' attribute value. When true, the class code returned is different from the requested class code.

Returns:
value
 
                     public Boolean getAlternativeInd() {
                         return ;
                     }

                    
Set the 'AlternativeInd' attribute value. When true, the class code returned is different from the requested class code.

Parameters:
alternativeInd
 
                     public void setAlternativeInd(Boolean alternativeInd) {
                         this. = alternativeInd;
                     }
                    
Type, class and compartment categories of train accommodations. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="Accommodation" minOccurs="0">
   <xs:complexType>
     <xs:complexContent>
       <xs:extension base="ns:AccommodationType">
         <xs:attribute type="xs:string" use="optional" name="Quantity"/>
       </xs:extension>
     </xs:complexContent>
   </xs:complexType>
 </xs:element>
 
 
                     public static class Accommodation
                             extends
                                 org.jibx.schema.org.opentravel._2012A.base.rail.Accommodation
                     {
                         private String quantity;

                        
Get the 'Quantity' attribute value. The quantity.

Returns:
value
 
                         public String getQuantity() {
                             return ;
                         }

                        
Set the 'Quantity' attribute value. The quantity.

Parameters:
quantity
 
                         public void setQuantity(String quantity) {
                             this. = quantity;
                         }
                     }
                    
Schema fragment(s) for this class:
 <xs:simpleType xmlns:xs="http://www.w3.org/2001/XMLSchema">
   <xs:restriction base="xs:string">
     <xs:enumeration value="Reservable"/>
     <xs:enumeration value="NotReservable"/>
   </xs:restriction>
 </xs:simpleType>
 
                    public static enum Reservation {
                        RESERVABLE("Reservable"), NOT_RESERVABLE(
                                "NotReservable");
                        private final String value;
                        private Reservation(String value) {
                            this. = value;
                        }
                        public String xmlValue() {
                            return ;
                        }
                        public static Reservation convert(String value) {
                            for (Reservation inst : values()) {
                                if (inst.xmlValue().equals(value)) {
                                    return inst;
                                }
                            }
                            return null;
                        }
                    }
                }
                
Train segment information. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="TrainSegment" minOccurs="0">
   <xs:complexType>
     <xs:complexContent>
       <xs:extension base="ns:TrainSegmentType">
         <xs:sequence>
           <xs:element type="ns:LocationType" name="TrainOrigin" minOccurs="0"/>
           <xs:element type="ns:LocationType" name="TrainDestination" minOccurs="0"/>
           <xs:element type="ns:RailAmenityType" name="RailAmenities" minOccurs="0"/>
           <xs:element type="ns:VendorMessagesType" name="VendorMessages" minOccurs="0"/>
           <xs:element name="Remarks" minOccurs="0">
             <!-- Reference to inner class Remarks -->
           </xs:element>
         </xs:sequence>
         <xs:attribute type="xs:float" use="optional" name="OnTimeRate"/>
         <xs:attribute type="xs:boolean" use="optional" name="AlternativeInd"/>
         <xs:attribute type="xs:boolean" use="optional" name="RestrictedServiceInd"/>
         <xs:attribute type="xs:boolean" use="optional" name="CancelledInd"/>
       </xs:extension>
     </xs:complexContent>
   </xs:complexType>
 </xs:element>
 
                public static class TrainSegment
                        extends
                            org.jibx.schema.org.opentravel._2012A.base.rail.TrainSegment
                {
                    private Location trainOrigin;
                    private Location trainDestination;
                    private RailAmenity railAmenities;
                    private VendorMessages vendorMessages;
                    private Remarks remarks;
                    private Float onTimeRate;
                    private Boolean alternativeInd;
                    private Boolean restrictedServiceInd;
                    private Boolean cancelledInd;

                    
Get the 'TrainOrigin' element value. Represents the start location of this train service.

Returns:
value
                    public Location getTrainOrigin() {
                        return ;
                    }

                    
Set the 'TrainOrigin' element value. Represents the start location of this train service.

Parameters:
trainOrigin
                    public void setTrainOrigin(Location trainOrigin) {
                        this. = trainOrigin;
                    }

                    
Get the 'TrainDestination' element value. Represents the final destination location of this train service.

Returns:
value
                    public Location getTrainDestination() {
                        return ;
                    }

                    
Set the 'TrainDestination' element value. Represents the final destination location of this train service.

Parameters:
trainDestination
                    public void setTrainDestination(Location trainDestination) {
                        this. = trainDestination;
                    }

                    
Get the 'RailAmenities' element value. A collection of preferred or offered rail amenities, including an amenity code, quantity and/or an associated preference level.

Returns:
value
                    public RailAmenity getRailAmenities() {
                        return ;
                    }

                    
Set the 'RailAmenities' element value. A collection of preferred or offered rail amenities, including an amenity code, quantity and/or an associated preference level.

Parameters:
railAmenities
                    public void setRailAmenities(RailAmenity railAmenities) {
                        this. = railAmenities;
                    }

                    
Get the 'VendorMessages' element value. A collection of special comments on the segment.

Returns:
value
                    public VendorMessages getVendorMessages() {
                        return ;
                    }

                    
Set the 'VendorMessages' element value. A collection of special comments on the segment.

Parameters:
vendorMessages
                    public void setVendorMessages(VendorMessages vendorMessages) {
                        this. = vendorMessages;
                    }

                    
Get the 'Remarks' element value.

Returns:
value
                    public Remarks getRemarks() {
                        return ;
                    }

                    
Set the 'Remarks' element value.

Parameters:
remarks
                    public void setRemarks(Remarks remarks) {
                        this. = remarks;
                    }

                    
Get the 'OnTimeRate' attribute value. Specifies the Dept. of Transport on time rate of the train.

Returns:
value
                    public Float getOnTimeRate() {
                        return ;
                    }

                    
Set the 'OnTimeRate' attribute value. Specifies the Dept. of Transport on time rate of the train.

Parameters:
onTimeRate
                    public void setOnTimeRate(Float onTimeRate) {
                        this. = onTimeRate;
                    }

                    
Get the 'AlternativeInd' attribute value. When true, indicates that the priced segment information returned was not the same as requested segment.

Returns:
value
                    public Boolean getAlternativeInd() {
                        return ;
                    }

                    
Set the 'AlternativeInd' attribute value. When true, indicates that the priced segment information returned was not the same as requested segment.

Parameters:
alternativeInd
                    public void setAlternativeInd(Boolean alternativeInd) {
                        this. = alternativeInd;
                    }

                    
Get the 'RestrictedServiceInd' attribute value. When true, indicates that this is a restricted service.

Returns:
value
                    public Boolean getRestrictedServiceInd() {
                        return ;
                    }

                    
Set the 'RestrictedServiceInd' attribute value. When true, indicates that this is a restricted service.

Parameters:
restrictedServiceInd
                    public void setRestrictedServiceInd(
                            Boolean restrictedServiceInd) {
                        this. = restrictedServiceInd;
                    }

                    
Get the 'CancelledInd' attribute value. When true, indicates that a segment has been cancelled.

Returns:
value
                    public Boolean getCancelledInd() {
                        return ;
                    }

                    
Set the 'CancelledInd' attribute value. When true, indicates that a segment has been cancelled.

Parameters:
cancelledInd
                    public void setCancelledInd(Boolean cancelledInd) {
                        this. = cancelledInd;
                    }
                    
A collection of remarks about the segment. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="Remarks" minOccurs="0">
   <xs:complexType>
     <xs:sequence>
       <xs:element type="ns:WarningType" name="Remark" maxOccurs="99"/>
     </xs:sequence>
   </xs:complexType>
 </xs:element>
 
                    public static class Remarks
                    {
                        private List<WarningremarkList = new ArrayList<Warning>();

                        
Get the list of 'Remark' element items. A remark about the segment.

Returns:
list
                        public List<WarninggetRemarkList() {
                            return ;
                        }

                        
Set the list of 'Remark' element items. A remark about the segment.

Parameters:
list
                        public void setRemarkList(List<Warninglist) {
                             = list;
                        }

                        
Get the number of 'Remark' element items.

Returns:
count
                        public int sizeRemarkList() {
                            return .size();
                        }

                        
Add a 'Remark' element item.

Parameters:
item
                        public void addRemark(Warning item) {
                            .add(item);
                        }

                        
Get 'Remark' element item by position.

Parameters:
index
Returns:
item
                        public Warning getRemark(int index) {
                            return .get(index);
                        }

                        
Remove all 'Remark' element items.
                        public void clearRemarkList() {
                            .clear();
                        }
                    }
                }
                
Bus segment information which may be hosted in the rail provider system or a code share. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="BusSegment" minOccurs="0">
   <xs:complexType>
     <xs:complexContent>
       <xs:extension base="ns:BusSegmentType">
         <xs:sequence>
           <xs:element name="ClassCodes" maxOccurs="99">
             <!-- Reference to inner class ClassCodes -->
           </xs:element>
           <xs:element name="Remarks" minOccurs="0">
             <!-- Reference to inner class Remarks -->
           </xs:element>
         </xs:sequence>
       </xs:extension>
     </xs:complexContent>
   </xs:complexType>
 </xs:element>
 
                public static class BusSegment
                        extends
                            org.jibx.schema.org.opentravel._2012A.base.rail.BusSegment
                {
                    private List<ClassCodesclassCodeList = new ArrayList<ClassCodes>();
                    private Remarks remarks;

                    
Get the list of 'ClassCodes' element items.

Returns:
list
                    public List<ClassCodesgetClassCodeList() {
                        return ;
                    }

                    
Set the list of 'ClassCodes' element items.

Parameters:
list
                    public void setClassCodeList(List<ClassCodeslist) {
                         = list;
                    }

                    
Get the number of 'ClassCodes' element items.

Returns:
count
                    public int sizeClassCodeList() {
                        return .size();
                    }

                    
Add a 'ClassCodes' element item.

Parameters:
item
                    public void addClassCode(ClassCodes item) {
                        .add(item);
                    }

                    
Get 'ClassCodes' element item by position.

Parameters:
index
Returns:
item
                    public ClassCodes getClassCode(int index) {
                        return .get(index);
                    }

                    
Remove all 'ClassCodes' element items.
                    public void clearClassCodeList() {
                        .clear();
                    }

                    
Get the 'Remarks' element value.

Returns:
value
                    public Remarks getRemarks() {
                        return ;
                    }

                    
Set the 'Remarks' element value.

Parameters:
remarks
                    public void setRemarks(Remarks remarks) {
                        this. = remarks;
                    }
                    
The class of inventory controlled services available. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="ClassCodes" maxOccurs="99">
   <xs:complexType>
     <xs:complexContent>
       <xs:extension base="ns:ClassCodeType">
         <xs:attribute type="xs:string" use="required" name="ReservationClass"/>
         <xs:attribute type="xs:string" use="required" name="ReservationType"/>
         <xs:attribute type="xs:string" use="optional" name="VehicleType"/>
         <xs:attribute type="xs:boolean" use="optional" name="AlternativeInd"/>
       </xs:extension>
     </xs:complexContent>
   </xs:complexType>
 </xs:element>
 
                    public static class ClassCodes extends ClassCode
                    {
                        private String reservationClass;
                        private String reservation;
                        private String vehicle;
                        private Boolean alternativeInd;

                        
Get the 'ReservationClass' attribute value. Specifies class, such as Coach, Premium and Sleeper.

Returns:
value
                        public String getReservationClass() {
                            return ;
                        }

                        
Set the 'ReservationClass' attribute value. Specifies class, such as Coach, Premium and Sleeper.

Parameters:
reservationClass
                        public void setReservationClass(String reservationClass) {
                            this. = reservationClass;
                        }

                        
Get the 'ReservationType' attribute value. Specifies the type of the reservation.

Returns:
value
                        public String getReservation() {
                            return ;
                        }

                        
Set the 'ReservationType' attribute value. Specifies the type of the reservation.

Parameters:
reservation
                        public void setReservation(String reservation) {
                            this. = reservation;
                        }

                        
Get the 'VehicleType' attribute value. Specifies the type of the vehicle or bus.

Returns:
value
                        public String getVehicle() {
                            return ;
                        }

                        
Set the 'VehicleType' attribute value. Specifies the type of the vehicle or bus.

Parameters:
vehicle
                        public void setVehicle(String vehicle) {
                            this. = vehicle;
                        }

                        
Get the 'AlternativeInd' attribute value. When true, this is an alternate form of transportation.

Returns:
value
                        public Boolean getAlternativeInd() {
                            return ;
                        }

                        
Set the 'AlternativeInd' attribute value. When true, this is an alternate form of transportation.

Parameters:
alternativeInd
                        public void setAlternativeInd(Boolean alternativeInd) {
                            this. = alternativeInd;
                        }
                    }
                    
Remarks about the bus segment. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="Remarks" minOccurs="0">
   <xs:complexType>
     <xs:sequence>
       <xs:element type="ns:WarningType" name="Remark" maxOccurs="99"/>
     </xs:sequence>
   </xs:complexType>
 </xs:element>
 
                    public static class Remarks
                    {
                        private List<WarningremarkList = new ArrayList<Warning>();

                        
Get the list of 'Remark' element items.

Returns:
list
                        public List<WarninggetRemarkList() {
                            return ;
                        }

                        
Set the list of 'Remark' element items.

Parameters:
list
                        public void setRemarkList(List<Warninglist) {
                             = list;
                        }

                        
Get the number of 'Remark' element items.

Returns:
count
                        public int sizeRemarkList() {
                            return .size();
                        }

                        
Add a 'Remark' element item.

Parameters:
item
                        public void addRemark(Warning item) {
                            .add(item);
                        }

                        
Get 'Remark' element item by position.

Parameters:
index
Returns:
item
                        public Warning getRemark(int index) {
                            return .get(index);
                        }

                        
Remove all 'Remark' element items.
                        public void clearRemarkList() {
                            .clear();
                        }
                    }
                }
            }
        }
    }