fr.paris.lutece.plugins.calendar.business
Class SimpleAgenda

java.lang.Object
  extended by fr.paris.lutece.plugins.calendar.business.SimpleAgenda
All Implemented Interfaces:
Agenda

public class SimpleAgenda
extends java.lang.Object
implements Agenda

A basic implementation of an agenda


Constructor Summary
SimpleAgenda()
           
 
Method Summary
 void addEvent(Event event)
          Add an event to the agenda
 java.util.List getEvents()
          Retrieves all events of the agenda
 java.util.List getEventsByDate(java.lang.String strDate)
          Retrieves events for a given date
 java.util.List getEventsByDate(java.lang.String strDateBegin, java.lang.String strDateEnd)
          Fetches the events by date
 java.lang.String getKeyName()
          Returns the KeyName
 java.lang.String getName()
          Returns the name of the Agenda
 boolean hasEvents(java.lang.String strDate)
          Indicates if the agenda gets events for a given date
 void setKeyName(java.lang.String strKeyName)
          Sets the KeyName
 void setName(java.lang.String strName)
          Defines the name of the Agenda
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleAgenda

public SimpleAgenda()
Method Detail

getName

public java.lang.String getName()
Returns the name of the Agenda

Specified by:
getName in interface Agenda
Returns:
The agenda's name

setName

public void setName(java.lang.String strName)
Defines the name of the Agenda

Specified by:
setName in interface Agenda
Parameters:
strName - The agenda's name

getKeyName

public java.lang.String getKeyName()
Returns the KeyName

Specified by:
getKeyName in interface Agenda
Returns:
The KeyName

setKeyName

public void setKeyName(java.lang.String strKeyName)
Sets the KeyName

Specified by:
setKeyName in interface Agenda
Parameters:
strKeyName - The KeyName

hasEvents

public boolean hasEvents(java.lang.String strDate)
Indicates if the agenda gets events for a given date

Specified by:
hasEvents in interface Agenda
Parameters:
strDate - A date code
Returns:
True if there is events, otherwise false

getEventsByDate

public java.util.List getEventsByDate(java.lang.String strDate)
Retrieves events for a given date

Specified by:
getEventsByDate in interface Agenda
Parameters:
strDate - A date code
Returns:
A list of events

addEvent

public void addEvent(Event event)
Add an event to the agenda

Parameters:
event - The event to add

getEvents

public java.util.List getEvents()
Retrieves all events of the agenda

Specified by:
getEvents in interface Agenda
Returns:
A list of events

getEventsByDate

public java.util.List getEventsByDate(java.lang.String strDateBegin,
                                      java.lang.String strDateEnd)
Fetches the events by date

Specified by:
getEventsByDate in interface Agenda
Parameters:
strDateBegin - The start date
strDateEnd - The end date
Returns:
The list of evensts


Copyright © 2008 Mairie de Paris. All Rights Reserved.