org.apache.tuscany.sca.core.scope
Interface ScopedImplementationProvider

All Superinterfaces:
ImplementationProvider
All Known Implementing Classes:
JavaImplementationProvider, OSGiImplementationProvider

public interface ScopedImplementationProvider
extends ImplementationProvider

A component implementation can implement this interface to provide scope management for the components


Method Summary
 InstanceWrapper createInstanceWrapper()
          Create a wrapper for the component instance for the scope management
 long getMaxAge()
           
 long getMaxIdleTime()
           
 Scope getScope()
          Get the scope for the component implementation
 boolean isEagerInit()
          Indicate if the component needs to be eagerly initialized
 
Methods inherited from interface org.apache.tuscany.sca.provider.ImplementationProvider
createInvoker, start, stop, supportsOneWayInvocation
 

Method Detail

getScope

Scope getScope()
Get the scope for the component implementation

Returns:
The scope for the component implementation, if null is returned, STATELESS will be used

isEagerInit

boolean isEagerInit()
Indicate if the component needs to be eagerly initialized

Returns:
true if the component is marked to be eagerly initialized, false otherwise

getMaxAge

long getMaxAge()
Returns:
the maxAge

getMaxIdleTime

long getMaxIdleTime()
Returns:
the maxIdleTime

createInstanceWrapper

InstanceWrapper createInstanceWrapper()
Create a wrapper for the component instance for the scope management

Returns:
A wrapper for the component instance