at.ac.tuwien.infosys.sm4all.copal.rest
Interface Service

All Known Implementing Classes:
ServiceImpl

public interface Service

Interface for COPAL REST service.

Author:
sanjin

Method Summary
 javax.ws.rs.core.Response create(javax.ws.rs.core.UriInfo uriInfo, ProcessedEventQuery query)
          Creates specified ProcessedEventQuery.
 javax.ws.rs.core.Response destroy(java.lang.String name)
          Destroys specified ContextQuery.
 javax.ws.rs.core.Response getEventType(java.lang.String name)
          Returns a Response with registered XMLContextEventType that has specified name.
 javax.ws.rs.core.Response getEventTypes()
          Returns a Response with all registered XMLContextEventTypes.
 javax.ws.rs.core.Response getListener(java.lang.String queryName, java.lang.String name)
          Returns a Response with a ContextListener that has specified name and is registered with ContextQuery that has specified query name.
 javax.ws.rs.core.Response getListeners(java.lang.String queryName)
          Returns a Response with all ContextListeners that are registered with ContextQuery that has specified query name.
 javax.ws.rs.core.Response getProcessor(java.lang.String name)
          Returns a Response with registered ContextProcessor that has specified name.
 javax.ws.rs.core.Response getProcessors()
          Returns a Response with all registered ContextProcessors.
 javax.ws.rs.core.Response getProcessors(java.lang.String eventName)
          Returns a Response with all registered ContextProcessors that process events with specified name.
 javax.ws.rs.core.Response getPublisher(java.lang.String sourceID)
          Returns a Response with registered ContextPublisher that has specified source ID.
 javax.ws.rs.core.Response getPublishers()
          Returns a Response with all registered ContextPublishers.
 javax.ws.rs.core.Response getPublishers(java.lang.String eventName)
          Returns a Response with all registered ContextPublishers that publish events with specified name.
 javax.ws.rs.core.Response getQueries()
          Returns a Response with all non-destroyed ContextQuerys.
 javax.ws.rs.core.Response getQueries(java.lang.String eventName)
          Returns a Response with all non-destroyed ContextQuerys that listen on events with specified name.
 javax.ws.rs.core.Response getQuery(java.lang.String name)
          Returns a Response with non-destroyed ContextQuery that has specified name.
 javax.ws.rs.core.Response publish(java.lang.String sourceID, Event event)
          Publishes specified Event using a RESTfulPublisher that has specified source ID.
 javax.ws.rs.core.Response register(javax.ws.rs.core.UriInfo uriInfo, RESTfulPublisher publisher)
          Registers specified RESTfulPublisher.
 javax.ws.rs.core.Response register(javax.ws.rs.core.UriInfo uriInfo, java.lang.String queryName, RESTfulListener listener)
          Registers specified RESTfulListener with ContextQuery that has specified query name.
 javax.ws.rs.core.Response register(javax.ws.rs.core.UriInfo uriInfo, XMLContextEventType eventType)
          Registers specified XMLContextEventType.
 javax.ws.rs.core.Response unregisterEventType(java.lang.String name)
          Unregisters specified XMLContextEventType.
 javax.ws.rs.core.Response unregisterListener(java.lang.String queryName, java.lang.String name)
          Unregisters specified RESTfulListener from ContextQuery that has specified query name.
 javax.ws.rs.core.Response unregisterPublisher(java.lang.String sourceID)
          Unregisters specified RESTfulPublisher.
 

Method Detail

getEventTypes

javax.ws.rs.core.Response getEventTypes()
Returns a Response with all registered XMLContextEventTypes.

Returns:
the Response with all registered XMLContextEventTypes.

register

javax.ws.rs.core.Response register(@Context
                                   javax.ws.rs.core.UriInfo uriInfo,
                                   XMLContextEventType eventType)
Registers specified XMLContextEventType.

Parameters:
uriInfo - the UriInfo to create URI to registered XMLContextEventType.
eventType - the XMLContextEventType.
Returns:
the Response.

getEventType

javax.ws.rs.core.Response getEventType(java.lang.String name)
Returns a Response with registered XMLContextEventType that has specified name.

Parameters:
name - the name of the XMLContextEventType.
Returns:
the Response with registered XMLContextEventType with specified name.

unregisterEventType

javax.ws.rs.core.Response unregisterEventType(java.lang.String name)
Unregisters specified XMLContextEventType.

Parameters:
name - the name of the XMLContextEventType.
Returns:
the Response with unregistered XMLContextEventType.

getPublishers

javax.ws.rs.core.Response getPublishers(java.lang.String eventName)
Returns a Response with all registered ContextPublishers that publish events with specified name.

Parameters:
eventName - the name of published events.
Returns:
the Response with all registered ContextPublisher s that publish events with specified name.

getProcessors

javax.ws.rs.core.Response getProcessors(java.lang.String eventName)
Returns a Response with all registered ContextProcessors that process events with specified name.

