View Javadoc

1   /*
2    * $Id: Order.java 19423 2010-09-08 08:04:54Z dirk.olmes $
3    * --------------------------------------------------------------------------------------
4    * Copyright (c) MuleSoft, Inc.  All rights reserved.  http://www.mulesoft.com
5    *
6    * The software in this package is published under the terms of the CPAL v1.0
7    * license, a copy of which has been included with this distribution in the
8    * LICENSE.txt file.
9    */
10  
11  package org.mule.example.bookstore;
12  
13  /**
14   * Simple class which represents a Book Order.
15   */
16  public class Order 
17  {
18      private Book book;
19      private int quantity;
20      /** Shipping address */
21      private String address;
22      /** E-mail address used to receive order notifications */
23      private String email;
24      
25      public Order()
26      {
27          // empty constructor
28      }
29      
30      public Order(Book book, int quantity, String address, String email)
31      {
32          this.book = book;
33          this.quantity = quantity;
34          this.address = address;
35          this.email = email;
36      }
37      
38      public Book getBook()
39      {
40          return book;
41      }
42  
43      public void setBook(Book book)
44      {
45          this.book = book;
46      }
47  
48      public int getQuantity()
49      {
50          return quantity;
51      }
52  
53      public void setQuantity(int quantity)
54      {
55          this.quantity = quantity;
56      }
57  
58      public String getAddress()
59      {
60          return address;
61      }
62  
63      public void setAddress(String address)
64      {
65          this.address = address;
66      }
67  
68      public String getEmail()
69      {
70          return email;
71      }
72  
73      public void setEmail(String email)
74      {
75          this.email = email;
76      }
77  }