View Javadoc

1   /*
2    * Copyright 2004 Carlos Sanchez.
3    *
4    * Licensed under the Apache License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    *
8    *      http://www.apache.org/licenses/LICENSE-2.0
9    *
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   * See the License for the specific language governing permissions and
14   * limitations under the License.
15   */
16  package net.sf.oness.order.model.bo;
17  
18  import java.util.Collection;
19  
20  /***
21   * @hibernate.class table="deliverydocket"
22   * 
23   * @author Carlos Sanchez
24   * @version $Revision: 1.5 $
25   */
26  public class DeliveryDocket extends Master {
27  
28      private Collection orders, invoices;
29      
30      private Boolean invoiced;
31  
32      /***
33       * @hibernate.bag table="deliverydocket_deliverydocketitem" inverse="true" lazy="true"
34       * @hibernate.collection-key column="deliverydocket_id"
35       * @hibernate.collection-many-to-many column="deliverydocketitem_id" class="net.sf.oness.order.model.bo.DeliveryDocketItem"
36       * 
37       * @return Returns the items.
38       */
39      public Collection getItems() {
40          return super.getItems();
41      }
42  
43      /***
44       * @param orders
45       *            The orders to set.
46       */
47      public void setOrders(Collection orders) {
48          this.orders = orders;
49      }
50  
51      /***
52       * @hibernate.bag table="order_deliverydocket" lazy="true" order-by="order_id desc"
53       * @hibernate.collection-key column="deliverydocket_id"
54       * @hibernate.collection-many-to-many column="order_id" class="net.sf.oness.order.model.bo.Order"
55       * 
56       * @return Returns the orders.
57       */
58      public Collection getOrders() {
59          return orders;
60      }
61  
62      /***
63       * @param invoices
64       *            The invoices to set.
65       */
66      public void setInvoices(Collection invoices) {
67          this.invoices = invoices;
68      }
69  
70      /***
71       * @hibernate.bag table="deliverydocket_invoice" inverse="true" lazy="true"
72       * @hibernate.collection-key column="deliverydocket_id"
73       * @hibernate.collection-many-to-many column="invoice_id" class="net.sf.oness.order.model.bo.Invoice"
74       * 
75       * @return Returns the invoices.
76       */
77      public Collection getInvoices() {
78          return invoices;
79      }
80  
81      /***
82       * @param invoiced
83       *            The invoiced to set.
84       */
85      public void setInvoiced(Boolean invoiced) {
86          this.invoiced = invoiced;
87      }
88  
89      /***
90       * @hibernate.property
91       * 
92       * @return Returns the invoiced.
93       */
94      public Boolean getInvoiced() {
95          return invoiced;
96      }
97  
98  }