Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  
  package org.jibx.schema.org.opentravel._2012A.fastrez;
  
  import java.util.List;
The Availability Request message is used to request the availability of one or more hotel properties matching specified criteria. Either the HotelCode or the HotelCityCode MUST be provided to process the request. 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_HotelAvailRQ">
   <xs:complexType>
     <xs:sequence>
       <xs:element name="POS">
         <xs:complexType>
           <xs:sequence>
             <xs:element name="Source">
               <xs:complexType>
                 <xs:sequence>
                   <xs:element name="RequestorID">
                     <xs:complexType>
                       <xs:attribute type="xs:string" use="required" name="Type"/>
                       <xs:attribute type="xs:string" use="required" name="ID"/>
                       <xs:attribute type="xs:string" use="required" name="ID_Context"/>
                     </xs:complexType>
                   </xs:element>
                 </xs:sequence>
                 <xs:attribute type="xs:string" use="required" name="ISOCountry"/>
                 <xs:attribute type="xs:string" use="required" name="ISOCurrency"/>
               </xs:complexType>
             </xs:element>
           </xs:sequence>
         </xs:complexType>
       </xs:element>
       <xs:element name="AvailRequestSegments">
         <xs:complexType>
           <xs:sequence>
             <xs:element name="AvailRequestSegment">
               <xs:complexType>
                 <xs:sequence>
                   <xs:element name="HotelSearchCriteria">
                     <xs:complexType>
                       <xs:sequence>
                         <xs:element name="Criterion">
                           <xs:complexType>
                             <xs:sequence>
                               <xs:element name="HotelRef">
                                 <xs:complexType>
                                   <xs:attribute type="xs:string" use="optional" name="ChainCode"/>
                                   <xs:attribute type="xs:string" use="optional" name="BrandCode"/>
                                   <xs:attribute type="xs:string" use="optional" name="HotelCode"/>
                                   <xs:attribute type="xs:string" use="optional" name="HotelCityCode"/>
                                 </xs:complexType>
                               </xs:element>
                               <xs:element name="StayDateRange">
                                 <xs:complexType>
                                   <xs:attribute type="xs:string" use="required" name="Start"/>
                                   <xs:attribute type="xs:string" use="required" name="End"/>
                                 </xs:complexType>
                               </xs:element>
                               <xs:element name="RoomStayCandidates">
                                 <xs:complexType>
                                   <xs:sequence>
                                     <xs:element name="RoomStayCandidate">
                                       <xs:complexType>
                                         <xs:sequence>
                                           <xs:element name="GuestCounts">
                                             <xs:complexType>
                                               <xs:sequence>
                                                 <xs:element name="GuestCount" maxOccurs="10">
                                                   <!-- Reference to inner class GuestCount -->
                                                 </xs:element>
                                               </xs:sequence>
                                             </xs:complexType>
                                           </xs:element>
                                         </xs:sequence>
                                         <xs:attribute type="ns:ListOfOTA_CodeType" use="optional" name="BedTypeCode"/>
                                         <xs:attribute type="xs:boolean" use="optional" name="NonSmoking"/>
                                       </xs:complexType>
                                     </xs:element>
                                   </xs:sequence>
                                 </xs:complexType>
                               </xs:element>
                             </xs:sequence>
                           </xs:complexType>
                         </xs:element>
                       </xs:sequence>
                     </xs:complexType>
                   </xs:element>
                 </xs:sequence>
               </xs:complexType>
             </xs:element>
           </xs:sequence>
         </xs:complexType>
       </xs:element>
     </xs:sequence>
     <xs:attribute type="xs:string" use="optional" name="EchoToken"/>
     <xs:attribute type="xs:dateTime" use="required" name="TimeStamp"/>
     <xs:attribute type="xs:float" use="required" name="Version"/>
     <xs:attribute type="xs:string" use="required" name="PrimaryLangID"/>
     <xs:attribute type="xs:string" use="optional" name="MaxResponses"/>
   </xs:complexType>
 </xs:element>
 
 <xs:simpleType xmlns:ns="http://www.opentravel.org/OTA/2003/05" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="ListOfOTA_CodeType">
   <xs:list itemType="xs:string"/>
 </xs:simpleType>
 
public class HotelAvailRQ
    private String POSSourceRequestorID;
    private String POSSourceISOCountry;
    private String POSSourceISOCurrency;
    private String echoToken;
    private DateTime timeStamp;
    private Float version;
    private String primaryLangID;
    private String maxResponses;

    
Get the 'Type' attribute value. The Type identifies the ID and MUST refer to OpenTravel Code List Unique ID Type (UIT).

Returns:
value
        return ;
    }

    
Set the 'Type' attribute value. The Type identifies the ID and MUST refer to OpenTravel Code List Unique ID Type (UIT).

