Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  
  package org.jibx.schema.org.opentravel._2012B.cruise;
  
  import java.util.List;
This message provides a detailed service history for the reservation requested. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05/common" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="OTA_CruiseBookingHistoryRS">
   <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="ReservationID">
           <xs:complexType>
             <xs:complexContent>
               <xs:extension base="ns:UniqueID_Type">
                 <xs:attributeGroup ref="ns:ReservationStatusGroup"/>
               </xs:extension>
             </xs:complexContent>
           </xs:complexType>
         </xs:element>
         <xs:element type="ns:SailingCategoryInfoType" name="SailingInfo" minOccurs="0"/>
         <xs:element name="HistoryInfos" minOccurs="0">
           <!-- Reference to inner class HistoryInfos -->
         </xs:element>
       </xs:sequence>
       <xs:element type="ns:ErrorsType" name="Errors"/>
     </xs:choice>
     <xs:attributeGroup ref="ns:OTA_PayloadStdAttributes"/>
     <xs:attributeGroup ref="ns:ResponseGroup"/>
   </xs:complexType>
 </xs:element>
 
 
 public class BookingHistoryRS
 {
     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 UniqueID reservationIDUniqueID;
     private SailingCategoryInfo sailingInfo;
     private HistoryInfos historyInfos;
     private Errors errors;
     private ResponseGroup responseGroup;
 
     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. Indicates successful processing of an OpenTravel message.

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

    
Set the 'Success' element value. Indicates successful processing of an OpenTravel message.

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

    
Get the 'Warnings' element value. Used in conjunction with a successful processing of an OpenTravel message to provide warnings.

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

    
Set the 'Warnings' element value. Used in conjunction with a successful processing of an OpenTravel message to provide warnings.

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

    
Get the extension value.

Returns:
value
        return ;
    }

    
Set the extension value.

Parameters:
reservationIDUniqueID
    public void setReservationIDUniqueID(UniqueID reservationIDUniqueID) {
        this. = reservationIDUniqueID;
    }

    
Get the 'ReservationStatusGroup' attributeGroup value. The status and last modified date of this reservation.

Returns:
value
    }

    
Set the 'ReservationStatusGroup' attributeGroup value. The status and last modified date of this reservation.

Parameters:
reservationIDReservationStatusGroup
            ReservationStatusGroup reservationIDReservationStatusGroup) {
        this. = reservationIDReservationStatusGroup;
    }

    
Get the 'SailingInfo' element value. Specifies the sailing information for a reservation.

Returns:
value
        return ;
    }

    
Set the 'SailingInfo' element value. Specifies the sailing information for a reservation.

Parameters:
sailingInfo
    public void setSailingInfo(SailingCategoryInfo sailingInfo) {
        this. = sailingInfo;
    }

    
Get the 'HistoryInfos' element value.

Returns:
value
    public HistoryInfos getHistoryInfos() {
        return ;
    }

    
Set the 'HistoryInfos' element value.

Parameters:
historyInfos
    public void setHistoryInfos(HistoryInfos historyInfos) {
        this. = historyInfos;
    }

    
Check if Errors is current selection for choice.

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

    
Get the 'Errors' element value. A collection of errors that occurred during the processing of a message.

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

    
Set the 'Errors' element value. A collection of errors that occurred during the processing of a message.

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

    
Get the 'OTA_PayloadStdAttributes' attributeGroup value. The standard attributes that appear on the root element for all OpenTravel Messages.

Returns:
value
        return ;
    }

    
Set the 'OTA_PayloadStdAttributes' attributeGroup value. The standard attributes that appear on the root element for all OpenTravel Messages.

Parameters:
OTAPayloadStdAttributes
    public void setOTAPayloadStdAttributes(
            OTAPayloadStdAttributes OTAPayloadStdAttributes) {
        this. = OTAPayloadStdAttributes;
    }

    
Get the 'ResponseGroup' attributeGroup value. Indicates that additional records are available and provides the echo token to be used to retrieve those records.

Returns:
value
    public ResponseGroup getResponseGroup() {
        return ;
    }

    
Set the 'ResponseGroup' attributeGroup value. Indicates that additional records are available and provides the echo token to be used to retrieve those records.

Parameters:
responseGroup
    public void setResponseGroup(ResponseGroup responseGroup) {
        this. = responseGroup;
    }
    
