| Constructor and Description |
|---|
EventEJB() |
| Modifier and Type | Method and Description |
|---|---|
es.uvigo.esei.dgss.letta.domain.entities.Event |
createEvent(es.uvigo.esei.dgss.letta.domain.entities.Event event)
Creates a new
Event in the database, setting its creator as the
current identified User. |
List<es.uvigo.esei.dgss.letta.domain.entities.Event> |
listByDate(int start,
int count)
Returns a paginated
List of Events, sorted by
ascending date (which means that older events will be first on the list). |
List<es.uvigo.esei.dgss.letta.domain.entities.Event> |
listHighlighted(int start,
int count)
Returns a paginated
List of Events with all the
currently highlighted events, sorted by a magician. |
List<es.uvigo.esei.dgss.letta.domain.entities.Event> |
search(String search,
int start,
int count)
|
@RolesAllowed(value="USER") public es.uvigo.esei.dgss.letta.domain.entities.Event createEvent(es.uvigo.esei.dgss.letta.domain.entities.Event event) throws IllegalArgumentException, SecurityException
Event in the database, setting its creator as the
current identified User.event - The Event to be inserted into the database.Event object with all its auto-generated
fields (the event Event.getId() id) already set.IllegalArgumentException - if the received Event is nullSecurityException - if the currently identified user is not found in the database
(!!!).@PermitAll public List<es.uvigo.esei.dgss.letta.domain.entities.Event> listByDate(int start, int count)
List of Events, sorted by
ascending date (which means that older events will be first on the list).start - The first Event position to return, numbered from 0.count - The number of Events to return.List with the specified number of Events, sorted by ascending date and counting from the received
start point.@PermitAll public List<es.uvigo.esei.dgss.letta.domain.entities.Event> listHighlighted(int start, int count)
List of Events with all the
currently highlighted events, sorted by a magician.start - The first Event position to return, numbered from 0.count - The number of Events to return.List with the specified number of Events, magically sorted and counting from the received start
point.@PermitAll public List<es.uvigo.esei.dgss.letta.domain.entities.Event> search(String search, int start, int count) throws IllegalArgumentException
Events matching some given String
query, and returns the results as a paginated List. If the given
search pattern is null, a NullPointerException will be thrown. title
and short description. Results are
sorted by ascending date and descending number of attendees.search - The search pattern as a simple String.start - The first Event position to return, from 0.count - The number of Events to return.List with the specified number of Events that have matched the search query.IllegalArgumentException - if the received String with the search terms is null.Copyright © 2015. All rights reserved.