edu.indiana.iucbrf.domain.componentfactory
Class AbstractComponentFactory

java.lang.Object
  extended by edu.indiana.iucbrf.domain.componentfactory.AbstractComponentFactory
All Implemented Interfaces:
ComponentFactory, java.io.Serializable
Direct Known Subclasses:
StandardComponentFactory

public abstract class AbstractComponentFactory
extends java.lang.Object
implements ComponentFactory

Provides some basic abstract implementations of ComponentFactory methods.

See Also:
Serialized Form

Field Summary
protected  Domain domain
           
 
Constructor Summary
AbstractComponentFactory()
           
 
Method Summary
 Feature constructFeature(FeatureKey featureKey, double value, FeatureSpecCollection fsc)
          Construct a feature at the given position in the given feature type collection, with the given value.
 Feature constructFeature(FeatureKey featureKey, java.lang.Object[] arguments, FeatureSpecCollection fsc)
           
 Feature constructFeature(FeatureKey featureKey, java.lang.Object value, FeatureSpecCollection fsc)
          Construct a feature at the given position in the given feature type collection, with the given value.
 FeatureCollection constructFeatureCollection(FeatureKey[] keys, java.lang.Object[][] arguments, int collectionType)
           
 FeatureCollection constructFeatureCollection(int collectionType)
           
 FeatureKey[] constructFeatureKeys(int length)
           
 Problem constructProblem()
           
 Problem constructProblem(double[] allFeatureValues)
           
 Problem constructProblem(DoubleCollection someFeatureValues)
           
 Feature constructProblemFeature(FeatureKey featureKey, double value)
          Construct a problem feature for a given position in a problem feature type collection.
 Feature constructProblemFeature(FeatureKey featureKey, java.lang.Object value)
          Construct a problem feature for a given position in a problem feature type collection.
 Feature constructProblemFeature(FeatureKey featureKey, java.lang.Object[] arguments)
           
 RunningAggregate constructRunningAggregate(FeatureKey key)
           
 RunningAggregate constructRunningAggregate(int varType)
           
 Solution constructSolution()
           
 Solution constructSolution(double featureValue)
          Construct a solution in this domain.
 Solution constructSolution(double[] featureValues)
           
 Solution constructSolution(DoubleCollection someFeatureValues)
           
 Feature constructSolutionFeature(FeatureKey featureKey, double value)
          Construct a solution feature for a given position in a solution feature type collection.
 Feature constructSolutionFeature(FeatureKey featureKey, java.lang.Object value)
          Construct a solution feature for a given position in a solution feature type collection.
 Feature constructSolutionFeature(FeatureKey featureKey, java.lang.Object[] arguments)
           
 void setDomain(Domain domain)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface edu.indiana.iucbrf.domain.componentfactory.ComponentFactory
constructCCBRFeatureSpec, constructFeatureCollection, constructFeatureCollection, constructFeatureCollection, constructFeatureSpec, constructProblem, constructProblemFeatureSpecCollection, constructProblemFeatureSpecCollection, constructProblemFeatureSpecCollection, constructQuestion, constructSolution, constructSolutionFeatureSpecCollection, constructSolutionFeatureSpecCollection
 

Field Detail

domain

protected Domain domain
Constructor Detail

AbstractComponentFactory

public AbstractComponentFactory()
Method Detail

setDomain

public void setDomain(Domain domain)
Specified by:
setDomain in interface ComponentFactory

constructProblem

public Problem constructProblem()
Specified by:
constructProblem in interface ComponentFactory

constructProblem

public Problem constructProblem(double[] allFeatureValues)
Specified by:
constructProblem in interface ComponentFactory

constructProblem

public Problem constructProblem(DoubleCollection someFeatureValues)
Specified by:
constructProblem in interface ComponentFactory

constructSolution

public Solution constructSolution()
Specified by:
constructSolution in interface ComponentFactory

constructSolution

public Solution constructSolution(double featureValue)
Construct a solution in this domain. The Solution class must have a 0-arg constructor, and have only 1 feature. Furthermore, that feature must implement DoubleRepresentable.

Specified by:
constructSolution in interface ComponentFactory

constructSolution

public Solution constructSolution(double[] featureValues)
Specified by:
constructSolution in interface ComponentFactory

constructSolution

public Solution constructSolution(DoubleCollection someFeatureValues)
Specified by:
constructSolution in interface ComponentFactory

constructFeatureCollection

public FeatureCollection constructFeatureCollection(FeatureKey[] keys,
                                                    java.lang.Object[][] arguments,
                                                    int collectionType)
Specified by:
constructFeatureCollection in interface ComponentFactory

constructFeatureCollection

public FeatureCollection constructFeatureCollection(int collectionType)
Specified by:
constructFeatureCollection in interface ComponentFactory

constructProblemFeature

public Feature constructProblemFeature(FeatureKey featureKey,
                                       java.lang.Object value)
Construct a problem feature for a given position in a problem feature type collection. The problem feature type at featureKey must have a 0-arg contructor.

Specified by:
constructProblemFeature in interface ComponentFactory

constructProblemFeature

public Feature constructProblemFeature(FeatureKey featureKey,
                                       java.lang.Object[] arguments)
Specified by:
constructProblemFeature in interface ComponentFactory

constructProblemFeature

public Feature constructProblemFeature(FeatureKey featureKey,
                                       double value)
Construct a problem feature for a given position in a problem feature type collection. The problem feature type at featureKey must have a 0-arg contructor and implement DoubleRepresentable.

Specified by:
constructProblemFeature in interface ComponentFactory

constructSolutionFeature

public Feature constructSolutionFeature(FeatureKey featureKey,
                                        java.lang.Object value)
Construct a solution feature for a given position in a solution feature type collection. The solution feature type at featureKey must have a 0-arg constructor.

Specified by:
constructSolutionFeature in interface ComponentFactory

constructSolutionFeature

public Feature constructSolutionFeature(FeatureKey featureKey,
                                        java.lang.Object[] arguments)
Specified by:
constructSolutionFeature in interface ComponentFactory

constructSolutionFeature

public Feature constructSolutionFeature(FeatureKey featureKey,
                                        double value)
Construct a solution feature for a given position in a solution feature type collection. The solution feature type at featureKey must have a 0-arg contructor and implement DoubleRepresentable.

Specified by:
constructSolutionFeature in interface ComponentFactory

constructFeature

public Feature constructFeature(FeatureKey featureKey,
                                java.lang.Object value,
                                FeatureSpecCollection fsc)
Construct a feature at the given position in the given feature type collection, with the given value.

Specified by:
constructFeature in interface ComponentFactory

constructFeature

public Feature constructFeature(FeatureKey featureKey,
                                double value,
                                FeatureSpecCollection fsc)
Construct a feature at the given position in the given feature type collection, with the given value.

Specified by:
constructFeature in interface ComponentFactory

constructFeature

public Feature constructFeature(FeatureKey featureKey,
                                java.lang.Object[] arguments,
                                FeatureSpecCollection fsc)
Specified by:
constructFeature in interface ComponentFactory

constructRunningAggregate

public RunningAggregate constructRunningAggregate(FeatureKey key)
Specified by:
constructRunningAggregate in interface ComponentFactory

constructRunningAggregate

public RunningAggregate constructRunningAggregate(int varType)
Specified by:
constructRunningAggregate in interface ComponentFactory

constructFeatureKeys

public FeatureKey[] constructFeatureKeys(int length)
Specified by:
constructFeatureKeys in interface ComponentFactory