org.apache.hivemind.lib.strategy
Class StrategyFactory

java.lang.Object
  extended by org.apache.hivemind.lib.strategy.StrategyFactory
All Implemented Interfaces:
org.apache.hivemind.ServiceImplementationFactory

public class StrategyFactory
extends java.lang.Object
implements org.apache.hivemind.ServiceImplementationFactory

Implementation of the hivemind.lib.StrategyFactory service that constructs a service where the first parameter of each method is used to selecte a strategy from an StrategyRegistry. The method invocation is then delegated to the strategy instance.

The service factory parameter defines a configuration (of StrategyContributions) that provide the mapping from Java classes (or interfaces) to adapter instances.

Since:
1.1
Author:
Howard M. Lewis Ship

Constructor Summary
StrategyFactory()
           
 
Method Summary
 java.lang.Object createCoreServiceImplementation(org.apache.hivemind.ServiceImplementationFactoryParameters factoryParameters)
           
 void setClassFactory(org.apache.hivemind.service.ClassFactory classFactory)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StrategyFactory

public StrategyFactory()
Method Detail

createCoreServiceImplementation

public java.lang.Object createCoreServiceImplementation(org.apache.hivemind.ServiceImplementationFactoryParameters factoryParameters)
Specified by:
createCoreServiceImplementation in interface org.apache.hivemind.ServiceImplementationFactory

setClassFactory

public void setClassFactory(org.apache.hivemind.service.ClassFactory classFactory)