org.objectweb.proactive.core.component
Class Fractive

java.lang.Object
  extended byorg.objectweb.proactive.core.component.Fractive
All Implemented Interfaces:
Component, Factory, GenericFactory

public class Fractive
extends java.lang.Object
implements GenericFactory, Component, Factory

This class is used for creating components. It acts as :

  1. a bootstrap component
  2. a GenericFactory for instantiating new components
  3. a utility class providing static methods to create collective interfaces and retreive references to ComponentParametersController

Author:
Matthieu Morel

Constructor Summary
Fractive()
          no-arg constructor (used by Fractal to get a bootstrap component)
 
Method Summary
static ProActiveInterface createCollectiveClientInterface(java.lang.String itfName, java.lang.String itfSignature)
          Method createCollectiveClientInterface.
static ProActiveInterface createCollectiveClientInterface(java.lang.String itfName, java.lang.String itfSignature, Component owner)
          Returns a generated interface reference, whose impl field is a group It is able to handle multiple bindings
static InterfaceType[] getClientInterfaceTypes(ComponentType componentType)
          Helper method for extracting the types of client interfaces from the type of a component
static ComponentParametersController getComponentParametersController(Component component)
          Returns the ContentController interface of the given component.
static Component getComponentRepresentativeOnThis()
          Returns a component representative pointing to the component associated to the component whose active thread is calling this method.
 java.lang.Object getFcContentDesc()
          see Factory.getFcContentDesc()
 java.lang.Object getFcControllerDesc()
          see Factory.getFcControllerDesc()
 Type getFcInstanceType()
          see Factory.getFcInstanceType()
 java.lang.Object getFcInterface(java.lang.String itfName)
          see Component.getFcInterface(java.lang.String)
 java.lang.Object[] getFcInterfaces()
          see Component.getFcInterfaces()
 Type getFcType()
          see Component.getFcType()
 Component newFcInstance()
          see Factory.newFcInstance()
 Component newFcInstance(Type arg0, java.lang.Object arg1, java.lang.Object arg2)
          see GenericFactory.newFcInstance(org.objectweb.fractal.api.Type, java.lang.Object, java.lang.Object)
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Fractive

public Fractive()
no-arg constructor (used by Fractal to get a bootstrap component)

Method Detail

getComponentParametersController

public static ComponentParametersController getComponentParametersController(Component component)
                                                                      throws NoSuchInterfaceException
Returns the ContentController interface of the given component.

Parameters:
component - a component.
Returns:
the ContentController interface of the given component.
Throws:
NoSuchInterfaceException - if there is no such interface.

createCollectiveClientInterface

public static ProActiveInterface createCollectiveClientInterface(java.lang.String itfName,
                                                                 java.lang.String itfSignature,
                                                                 Component owner)
                                                          throws ProActiveRuntimeException
Returns a generated interface reference, whose impl field is a group It is able to handle multiple bindings

Parameters:
itfName - String
itfSignature - String
owner - Component
Returns:
ProActiveInterface
Throws:
ProActiveRuntimeException

createCollectiveClientInterface

public static ProActiveInterface createCollectiveClientInterface(java.lang.String itfName,
                                                                 java.lang.String itfSignature)
                                                          throws ProActiveRuntimeException
Method createCollectiveClientInterface.

Parameters:
itfName - String
itfSignature - String
Returns:
ProActiveInterface
Throws:
ProActiveRuntimeException

newFcInstance

public Component newFcInstance(Type arg0,
                               java.lang.Object arg1,
                               java.lang.Object arg2)
                        throws InstantiationException
see GenericFactory.newFcInstance(org.objectweb.fractal.api.Type, java.lang.Object, java.lang.Object)

Specified by:
newFcInstance in interface GenericFactory
Parameters:
arg0 - Type
arg1 - Object
arg2 - Object
Returns:
Component
Throws:
InstantiationException
See Also:
GenericFactory.newFcInstance(Type, Object, Object)

getFcInterface

public java.lang.Object getFcInterface(java.lang.String itfName)
                                throws NoSuchInterfaceException
see Component.getFcInterface(java.lang.String)

Specified by:
getFcInterface in interface Component
Parameters:
itfName - String
Returns:
Object
Throws:
NoSuchInterfaceException
See Also:
Component.getFcInterface(String)

getFcInterfaces

public java.lang.Object[] getFcInterfaces()
see Component.getFcInterfaces()

Specified by:
getFcInterfaces in interface Component
Returns:
Object[]
See Also:
Component.getFcInterfaces()

getFcType

public Type getFcType()
see Component.getFcType()

Specified by:
getFcType in interface Component
Returns:
Type
See Also:
Component.getFcType()

getFcContentDesc

public java.lang.Object getFcContentDesc()
see Factory.getFcContentDesc()

Specified by:
getFcContentDesc in interface Factory
Returns:
Object
See Also:
Factory.getFcContentDesc()

getFcControllerDesc

public java.lang.Object getFcControllerDesc()
see Factory.getFcControllerDesc()

Specified by:
getFcControllerDesc in interface Factory
Returns:
Object
See Also:
Factory.getFcControllerDesc()

getFcInstanceType

public Type getFcInstanceType()
see Factory.getFcInstanceType()

Specified by:
getFcInstanceType in interface Factory
Returns:
Type
See Also:
Factory.getFcInstanceType()

newFcInstance

public Component newFcInstance()
                        throws InstantiationException
see Factory.newFcInstance()

Specified by:
newFcInstance in interface Factory
Returns:
Component
Throws:
InstantiationException
See Also:
Factory.newFcInstance()

getClientInterfaceTypes

public static InterfaceType[] getClientInterfaceTypes(ComponentType componentType)
Helper method for extracting the types of client interfaces from the type of a component

Parameters:
componentType - ComponentType
Returns:
the types of client interfacess

getComponentRepresentativeOnThis

public static Component getComponentRepresentativeOnThis()
Returns a component representative pointing to the component associated to the component whose active thread is calling this method. It can be used for a component to pass callback references to itself.

Returns:
a component representative for the component in which the current thread is running


Copyright 2001-2005 INRIA All Rights Reserved.