Parameters:
eventName - the name of processed events.
Returns:
the Response with all registered ContextProcessor s that process events with specified name.

getQueries

javax.ws.rs.core.Response getQueries(java.lang.String eventName)
Returns a Response with all non-destroyed ContextQuerys that listen on events with specified name.

Parameters:
eventName - the name of listened events.
Returns:
the Response with all registered ContextQuery s that listen on events with specified name.

getPublishers

javax.ws.rs.core.Response getPublishers()
Returns a Response with all registered ContextPublishers.

Returns:
the Response with all registered ContextPublisher s.

register

javax.ws.rs.core.Response register(@Context
                                   javax.ws.rs.core.UriInfo uriInfo,
                                   RESTfulPublisher publisher)
Registers specified RESTfulPublisher.

Parameters:
uriInfo - the UriInfo to create URI to registered RESTfulPublisher.
publisher - the RESTfulPublisher.
Returns:
the Response.

getPublisher

javax.ws.rs.core.Response getPublisher(java.lang.String sourceID)
Returns a Response with registered ContextPublisher that has specified source ID.

Parameters:
sourceID - the source ID of the ContextPublisher.
Returns:
the Response with registered ContextPublisher with specified source ID.

publish

javax.ws.rs.core.Response publish(java.lang.String sourceID,
                                  Event event)
Publishes specified Event using a RESTfulPublisher that has specified source ID.

Parameters:
sourceID - the source ID of the RESTfulPublisher.
event - the Event to be published.
Returns:
the Response.

unregisterPublisher

javax.ws.rs.core.Response unregisterPublisher(java.lang.String sourceID)
Unregisters specified RESTfulPublisher.

Parameters:
sourceID - the source ID of the RESTfulPublisher.
Returns:
the Response with unregistered RESTfulPublisher.

getProcessors

javax.ws.rs.core.Response getProcessors()
Returns a Response with all registered ContextProcessors.

Returns:
the Response with all registered ContextProcessor s.

getProcessor

javax.ws.rs.core.Response getProcessor(java.lang.String name)
Returns a Response with registered ContextProcessor that has specified name.

Parameters:
name - the name of the ContextProcessor.
Returns:
the Response with registered ContextProcessor with specified name.

getQueries

javax.ws.rs.core.Response getQueries()
Returns a Response with all non-destroyed ContextQuerys.

Returns:
the Response with all non-destroyed ContextQuery s.

create

javax.ws.rs.core.Response create(@Context
                                 javax.ws.rs.core.UriInfo uriInfo,
                                 ProcessedEventQuery query)
Creates specified ProcessedEventQuery.

Parameters:
uriInfo - the UriInfo to create URI to registered ProcessedEventQuery.
query - the ProcessedEventQuery.
Returns:
the Response.

getQuery

javax.ws.rs.core.Response getQuery(java.lang.String name)
Returns a Response with non-destroyed ContextQuery that has specified name.

Parameters:
name - the name of the ContextQuery.
Returns:
the Response with non-destroyed ContextQuery with specified name.

destroy

javax.ws.rs.core.Response destroy(java.lang.String name)
Destroys specified ContextQuery.

Parameters:
name - the name of ContextQuery.
Returns:
the Response with destroyed ContextQuery.

getListeners

javax.ws.rs.core.Response getListeners(java.lang.String queryName)
Returns a Response with all ContextListeners that are registered with ContextQuery that has specified query name.

Parameters:
queryName - the name of the ContextQuery.
Returns:
the Response with all ContextListeners that are registered with ContextQuery that has specified name.

register

javax.ws.rs.core.Response register(@Context
                                   javax.ws.rs.core.UriInfo uriInfo,
                                   java.lang.String queryName,
                                   RESTfulListener listener)
Registers specified RESTfulListener with ContextQuery that has specified query name.

Parameters:
uriInfo - the UriInfo to create URI to registered RESTfulListener.
queryName - the name of the ContextQuery.
listener - the RESTfulListener.
Returns:
the Response.

getListener

javax.ws.rs.core.Response getListener(java.lang.String queryName,
                                      java.lang.String name)
Returns a Response with a ContextListener that has specified name and is registered with ContextQuery that has specified query name.

Parameters:
queryName - the name of the ContextQuery.
name - the name of the ContextListener.
Returns:
the Response with the ContextListener that has specified name and is registered with ContextQuery that has specified query name.

unregisterListener

javax.ws.rs.core.Response unregisterListener(java.lang.String queryName,
                                             java.lang.String name)
Unregisters specified RESTfulListener from ContextQuery that has specified query name.

Parameters:
queryName - the name of the ContextQuery.
name - the name of the ContextListener.
Returns:
the Response with unregistered RESTfulListener.


Copyright © 2010 Distributed Systems Group, Vienna University of Technology. All Rights Reserved.