Package org.bedework.eventreg.db
Class Registration
- All Implemented Interfaces:
Serializable,Comparable<Registration>
A registration to an event for a single person (or entity)
- Author:
- douglm
- See Also:
-
Field Summary
FieldsFields inherited from class org.bedework.eventreg.db.SerializableProperties
vals -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAdd a new ticketvoidvoidaddTickets(int numTickets) intcompareTo(Registration that) booleangetEmail()getEvent()getHref()intintgetType()inthashCode()voidremoveTicket(Ticket val) voidremoveTickets(int numTickets) voidsaveFormValues(Map vals) voidvoidsetCancelSent(boolean val) voidsetComment(String val) voidsetCreated(String val) voidvoidvoidvoidsetEvLocation(String evLocation) voidsetEvSummary(String evSummary) voidvoidsetFormName(String val) voidsetFormOwner(String val) voidsetFormValues(String val) voidvoidSet the lastmod to now.voidsetLastmod(String val) voidsetMessage(String val) voidsetNotificationTimestamp(String notificationTimestamp) voidsetRegistrationId(Long val) voidsetTickets(Set<Ticket> val) voidsetTicketsRequested(int val) voidSet the various timestamps to now for a new registration.voidvoidSet the waitq date to now.voidsetWaitqDate(String val) The waitqDate is almost the lastmod and orders the waitq.toString()protected voidtoStringSegment(org.bedework.util.misc.ToString ts) Add our stuff to the StringBuilderMethods inherited from class org.bedework.eventreg.db.DbItem
clone, equals, getId, getSeq, setId, setSeq, unsavedMethods inherited from class org.bedework.eventreg.db.SerializableProperties
asMap, asString, getMap, getProperties, getVals, init, may, mayBool, mayInt, mayList, mayList, must, mustList, setBoolean, setInt, setObject, setProperties, setString
-
Field Details
-
typeRegistered
Type values- See Also:
-
typeHold
- See Also:
-
-
Constructor Details
-
Registration
public Registration()
-
-
Method Details
-
setRegistrationId
- Parameters:
val- the id
-
getRegistrationId
- Returns:
- registrationId
-
setAuthid
- Parameters:
val- the authid
-
getAuthid
- Returns:
- authid
-
setEmail
- Parameters:
val- email of user (do we need this if notify engine has it)
-
getEmail
- Returns:
-
setHref
- Parameters:
val- href of event
-
getHref
- Returns:
- eventHref
-
setTicketsRequested
public void setTicketsRequested(int val) - Parameters:
val- - ticketsRequested
-
getTicketsRequested
public int getTicketsRequested()- Returns:
- ticketsRequested
-
setType
- Parameters:
val- hold/reg etc
-
getType
- Returns:
- type
-
setCreated
- Parameters:
val- date
-
getCreated
- Returns:
- created
-
setLastmod
- Parameters:
val- date
-
getLastmod
- Returns:
- lastmod
-
setWaitqDate
The waitqDate is almost the lastmod and orders the waitq. We need a separate date to avoid somebody going to the back of the queue because of a trivial modification. For example changing the number of tickets required should preserve your place if you're already on the q.On the other hand we need to ensure that somebody goes to the back of the queue if they are already fulfilled but decide they want more.
- Parameters:
val- date
-
getWaitqDate
- Returns:
- waitqDate
-
setComment
- Parameters:
val- a comment
-
getComment
- Returns:
- comment
-
setMessage
- Parameters:
val- a message
-
getMessage
- Returns:
- message
-
setFormName
- Parameters:
val- name
-
getFormName
- Returns:
- name
-
setFormOwner
- Parameters:
val- name
-
getFormOwner
- Returns:
- name
-
setTickets
- Parameters:
val- set of tickets
-
getTickets
- Returns:
- tickets
-
getEvSummary
-
setEvSummary
-
getEvDate
-
setEvDate
-
getEvTime
-
setEvTime
-
getEvLocation
-
setEvLocation
-
getNotificationTimestamp
-
setNotificationTimestamp
-
setCancelSent
public void setCancelSent(boolean val) - Parameters:
val- flag to say we sent a cancel message
-
getCancelSent
- Returns:
- flag to say we sent a cancel message
- Throws:
EventregException
-
setFormValues
- Parameters:
val- Saved form fields as a serialized json string
-
getFormValues
- Returns:
- Saved form fields as a serialized json string
- Throws:
EventregException
-
setEvent
- Parameters:
val- the event
-
getEvent
- Returns:
- event
-
saveFormValues
- Throws:
EventregException
-
restoreFormValues
- Throws:
EventregException
-
setTimestamps
public void setTimestamps()Set the various timestamps to now for a new registration. -
setLastmod
public void setLastmod()Set the lastmod to now. -
setWaitqDate
public void setWaitqDate()Set the waitq date to now. -
toStringSegment
protected void toStringSegment(org.bedework.util.misc.ToString ts) Add our stuff to the StringBuilder- Overrides:
toStringSegmentin classDbItem<Registration>- Parameters:
ts- for result
-
addTicket
- Parameters:
val- a ticket
-
addTicket
public void addTicket()Add a new ticket -
addTickets
public void addTickets(int numTickets) - Parameters:
numTickets-
-
removeTicket
- Parameters:
val-
-
removeTickets
public void removeTickets(int numTickets) - Parameters:
numTickets-
-
getNumTickets
public int getNumTickets()- Returns:
- numTickets
-
compareTo
- Specified by:
compareToin interfaceComparable<Registration>- Overrides:
compareToin classDbItem<Registration>
-
hashCode
public int hashCode()- Overrides:
hashCodein classDbItem<Registration>
-
toString
-