Parameters:
POSSourceRequestorIDType
    public void setPOSSourceRequestorIDType(String POSSourceRequestorIDType) {
         = POSSourceRequestorIDType;
    }

    
Get the 'ID' attribute value. ID MUST contain a unique identifying value for the requestor within the scope of the ID_Context.

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

    
Set the 'ID' attribute value. ID MUST contain a unique identifying value for the requestor within the scope of the ID_Context.

Parameters:
POSSourceRequestorIDID
    public void setPOSSourceRequestorIDID(String POSSourceRequestorIDID) {
        this. = POSSourceRequestorIDID;
    }

    
Get the 'ID_Context' attribute value. ID_Context MUST identify the authoritative source of the ID (e.g., IATA, ABTA).

Returns:
value
        return ;
    }

    
Set the 'ID_Context' attribute value. ID_Context MUST identify the authoritative source of the ID (e.g., IATA, ABTA).

Parameters:
POSSourceRequestorIDIDContext
            String POSSourceRequestorIDIDContext) {
        this. = POSSourceRequestorIDIDContext;
    }

    
Get the 'ISOCountry' attribute value. ISOCountry identifies the country code of the requesting party and MUST conform to ISO-3166. The country code of the requesting party MAY be used to refine responses therefore it SHOULD reflect the origin of the Guest.

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

    
Set the 'ISOCountry' attribute value. ISOCountry identifies the country code of the requesting party and MUST conform to ISO-3166. The country code of the requesting party MAY be used to refine responses therefore it SHOULD reflect the origin of the Guest.

Parameters:
POSSourceISOCountry
    public void setPOSSourceISOCountry(String POSSourceISOCountry) {
        this. = POSSourceISOCountry;
    }

    
Get the 'ISOCurrency' attribute value. ISOCurrency MUST conform to ISO 4217, 3 character codes. OpenTravel RECOMMENDS that the same currency code be used in the response, but responses MAY be returned in any valid currency.

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

    
Set the 'ISOCurrency' attribute value. ISOCurrency MUST conform to ISO 4217, 3 character codes. OpenTravel RECOMMENDS that the same currency code be used in the response, but responses MAY be returned in any valid currency.

Parameters:
POSSourceISOCurrency
    public void setPOSSourceISOCurrency(String POSSourceISOCurrency) {
        this. = POSSourceISOCurrency;
    }

    
Get the 'ChainCode' attribute value. The ChainCode MAY identify a hotel chain or management group (e.g. Hyatt, Hilton, Marriott). The hotel chain code is decided between vendors and is OPTIONAL if the hotel is an independent property that can be identified by the HotelCode attribute alone.

Returns:
value
    }

    
Set the 'ChainCode' attribute value. The ChainCode MAY identify a hotel chain or management group (e.g. Hyatt, Hilton, Marriott). The hotel chain code is decided between vendors and is OPTIONAL if the hotel is an independent property that can be identified by the HotelCode attribute alone.

Parameters:
availRequestSegmentsHotelRefChainCode
            String availRequestSegmentsHotelRefChainCode) {
        this. = availRequestSegmentsHotelRefChainCode;
    }

    
Get the 'BrandCode' attribute value. The BrandCode MAY identify the brand within a chain (e.g., Courtyard, Hampton Inn). This code is OPTIONAL if the hotel is an independent property that can be identified by the HotelCode attribute alone.

Returns:
value
    }

    
Set the 'BrandCode' attribute value. The BrandCode MAY identify the brand within a chain (e.g., Courtyard, Hampton Inn). This code is OPTIONAL if the hotel is an independent property that can be identified by the HotelCode attribute alone.

Parameters:
availRequestSegmentsHotelRefBrandCode
            String availRequestSegmentsHotelRefBrandCode) {
        this. = availRequestSegmentsHotelRefBrandCode;
    }

    
Get the 'HotelCode' attribute value. The HotelCode uniquely identifies a single hotel property for which the availability is to be performed. The HotelCode MAY be used in conjunction with the ChainCode and BrandCode in order to uniquely identify the hotel property. The hotel code is decided between vendors.

Returns:
value
    }

    
Set the 'HotelCode' attribute value. The HotelCode uniquely identifies a single hotel property for which the availability is to be performed. The HotelCode MAY be used in conjunction with the ChainCode and BrandCode in order to uniquely identify the hotel property. The hotel code is decided between vendors.

Parameters:
availRequestSegmentsHotelRefHotelCode
            String availRequestSegmentsHotelRefHotelCode) {
        this. = availRequestSegmentsHotelRefHotelCode;
    }

    
Get the 'HotelCityCode' attribute value. The HotelCityCode specifies the IATA city code (e.g. DCA, ORD LAX) for which the availability is to be performed.

Returns:
value
    }

    
Set the 'HotelCityCode' attribute value. The HotelCityCode specifies the IATA city code (e.g. DCA, ORD LAX) for which the availability is to be performed.

