Nuxeo Enterprise Platform 5.4

org.nuxeo.runtime.model
Interface ComponentInstance

All Superinterfaces:
Adaptable, ComponentContext, Extensible
All Known Implementing Classes:
ComponentInstanceImpl, RemoteComponentInstance

public interface ComponentInstance
extends ComponentContext, Extensible, Adaptable

A component instance is a proxy to the component implementation object.

Component instance objects are created each time a component is activated, and destroyed at component deactivation.

Author:
Bogdan Stefanescu

Method Summary
 void activate()
          Activates the implementation instance.
 void deactivate()
          Deactivates the implementation instance.
 void destroy()
          Destroys this instance.
 RuntimeContext getContext()
          Gets the runtime context attached to this instance.
 Object getInstance()
          Gets the actual component implementation instance.
 ComponentName getName()
          Gets the name of the component.
 String[] getProvidedServiceNames()
          Gets the list of provided services, or null if no service is provided.
 void reload()
          Reload the component.
 
Methods inherited from interface org.nuxeo.runtime.model.ComponentContext
getProperty, getPropertyNames, getPropertyValue, getPropertyValue, getRuntimeContext
 
Methods inherited from interface org.nuxeo.runtime.model.Extensible
registerExtension, unregisterExtension
 
Methods inherited from interface org.nuxeo.runtime.model.Adaptable
getAdapter
 

Method Detail

getInstance

Object getInstance()
Gets the actual component implementation instance.

Returns:
the component implementation instance

getName

ComponentName getName()
Gets the name of the component.

Returns:
the component name

getContext

RuntimeContext getContext()
Gets the runtime context attached to this instance.

Returns:
the runtime context

activate

void activate()
              throws Exception
Activates the implementation instance.

Throws:
Exception - if any error occurs during activation

deactivate

void deactivate()
                throws Exception
Deactivates the implementation instance.

Throws:
Exception - if any error occurs during deactivation

destroy

void destroy()
             throws Exception
Destroys this instance.

Throws:
Exception - if any error occurs

reload

void reload()
            throws Exception
Reload the component. All the extensions and registries are reloaded.

Throws:
Exception

getProvidedServiceNames

String[] getProvidedServiceNames()
Gets the list of provided services, or null if no service is provided.

Returns:
an array containing the service class names or null if no service is provided

Nuxeo Enterprise Platform 5.4

Copyright © 2011 Nuxeo SAS. All Rights Reserved.