org.apache.felix.ipojo.api.composite
Class ProvidedService

java.lang.Object
  extended by org.apache.felix.ipojo.api.composite.ProvidedService
All Implemented Interfaces:
HandlerConfiguration

public class ProvidedService
extends Object
implements HandlerConfiguration

Allows defining a provided service. A provided service is a service 'implemented' by the composite. This implementations relies (by delegation) on contained instances and services.

Author:
Felix Project Team

Field Summary
static String ALL_POLICY
          Delegation policy: all.
static String ONE_POLICY
          Delegation policy: one.
 
Constructor Summary
ProvidedService()
           
 
Method Summary
 Element getElement()
          Gets the provided element.
 ProvidedService setDelegation(String method, String policy)
          Sets the delegation policy of the given method.
 ProvidedService setSpecification(String spec)
          Sets the provided service specification.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ALL_POLICY

public static final String ALL_POLICY
Delegation policy: all.

See Also:
Constant Field Values

ONE_POLICY

public static final String ONE_POLICY
Delegation policy: one.

See Also:
Constant Field Values
Constructor Detail

ProvidedService

public ProvidedService()
Method Detail

getElement

public Element getElement()
Gets the provided element.

Specified by:
getElement in interface HandlerConfiguration
Returns:
the 'provides' element describing the current provided service.

setSpecification

public ProvidedService setSpecification(String spec)
Sets the provided service specification.

Parameters:
spec - the specification
Returns:
the current provided service.

setDelegation

public ProvidedService setDelegation(String method,
                                     String policy)
Sets the delegation policy of the given method.

Parameters:
method - the method name
policy - the delegation policy
Returns:
the current exported service.


Copyright © 2011 Apache Software Foundation. All Rights Reserved.