Parameters:
availRequestSegmentsHotelRefHotelCityCode
            String availRequestSegmentsHotelRefHotelCityCode) {
        this. = availRequestSegmentsHotelRefHotelCityCode;
    }

    
Get the 'Start' attribute value. Start MUST specify the arrival date for the availability request.

Returns:
value
    }

    
Set the 'Start' attribute value. Start MUST specify the arrival date for the availability request.

Parameters:
availRequestSegmentsStayDateRangeStart
            String availRequestSegmentsStayDateRangeStart) {
        this. = availRequestSegmentsStayDateRangeStart;
    }

    
Get the 'End' attribute value. End MUST specify the departure date for the availability request.

Returns:
value
    }

    
Set the 'End' attribute value. End MUST specify the departure date for the availability request.

Parameters:
availRequestSegmentsStayDateRangeEnd
            String availRequestSegmentsStayDateRangeEnd) {
        this. = availRequestSegmentsStayDateRangeEnd;
    }

    
Get the list of 'GuestCount' element items. GuestCounts contains a collection of GuestCount elements that MUST identify the number of guests for the availability request.

Returns:
list
    }

    
Set the list of 'GuestCount' element items. GuestCounts contains a collection of GuestCount elements that MUST identify the number of guests for the availability request.

Parameters:
list
            List<GuestCountlist) {
    }

    
Get the number of 'GuestCount' element items.

Returns:
count
    }

    
Add a 'GuestCount' element item.

Parameters:
item
            GuestCount item) {
    }

    
Get 'GuestCount' element item by position.

Parameters:
index
Returns:
item
            int index) {
    }

    
Remove all 'GuestCount' element items.
    }

    
Get the list of 'BedTypeCode' attribute items. The BedTypeCode MAY indicate the type of bed(s) for the availability request. Typical values include Double, Twin, Queen, or King. Refer to OpenTravel Code List Bed Type Code (BED).

Returns:
list
    }

    
Set the list of 'BedTypeCode' attribute items. The BedTypeCode MAY indicate the type of bed(s) for the availability request. Typical values include Double, Twin, Queen, or King. Refer to OpenTravel Code List Bed Type Code (BED).

Parameters:
list
            List<Stringlist) {
    }

    
Serializer for 'BedTypeCode' attribute list.

Parameters:
values
Returns:
text
            List<Stringvalues) {
        if (values == null) {
            return null;
        } else {
            java.lang.StringBuffer buff = new java.lang.StringBuffer();
            for (java.util.Iterator<Stringiter = values.iterator(); iter
                    .hasNext();) {
                if (buff.length() > 0) {
                    buff.append(' ');
                }
                String value = iter.next();
                buff.append(value);
            }
            return buff.toString();
        }
    }

    
Deserializer for 'BedTypeCode' attribute list.

Parameters:
text
Returns:
values
Throws:
org.jibx.runtime.JiBXException on conversion error
            String textthrows org.jibx.runtime.JiBXException {
            public java.lang.Object deserialize(String text) {
                return text;
            }
        };
        return (List<String>) org.jibx.runtime.Utility.deserializeList(text,
                ldser);
    }

    
Get the number of 'BedTypeCode' attribute items.

Returns:
count
    }

    
Add a 'BedTypeCode' attribute item.

Parameters:
item
    }

    
Get 'BedTypeCode' attribute item by position.

Parameters:
index
Returns:
item
    }

    
Remove all 'BedTypeCode' attribute items.
    }

    
Get the 'NonSmoking' attribute value. The non-smoking indicator, when true, indicates that only non-smoking rooms SHOULD be returned in the availability response.

Returns:
value
    }

    
Set the 'NonSmoking' attribute value. The non-smoking indicator, when true, indicates that only non-smoking rooms SHOULD be returned in the availability response.

Parameters:
availRequestSegmentsRoomStayCandidateNonSmoking
            Boolean availRequestSegmentsRoomStayCandidateNonSmoking) {
        this. = availRequestSegmentsRoomStayCandidateNonSmoking;
    }

    
Get the 'EchoToken' attribute value. EchoToken MAY provide a reference for additional message identification, assigned by the requesting host system. This attribute SHOULD NOT be used to maintain state, but SHOULD only be used for diagnostic purposes. When a request message includes an echo token the corresponding response message MUST include an echo token with an identical value.

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

    
Set the 'EchoToken' attribute value. EchoToken MAY provide a reference for additional message identification, assigned by the requesting host system. This attribute SHOULD NOT be used to maintain state, but SHOULD only be used for diagnostic purposes. When a request message includes an echo token the corresponding response message MUST include an echo token with an identical value.

Parameters:
echoToken
    public void setEchoToken(String echoToken) {
        this. = echoToken;
    }

    
