Package com.groiss.cal
Class SimpleEvent
java.lang.Object
com.groiss.cal.SimpleEvent
default
CalEvent
implementation-
Field Summary
-
Constructor Summary
ConstructorDescriptionSimpleEvent
(CalEvent evt) constructor creating a copy of the given eventSimpleEvent
(String subject, Date fromDate, Date untilDate) constructor -
Method Summary
Modifier and TypeMethodDescriptionvoid
addObject
(Persistent obj) clone()
boolean
int
returns the caption to use for this event.int
returns the object thisCalEvent
was initially fetched forthe objects, this event belongs toint
getText()
getUID()
get the unique identifier for this eventint
hashCode()
boolean
should a reminder be used?boolean
boolean
boolean
check if the given user may edit this eventboolean
check if the given user may view this eventonClick()
void
setCaption
(int caption) void
setEventType
(EventType eventType) void
setFromDate
(Date fromDate) void
setHasReminder
(boolean hasReminder) void
setInterval
(int interval) void
setLocation
(String location) void
setOnClick
(String onClick) void
setPrivateDate
(boolean isPrivateDate) void
setPrivateEvent
(boolean privateEvent) void
setRecEndDate
(Date recEndDate) void
setRecurrenceInterval
(int interval) void
setRecurrenceType
(int recurrenceType) void
setSubject
(String subject) void
void
void
setUntilDate
(Date untilDate) void
setWholeDay
(boolean wholeDay) void
Shift a recurrent evt to another date and compute the right time
-
Constructor Details
-
SimpleEvent
public SimpleEvent() -
SimpleEvent
constructor- Parameters:
subject
- the event's subjectfromDate
- the start-dateuntilDate
- the end-date
-
SimpleEvent
constructor creating a copy of the given event- Parameters:
evt
- the event
-
-
Method Details
-
clone
-
getCaption
public int getCaption()returns the caption to use for this event.- Specified by:
getCaption
in interfaceCalEvent
- Returns:
- the caption's index
CalInfo.getCaptions()
-
getFromDate
- Specified by:
getFromDate
in interfaceCalEvent
- Returns:
- Returns the fromDate.
-
getInterval
public int getInterval()- Specified by:
getInterval
in interfaceCalEvent
- Returns:
- Returns the interval.
-
getLocation
- Specified by:
getLocation
in interfaceCalEvent
- Returns:
- Returns the location.
-
getRecEndDate
- Specified by:
getRecEndDate
in interfaceCalEvent
- Returns:
- Returns the recEndDate.
-
getRecurrenceType
public int getRecurrenceType()- Specified by:
getRecurrenceType
in interfaceCalEvent
- Returns:
- Returns the recurrenceType.
-
getSubject
- Specified by:
getSubject
in interfaceCalEvent
- Returns:
- Returns the subject.
-
getText
-
getUID
get the unique identifier for this event -
getUntilDate
- Specified by:
getUntilDate
in interfaceCalEvent
- Returns:
- Returns the untilDate.
-
isPrivateEvent
public boolean isPrivateEvent()- Specified by:
isPrivateEvent
in interfaceCalEvent
- Returns:
- Returns the privateDate.
-
isWholeDay
public boolean isWholeDay()- Specified by:
isWholeDay
in interfaceCalEvent
- Returns:
- Returns the wholeDay.
-
onClick
-
addObject
-
setCaption
public void setCaption(int caption) -
setFromDate
-
setInterval
public void setInterval(int interval) -
setLocation
-
setOnClick
-
setPrivateEvent
public void setPrivateEvent(boolean privateEvent) -
setRecEndDate
-
setRecurrenceType
public void setRecurrenceType(int recurrenceType) -
setSubject
-
setText
-
setUID
-
setUntilDate
-
setWholeDay
public void setWholeDay(boolean wholeDay) -
shiftTo
Shift a recurrent evt to another date and compute the right time- Parameters:
begin
- the date to shift to
-
getObject
returns the object thisCalEvent
was initially fetched for -
getObjects
the objects, this event belongs to- Specified by:
getObjects
in interfaceCalEvent
- Returns:
- the objects
-
setHasReminder
public void setHasReminder(boolean hasReminder) -
hasReminder
public boolean hasReminder()should a reminder be used?- Specified by:
hasReminder
in interfaceCalEvent
- Returns:
true
orfalse
-
mayEdit
check if the given user may edit this event -
mayView
check if the given user may view this event -
getEventType
- Specified by:
getEventType
in interfaceCalEvent
- Returns:
- the
EventType
of this event
-
setEventType
-
equals
-
setRecurrenceInterval
public void setRecurrenceInterval(int interval) - Parameters:
interval
- sets the recurrence interval
-
setPrivateDate
public void setPrivateDate(boolean isPrivateDate) -
hashCode
public int hashCode()
-