org.eclipse.ocl.examples.pivot.manager
Class ImplementationManager

java.lang.Object
  extended by org.eclipse.ocl.examples.pivot.manager.ImplementationManager

public class ImplementationManager
extends java.lang.Object

ImplementationManager encapsulates the knowledge about known feature implementations.


Nested Class Summary
static interface ImplementationManager.ExplicitNavigator
           
 
Field Summary
protected  MetaModelManager metaModelManager
           
 
Constructor Summary
protected ImplementationManager(MetaModelManager metaModelManager)
           
 
Method Summary
 void addClassLoader(java.lang.ClassLoader classLoader)
           
static void addExplicitNavgator(ImplementationManager.ExplicitNavigator explicitNavigator)
           
 void dispose()
           
 java.util.List<java.lang.ClassLoader> getClassLoaders()
           
protected  LibraryOperation getOperationImplementation(Operation operation)
           
protected  LibraryProperty getPropertyImplementation(java.lang.Object sourceValue, Property property)
           
 LibraryFeature loadImplementation(Feature feature)
          Return the implementation of a feature.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

metaModelManager

@NonNull
protected final MetaModelManager metaModelManager
Constructor Detail

ImplementationManager

protected ImplementationManager(@NonNull
                                MetaModelManager metaModelManager)
Method Detail

addExplicitNavgator

public static void addExplicitNavgator(@NonNull
                                       ImplementationManager.ExplicitNavigator explicitNavigator)

addClassLoader

public void addClassLoader(@NonNull
                           java.lang.ClassLoader classLoader)

getClassLoaders

@NonNull
public java.util.List<java.lang.ClassLoader> getClassLoaders()

getOperationImplementation

@NonNull
protected LibraryOperation getOperationImplementation(@NonNull
                                                              Operation operation)

getPropertyImplementation

@NonNull
protected LibraryProperty getPropertyImplementation(@Nullable
                                                            java.lang.Object sourceValue,
                                                            @NonNull
                                                            Property property)

dispose

public void dispose()

loadImplementation

@Nullable
public LibraryFeature loadImplementation(@NonNull
                                                  Feature feature)
                                  throws java.lang.ClassNotFoundException,
                                         java.lang.SecurityException,
                                         java.lang.NoSuchFieldException,
                                         java.lang.IllegalArgumentException,
                                         java.lang.IllegalAccessException
Return the implementation of a feature.

Parameters:
feature - to be implemented.
Returns:
the implementation, or null if the feature has no implementation as is the case for a normal model feature
Throws:
java.lang.ClassNotFoundException - if the implementation class realising the implementation is not loadable
java.lang.NoSuchFieldException - if the implementation class realising the implementation does not provide a static INSTANCE field
java.lang.SecurityException - if the implementation class is not accessible
java.lang.IllegalAccessException - if the implementation class is not accessible
java.lang.IllegalArgumentException - if the implementation class is not accessible