Get the 'TimeStamp' attribute value. TimeStamp MUST indicate the creation date and time of the message in UTC using the following format specified by ISO 8601; YYYY-MM-DDThh:mm:ssZ with time values using the 24 hour clock (e.g. 20 November 2003, 1:59:38 pm UTC becomes 2003-11-20T13:59:38Z).

Returns:
value
    public DateTime getTimeStamp() {
        return ;
    }

    
Set the 'TimeStamp' attribute value. TimeStamp MUST indicate the creation date and time of the message in UTC using the following format specified by ISO 8601; YYYY-MM-DDThh:mm:ssZ with time values using the 24 hour clock (e.g. 20 November 2003, 1:59:38 pm UTC becomes 2003-11-20T13:59:38Z).

Parameters:
timeStamp
    public void setTimeStamp(DateTime timeStamp) {
        this. = timeStamp;
    }

    
Get the 'Version' attribute value. Version MUST be consistent with the underlying schema baseline.

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

    
Set the 'Version' attribute value. Version MUST be consistent with the underlying schema baseline.

Parameters:
version
    public void setVersion(Float version) {
        this. = version;
    }

    
Get the 'PrimaryLangID' attribute value. PrimaryLangID code MUST conform to ISO 639 language codes. The code MUST define the language of the request. FastRez RECOMMENDS that the response SHOULD match the request, but a response MAY use any language recognized by ISO 639.

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

    
Set the 'PrimaryLangID' attribute value. PrimaryLangID code MUST conform to ISO 639 language codes. The code MUST define the language of the request. FastRez RECOMMENDS that the response SHOULD match the request, but a response MAY use any language recognized by ISO 639.

Parameters:
primaryLangID
    public void setPrimaryLangID(String primaryLangID) {
        this. = primaryLangID;
    }

    
Get the 'MaxResponses' attribute value. MaxResponses MAY specify a positive integer value that indicates the maximum number of responses desired in the return.

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

    
Set the 'MaxResponses' attribute value. MaxResponses MAY specify a positive integer value that indicates the maximum number of responses desired in the return.

Parameters:
maxResponses
    public void setMaxResponses(String maxResponses) {
        this. = maxResponses;
    }
    
GuestCount MUST identify the number of guests for the request. The number of guests and OPTIONALLY the ages of the guests MAY be used to determine the room rates based on business rules for occupancy at each property. Only the rates that apply to the guest count information specified SHOULD be returned. 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="GuestCount" maxOccurs="10">
   <xs:complexType>
     <xs:attribute type="xs:string" use="required" name="AgeQualifyingCode"/>
     <xs:attribute type="xs:int" use="optional" name="Age"/>
     <xs:attribute type="xs:int" use="required" name="Count"/>
   </xs:complexType>
 </xs:element>
 
    public static class GuestCount
    {
        private String ageQualifyingCode;
        private Integer age;
        private Integer count;

        
Get the 'AgeQualifyingCode' attribute value. The AgeQualifyingCode specifies a code representing the age type of the guest and MUST refer to the OpenTravel Code List Age Qualifying Code (AQC). This attribute MUST be used in conjunction with the Count attribute to identify the number of guests of this age type. FastRez RECOMMENDS restricting the use of the code table to codes 7 - Infant, 8 - Child, 10 - Adult, and 11 - Senior.

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

        
Set the 'AgeQualifyingCode' attribute value. The AgeQualifyingCode specifies a code representing the age type of the guest and MUST refer to the OpenTravel Code List Age Qualifying Code (AQC). This attribute MUST be used in conjunction with the Count attribute to identify the number of guests of this age type. FastRez RECOMMENDS restricting the use of the code table to codes 7 - Infant, 8 - Child, 10 - Adult, and 11 - Senior.

Parameters:
ageQualifyingCode
        public void setAgeQualifyingCode(String ageQualifyingCode) {
            this. = ageQualifyingCode;
        }

        
Get the 'Age' attribute value. Age MAY be used to specify the age of the guest(s). Age MAY be used to calculate additional person fees by guest age.

Returns:
value
        public Integer getAge() {
            return ;
        }

        
Set the 'Age' attribute value. Age MAY be used to specify the age of the guest(s). Age MAY be used to calculate additional person fees by guest age.

Parameters:
age
        public void setAge(Integer age) {
            this. = age;
        }

        
Get the 'Count' attribute value. Count MUST specify the number of guests that are of the age type identified in AgeQualifyingCode and OPTIONALLY of the age identified in the Age attribute.

Returns:
value
        public Integer getCount() {
            return ;
        }

        
Set the 'Count' attribute value. Count MUST specify the number of guests that are of the age type identified in AgeQualifyingCode and OPTIONALLY of the age identified in the Age attribute.

Parameters:
count
        public void setCount(Integer count) {
            this. = count;
        }
    }
New to GrepCode? Check out our FAQ X