java.lang.Object
feynman.framework.system.PhysicalSystemFactory
- public class PhysicalSystemFactory
- extends java.lang.Object
Factory to create differenct types of PhysicalSystems.
- Version:
- $Revision: 1.1.1.1 $ $Date: 2002/11/12 02:25:43 $
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
INSTANCE
private static final PhysicalSystemFactory INSTANCE
PhysicalSystemFactory
private PhysicalSystemFactory()
getInstance
public static final PhysicalSystemFactory getInstance()
- Method used to retrieve an instance of the factory class.
create
public static PhysicalSystem create(feynman.framework.simulation.Simulation simulation)
throws PhysicalSystemFactoryException
- Note: This method is used by the feynman.framework.Controller.
Unless you are not using those classes to build your simulation, you should
not have to use this factory class directly. If you do, then follow the
instructions given below.
Use this method to create a PhysicalSystem of PhysicalObjects.
The className is the name of the class to be instantiated for the
type of physical system to be created. For example, if the client wants to
to create a system included in the framework, then the following call to this
factory will work:
Simulation simulation = Marshaller.unmarshall("MyProps.properties");
PhysicalSystemFactory sf = PhysicalSystemFactory.getInstance();
PhysicalSystem ps = sf.create(simulation);