org.apache.muse.core
Interface Capability
- All Superinterfaces:
- Initialization, InitializationParameters, Shutdown
- All Known Subinterfaces:
- Advertisement, Configuration, CorrelatableProperties, Description, Entry, GetCapability, Identity, ImmediateTermination, ManageabilityCapability, ManageabilityCharacteristics, MetadataExchange, Metrics, NotificationConsumer, NotificationProducer, OperationalStatus, PullPoint, PullPointCreation, QueryCapability, RelationshipResource, Relationships, ScheduledTermination, ServiceGroup, ServiceGroupRegistration, SetCapability, State, SubscriptionManager, WsResourceCapability
- All Known Implementing Classes:
- AbstractAdvertisement, AbstractCapability, AbstractManageabilityCapability, AbstractWsResourceCapability, BroadcastAdvertisement, ServiceGroupEntryAdvertisement, SimpleAdvertisement, SimpleConfiguration, SimpleCorrelatableProperties, SimpleDescription, SimpleEntry, SimpleGetCapability, SimpleIdentity, SimpleImmediateTermination, SimpleManageabilityCharacteristics, SimpleMetadataExchange, SimpleMetrics, SimpleNotificationConsumer, SimpleNotificationProducer, SimpleOperationalStatus, SimplePullPoint, SimplePullPointCreation, SimpleQueryCapability, SimpleRelationshipResource, SimpleRelationships, SimpleScheduledTermination, SimpleServiceGroup, SimpleServiceGroupRegistration, SimpleSetCapability, SimpleState, SimpleSubscriptionManager, WsrfMetadataExchange
public interface Capability
- extends Initialization, InitializationParameters, Shutdown
Capability is the atomic unit of functional definition for a resource
type. A capability class should define a set of data and operations
that are closely-related, but do not necessarily make up the entire
definition of a resource interface. Users aggregate capabilities into
a Resource, which takes care of delegating
requests to the appropriate capabilities at runtime. Most users will
only have to interact with the pluggable nature of Muse development
through this interface and the <capability/> tag in muse.xml.
- Author:
- Dan Jemiolo (danj)
getActions
Collection getActions()
- Returns:
- All of the WS-A Action URIs for which the capability has
a MessageHandler.
- See Also:
getMessageHandler(String)
getCapabilityURI
String getCapabilityURI()
- Returns:
- The unique URI (within the resource type) that defines this
capability.
getEnvironment
Environment getEnvironment()
- Returns:
- The capability's access point for things such as the
WS-Addressing context, file system resources, and more.
getLog
Logger getLog()
- Returns:
- The JDK logger that writes to the Muse log file.
getMessageHandler
MessageHandler getMessageHandler(String action)
- Parameters:
action
-
- Returns:
- This method is called as part of the containing Resource's
method invocation process; it allows the capability to
specify the handler that will parse the request/response
for the method.
- See Also:
getActions()
getPersistence
Persistence getPersistence()
- Returns:
- The persistence mechanism for this capability, or null if none
was defined.
getResource
Resource getResource()
- Returns:
- The resource that contains this capability instance.
initializeCompleted
void initializeCompleted()
throws SoapFault
- This method is called by the containing Resource after all other
capabilities have been initialized via initialize(). It allows the
Capability to do initialization work that requires the presence of
certain other capabilities. This "post-initialization" state is
necessary because capability definition and creation is
non-deterministic, and users cannot make any assumptions about the
order of those tasks.
- Throws:
SoapFault
prepareShutdown
void prepareShutdown()
throws SoapFault
- This method is called prior to shutdown() and allows the capability
to do any shutdown tasks that require the presence of certain other
capabilities. Once shutdown() is called, the capability cannot be
certain that the other capabilities it depends on have not already
been shutdown as well, so this "pre-shutdown" state gives it this
opportunity.
- Throws:
SoapFault
setCapabilityURI
void setCapabilityURI(String capabilityURI)
setEnvironment
void setEnvironment(Environment environment)
setLog
void setLog(Logger log)
setMessageHandlers
void setMessageHandlers(Collection handlers)
setPersistence
void setPersistence(Persistence persistence)
setResource
void setResource(Resource resource)
Copyright © 2005-2011 Apache Web Services - Muse. All Rights Reserved.