Methods summary
public
|
|
public
|
#
set_id( integer $id )
Sets the id of the event. The id is the corresponding data base entry one.
Sets the id of the event. The id is the corresponding data base entry one.
Parameters
|
public
|
#
set_entitled( string $entitled )
Sets the entitled of the event. The entitled can be considered as the name, it must be explicit.
Sets the entitled of the event. The entitled can be considered as the name, it must be explicit.
Parameters
- $entitled
- The event entitiled.
|
public
|
#
set_fixing_url( string $fixing_url )
Sets the URL corresponding to the event. For the contributions and the administrator alerts it's the number URL at which the problem can be solved.
Sets the URL corresponding to the event. For the contributions and the administrator alerts it's the number URL at which the problem can be solved.
Parameters
- $fixing_url
- Relative URL (the first character must be / for the root of the site).
|
public
|
#
set_status( integer $new_current_status )
Set the status of the event.
Set the status of the event.
Parameters
- $new_current_status
One of those elements:
- Event::EVENT_STATUS_UNREAD if it's not read.
- Event::EVENT_STATUS_BEING_PROCESSED if the event is beeing processed
- Event::EVENT_STATUS_PROCESSED if the event is processed.
|
public
|
#
set_creation_date( Date $date )
Sets the creation date of the event.
Sets the creation date of the event.
Parameters
|
public
|
#
set_id_in_module( integer $id )
Sets the id in module parameter. It corresponds to the id of the element corresponding to the event in your data base tables.
For example, il you use the events to allow user to purpose some news in your web site, it will be the id of the news added.
Sets the id in module parameter. It corresponds to the id of the element corresponding to the event in your data base tables.
For example, il you use the events to allow user to purpose some news in your web site, it will be the id of the news added.
Parameters
|
public
|
#
set_identifier( string $identifier )
Sets the event identifier. To retrieve your event, you might need to have a field in which you put some informations, for example a hash or an identifier.
It's that identifier which can be used to filter the events. You don't have to use it, you can let it blank.
Sets the event identifier. To retrieve your event, you might need to have a field in which you put some informations, for example a hash or an identifier.
It's that identifier which can be used to filter the events. You don't have to use it, you can let it blank.
Parameters
- $identifier
- Identifier of the event.
|
public
|
#
set_type( string $type )
Sets the type of the event. To retrieve your event, you might need to have a type of event, for example if your module has differents kinds of events. With this field, you can specify it.
Sets the type of the event. To retrieve your event, you might need to have a type of event, for example if your module has differents kinds of events. With this field, you can specify it.
Parameters
- $type
- The type of your event.
|
public
|
#
set_must_regenerate_cache( boolean $must )
Sets a private property indicating if the changes made on this event imply the regeneration of the events cache.
Sets a private property indicating if the changes made on this event imply the regeneration of the events cache.
Parameters
- $must
- true if we must generate the events cache, otherwise false.
|
public
integer
|
#
get_id( )
Gets the id of the event (in the event data base).
Gets the id of the event (in the event data base).
Returns
integer The id.
|
public
string
|
#
get_entitled( )
Returns the entitled of the event.
Returns the entitled of the event.
Returns
string The entitled.
|
public
string
|
#
get_fixing_url( )
Returns the URL corresponding to the alert.
Returns the URL corresponding to the alert.
Returns
string Relative URL whose first character is / for the website root.
|
public
integer
|
#
get_status( )
Gets the status of the event. The status is one of those elements:
ul>
Event::EVENT_STATUS_UNREAD if it's not read.
Event::EVENT_STATUS_BEING_PROCESSED if the event is beeing processed
Event::EVENT_STATUS_PROCESSED if the event is processed.
Gets the status of the event. The status is one of those elements:
ul> Event::EVENT_STATUS_UNREAD if it's not read. Event::EVENT_STATUS_BEING_PROCESSED if the event is beeing processed Event::EVENT_STATUS_PROCESSED if the event is processed.
Returns
integer Status
|
public
Date
|
#
get_creation_date( )
Returns the creation date of the event.
Returns the creation date of the event.
Returns
|
public
integer
|
#
get_id_in_module( )
Gets the id in the module. This value corresponds to the id of the daba base entry associated to the event.
Gets the id in the module. This value corresponds to the id of the daba base entry associated to the event.
Returns
integer The id in the module.
|
public
string
|
#
get_identifier( )
Gets the identifier of the event. To retrieve your event, you might need to have a field in which you put some informations, for example a hash or an identifier.
It's that identifier which can be used to filter the events.
Gets the identifier of the event. To retrieve your event, you might need to have a field in which you put some informations, for example a hash or an identifier.
It's that identifier which can be used to filter the events.
Returns
string The identifier of the event.
|
public
string
|
#
get_type( )
Gets the type of the event. To retrieve your event, you might need to have a type of event, for example if your module has differents kinds of events. With this field, you can specify it.
Gets the type of the event. To retrieve your event, you might need to have a type of event, for example if your module has differents kinds of events. With this field, you can specify it.
Returns
string The type.
|
public
boolean
|
#
get_must_regenerate_cache( )
Gets the value indicating if the cache must be generated.
Gets the value indicating if the cache must be generated.
Returns
boolean true if the cache has to be generated, false else.
|
public
The
|
#
get_status_name( )
Gets the event status name. It's automatically translated in the user language.
Gets the event status name. It's automatically translated in the user language.
Returns
The name of the event status, ready to be displayed.
|
public
|
#
build_event( integer $id, string $entitled, string $fixing_url, integer $current_status, Date $creation_date, integer $id_in_module, string $identifier, string $type )
Builds an event object from its whole parameters.
Builds an event object from its whole parameters.
Parameters
- $id
- The event id.
- $entitled
- The event entitled.
- $fixing_url
- The URL corresponding to the event.
- $current_status
- The event status.
- $creation_date
- The creation date.
- $id_in_module
- The id of the object associated to the event.
- $identifier
- The event identifier.
- $type
- The event type.
|