public class EhCacheTicketRegistry extends AbstractTicketRegistry
Ehcache based distributed ticket registry.
cipherExecutor
Constructor and Description |
---|
EhCacheTicketRegistry(net.sf.ehcache.Cache ticketCache,
CipherExecutor cipher)
Instantiates a new EhCache ticket registry.
|
Modifier and Type | Method and Description |
---|---|
void |
addTicket(Ticket ticketToAdd)
Add a ticket to the registry.
|
long |
deleteAll()
Delete all tickets from the registry.
|
boolean |
deleteSingleTicket(java.lang.String ticketId)
Delete a single ticket instance from the store.
|
Ticket |
getTicket(java.lang.String ticketIdToGet)
Retrieve a ticket from the registry.
|
java.util.Collection<Ticket> |
getTickets()
Retrieve all tickets from the registry.
|
java.lang.String |
toString() |
Ticket |
updateTicket(Ticket ticket)
Update the received ticket.
|
decodeTicket, decodeTickets, deleteChildren, deleteSingleTicket, deleteTicket, encodeTicket, encodeTicketId, getTicket, isCipherExecutorEnabled, serviceTicketCount, sessionCount, setCipherExecutor
public EhCacheTicketRegistry(net.sf.ehcache.Cache ticketCache, CipherExecutor cipher)
ticketCache
- the ticket cachecipher
- the cipherpublic void addTicket(Ticket ticketToAdd)
TicketRegistry
ticketToAdd
- The ticket we wish to add to the cache.public boolean deleteSingleTicket(java.lang.String ticketId)
deleteSingleTicket
in class AbstractTicketRegistry
ticketId
- the ticket idpublic long deleteAll()
TicketRegistry
public Ticket getTicket(java.lang.String ticketIdToGet)
TicketRegistry
ticketIdToGet
- the id of the ticket we wish to retrievepublic java.util.Collection<Ticket> getTickets()
TicketRegistry
public Ticket updateTicket(Ticket ticket)
TicketRegistry
ticket
- the ticketpublic java.lang.String toString()
toString
in class java.lang.Object