org.jboss.seam.examples.booking.model
Class Hotel

java.lang.Object
  extended by org.jboss.seam.examples.booking.model.Hotel
All Implemented Interfaces:
Serializable

@Entity
@Veto
public class Hotel
extends Object
implements Serializable

Hotel is the model/entity class that represents a hotel.

Author:
Gavin King, Dan Allen
See Also:
Serialized Form

Constructor Summary
Hotel()
           
Hotel(int price, int stars, String name, String address, String city, String state, String zip, String country)
           
Hotel(String name, String address, String city, String state, String zip, String country)
           
 
Method Summary
 String getAddress()
           
 String getCity()
           
 String getCountry()
           
 Long getId()
           
 String getLocation()
           
 String getName()
           
 BigDecimal getPrice()
           
 Integer getStars()
           
 String getState()
           
 String getZip()
           
 void setAddress(String address)
           
 void setCity(String city)
           
 void setCountry(String country)
           
 void setId(Long id)
           
 void setName(String name)
           
 void setPrice(BigDecimal price)
           
 void setStars(Integer stars)
           
 void setState(String state)
           
 void setZip(String zip)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Hotel

public Hotel()

Hotel

public Hotel(String name,
             String address,
             String city,
             String state,
             String zip,
             String country)

Hotel

public Hotel(int price,
             int stars,
             String name,
             String address,
             String city,
             String state,
             String zip,
             String country)
Method Detail

getId

public Long getId()

setId

public void setId(Long id)

getName

@Size(max=50)
@NotNull
public String getName()

setName

public void setName(String name)

getAddress

@Size(max=100)
@NotNull
public String getAddress()

setAddress

public void setAddress(String address)

getCity

@Size(max=40)
@NotNull
public String getCity()

setCity

public void setCity(String city)

getZip

@Size(min=3,
      max=6)
@NotNull
public String getZip()

setZip

public void setZip(String zip)

getState

@Size(min=2,
      max=10)
public String getState()

setState

public void setState(String state)

getCountry

@Size(min=2,
      max=40)
@NotNull
public String getCountry()

setCountry

public void setCountry(String country)

getStars

@Min(value=1L)
@Max(value=5L)
public Integer getStars()

setStars

public void setStars(Integer stars)

getPrice

public BigDecimal getPrice()

setPrice

public void setPrice(BigDecimal price)

getLocation

public String getLocation()

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2011 Seam Framework. All Rights Reserved.