Fish & Chips Club 4.10.0.0

hirondelle.fish.main.visit
Class Visit

Object
  extended by hirondelle.fish.main.visit.Visit

public class Visit
extends Object

Model Object for a weekly Visit to a Resto.

(This class is non-final only because of a test case for equals.)


Constructor Summary
Visit(Id aId, Id aRestaurantId, Date aLunchDate, SafeText aMessage)
          Constructor.
 
Method Summary
 boolean equals(Object aThat)
           
 Id getId()
          Return the Visit id passed to the constructor.
 Date getLunchDate()
          Return a defensive copy of the lunch date passed to the constructor.
 SafeText getMessage()
          Return the message passed to the constructor.
 Code getRestaurant()
          Return the item in CodeTable.RESTAURANTS corresponding to the restaurant id passed to the constructor.
 int hashCode()
           
 String toString()
          Intended for debugging only.
 
Methods inherited from class Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Visit

public Visit(Id aId,
             Id aRestaurantId,
             Date aLunchDate,
             SafeText aMessage)
      throws ModelCtorException
Constructor.

Parameters:
aId - underlying database internal identifier (optional) 1..50 characters
aRestaurantId - required. This item is translated internally to its corresponding Code.
aLunchDate - date for the visit (required), year in range 2006..2100. A defensive copy is made for this item.
aMessage - shown to the Members on RSVP page (optional), 2..50 characters
Throws:
ModelCtorException
Method Detail

getId

public Id getId()
Return the Visit id passed to the constructor.


getRestaurant

public Code getRestaurant()
Return the item in CodeTable.RESTAURANTS corresponding to the restaurant id passed to the constructor.


getLunchDate

public Date getLunchDate()
Return a defensive copy of the lunch date passed to the constructor.


getMessage

public SafeText getMessage()
Return the message passed to the constructor.


toString

public String toString()
Intended for debugging only.

Overrides:
toString in class Object

equals

public boolean equals(Object aThat)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

Fish & Chips Club 4.10.0.0

Copyright Hirondelle Systems - Generated 2013Oct19.12.26