net.dpml.component
Interface Component

All Superinterfaces:
Commissionable, Remote
All Known Subinterfaces:
ComponentHandler

public interface Component
extends Remote, Commissionable

The Component represents a remote interface to a runtime component type.

Version:
1.0.0
Author:
Digital Product Meta Library

Method Summary
 ActivationPolicy getActivationPolicy()
          Get the activation policy.
 Provider getProvider()
          Return a provider of an instance of the component.
 boolean isaCandidate(Service service)
          Return true if this handler is a candidate for the supplied service definition.
 boolean isActive()
          Returns the commissioned status of the handler.
 int size()
          Return the number of instances currently under management.
 
Methods inherited from interface net.dpml.component.Commissionable
commission, decommission
 

Method Detail

getProvider

public Provider getProvider()
                     throws IOException,
                            InvocationTargetException
Return a provider of an instance of the component.

Returns:
the instance provider
Throws:
InvocationTargetException - if a target invocation error occurs
IOException - if a IO error occurs
InvocationTargetException - if a component invocation error occurs

isaCandidate

public boolean isaCandidate(Service service)
                     throws RemoteException
Return true if this handler is a candidate for the supplied service definition.

Parameters:
service - the service descriptor
Returns:
true if this is a candidate
Throws:
RemoteException - if a remote exception occurs

getActivationPolicy

public ActivationPolicy getActivationPolicy()
                                     throws RemoteException
Get the activation policy. If the activation policy is STARTUP, an implementation a handler shall immidiately activation a runtime instance. If the policy is on DEMAND an implementation shall defer activiation until an explicit request is received. If the policy if SYSTEM activation may occur at the discretion of an implementation.

Returns:
the activation policy
Throws:
RemoteException - if a remote exception occurs
See Also:
ActivationPolicy.SYSTEM, ActivationPolicy.STARTUP, ActivationPolicy.DEMAND

isActive

public boolean isActive()
                 throws RemoteException
Returns the commissioned status of the handler.

Returns:
TRUE if the handler has been commissioned otherwise FALSE
Throws:
RemoteException - if a remote exception occurs

size

public int size()
         throws RemoteException
Return the number of instances currently under management.

Returns:
the instance count.
Throws:
RemoteException - if a remote exception occurs