A collection of booking history info items. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05/common" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="HistoryInfos" minOccurs="0">
   <xs:complexType>
     <xs:sequence>
       <xs:element name="HistoryInfo" maxOccurs="999">
         <!-- Reference to inner class HistoryInfo -->
       </xs:element>
     </xs:sequence>
   </xs:complexType>
 </xs:element>
 
    public static class HistoryInfos
    {
        private List<HistoryInfohistoryInfoList = new ArrayList<HistoryInfo>();

        
Get the list of 'HistoryInfo' element items.

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

        
Set the list of 'HistoryInfo' element items.

Parameters:
list
        public void setHistoryInfoList(List<HistoryInfolist) {
             = list;
        }

        
Get the number of 'HistoryInfo' element items.

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

        
Add a 'HistoryInfo' element item.

Parameters:
item
        public void addHistoryInfo(HistoryInfo item) {
            .add(item);
        }

        
Get 'HistoryInfo' element item by position.

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

        
Remove all 'HistoryInfo' element items.
        public void clearHistoryInfoList() {
            .clear();
        }
        
Used to provide history of the booking. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05/common" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="HistoryInfo" maxOccurs="999">
   <xs:complexType>
     <xs:complexContent>
       <xs:extension base="ns:SourceType">
         <xs:sequence>
           <xs:element name="Items" maxOccurs="99">
             <!-- Reference to inner class Items -->
           </xs:element>
         </xs:sequence>
         <xs:attribute type="xs:dateTime" use="required" name="LastModified"/>
       </xs:extension>
     </xs:complexContent>
   </xs:complexType>
 </xs:element>
 
        public static class HistoryInfo extends Source
        {
            private List<ItemsitemList = new ArrayList<Items>();
            private DateTime lastModified;

            
Get the list of 'Items' element items.

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

            
Set the list of 'Items' element items.

Parameters:
list
            public void setItemList(List<Itemslist) {
                 = list;
            }

            
Get the number of 'Items' element items.

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

            
Add a 'Items' element item.

Parameters:
item
            public void addItem(Items item) {
                .add(item);
            }

            
Get 'Items' element item by position.

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

            
Remove all 'Items' element items.
            public void clearItemList() {
                .clear();
            }

            
Get the 'LastModified' attribute value.

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

            
Set the 'LastModified' attribute value.

Parameters:
lastModified
            public void setLastModified(DateTime lastModified) {
                this. = lastModified;
            }
            
Collection of changed items. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05/common" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="Items" maxOccurs="99">
   <xs:complexType>
     <xs:sequence>
       <xs:element name="Item" maxOccurs="999">
         <!-- Reference to inner class Item -->
       </xs:element>
     </xs:sequence>
     <xs:attributeGroup ref="ns:OptionalCodeOptionalNameGroup"/>
   </xs:complexType>
 </xs:element>
 
            public static class Items
            {
                private List<ItemitemList = new ArrayList<Item>();
                private OptionalCodeOptionalNameGroup optionalCodeOptionalNameGroup;

                
Get the list of 'Item' element items.

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

                
Set the list of 'Item' element items.

Parameters:
list
                public void setItemList(List<Itemlist) {
                     = list;
                }

                
Get the number of 'Item' element items.

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

                
Add a 'Item' element item.

Parameters:
item
                public void addItem(Item item) {
                    .add(item);
                }

                
Get 'Item' element item by position.

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

                
Remove all 'Item' element items.
                public void clearItemList() {
                    .clear();
                }

                
Get the 'OptionalCodeOptionalNameGroup' attributeGroup value. Specifies a general category of history items or type of history item (e.g., RESERVATION, TRANSACTION).

Returns:
value
                public OptionalCodeOptionalNameGroup getOptionalCodeOptionalNameGroup() {
                    return ;
                }

                
Set the 'OptionalCodeOptionalNameGroup' attributeGroup value. Specifies a general category of history items or type of history item (e.g., RESERVATION, TRANSACTION).

Parameters:
optionalCodeOptionalNameGroup
                public void setOptionalCodeOptionalNameGroup(
                        OptionalCodeOptionalNameGroup optionalCodeOptionalNameGroup) {
                    this. = optionalCodeOptionalNameGroup;
                }
                
History item details. Schema fragment(s) for this class:
 <xs:element xmlns:ns="http://www.opentravel.org/OTA/2003/05/common" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="Item" maxOccurs="999">
   <xs:complexType>
     <xs:complexContent>
       <xs:extension base="ns:ParagraphType">
         <xs:attribute type="xs:string" use="optional" name="GuestID"/>
         <xs:attribute type="xs:string" use="optional" name="ItemName"/>
         <xs:attribute type="xs:string" use="optional" name="OldValue"/>
         <xs:attribute type="xs:string" use="optional" name="NewValue"/>
         <xs:attribute type="xs:string" use="optional" name="Classification"/>
       </xs:extension>
     </xs:complexContent>
   </xs:complexType>
 </xs:element>
 
                public static class Item extends Paragraph
                {
                    private String guestID;
                    private String itemName;
                    private String oldValue;
                    private String newValue;
                    private String classification;

                    
Get the 'GuestID' attribute value. Unique identifier of the guest to whom this transaction applies.

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

                    
Set the 'GuestID' attribute value. Unique identifier of the guest to whom this transaction applies.

Parameters:
guestID
                    public void setGuestID(String guestID) {
                        this. = guestID;
                    }

                    
Get the 'ItemName' attribute value. The item being modified in this transaction.

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

                    
Set the 'ItemName' attribute value. The item being modified in this transaction.

Parameters:
itemName
                    public void setItemName(String itemName) {
                        this. = itemName;
                    }

                    
Get the 'OldValue' attribute value. Specifies the old value of an item.

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

                    
Set the 'OldValue' attribute value. Specifies the old value of an item.

Parameters:
oldValue
                    public void setOldValue(String oldValue) {
                        this. = oldValue;
                    }

                    
Get the 'NewValue' attribute value. Specifies the new value of an item.

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

                    
Set the 'NewValue' attribute value. Specifies the new value of an item.

Parameters:
newValue
                    public void setNewValue(String newValue) {
                        this. = newValue;
                    }

                    
Get the 'Classification' attribute value. Specifies the classification of the item (e.g., RES_GUEST, RES_HEADER).

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

                    
Set the 'Classification' attribute value. Specifies the classification of the item (e.g., RES_GUEST, RES_HEADER).

Parameters:
classification
                    public void setClassification(String classification) {
                        this. = classification;
                    }
                }
            }
        }
    }
New to GrepCode? Check out our FAQ X