FreeHEP API
Version current

hep.graphics.heprep
Class HepRepFactory

java.lang.Object
  extended byhep.graphics.heprep.HepRepFactory
Direct Known Subclasses:
DefaultHepRepFactory

public abstract class HepRepFactory
extends Object

HepRepFactory interface.

Author:
Mark Donszelmann
Source Code:
HepRepFactory.java

Field Summary
static String defaultFactoryName
          Default HepRep factory classname.
static String factoryName
          Name of the interface for factory for HepRep.
static String propertyFile
          Properties filename to find out what factory to load for HepRep.
 
Constructor Summary
HepRepFactory()
           
 
Method Summary
static HepRepFactory create()
          Creates a heprep factory based on the content of heprep.properties file.
abstract  HepRep createHepRep()
          Creates a HepRep.
abstract  HepRepAction createHepRepAction(String name, String expression)
          Creates a HepRepAction.
abstract  HepRepInstance createHepRepInstance(HepRepInstance parent, HepRepType type)
          Creates a HepRepInstance.
abstract  HepRepInstance createHepRepInstance(HepRepInstanceTree parent, HepRepType type)
          Creates a HepRepInstance.
abstract  HepRepInstanceTree createHepRepInstanceTree(String name, String version, HepRepTreeID typeTree)
          Creates a HepRepInstanceTree.
abstract  HepRepPoint createHepRepPoint(HepRepInstance instance, double x, double y, double z)
          Creates a HepRepPoint.
abstract  HepRepReader createHepRepReader(InputStream in)
          Creates a HepRepReader from a stream.
abstract  HepRepReader createHepRepReader(String inputFileName)
          Creates a HepRepReader from a file name.
 HepRepTreeID createHepRepTreeID(String name, String version)
          Creates a HepRepTreeID.
abstract  HepRepTreeID createHepRepTreeID(String name, String version, String qualifier)
          Creates a HepRepTreeID.
abstract  HepRepType createHepRepType(HepRepType parent, String name)
          Creates a HepRepType.
abstract  HepRepType createHepRepType(HepRepTypeTree parent, String name)
          Creates a HepRepType.
abstract  HepRepTypeTree createHepRepTypeTree(HepRepTreeID treeID)
          Creates a HepRepTypeTree.
abstract  HepRepWriter createHepRepWriter(OutputStream out, boolean randomAccess, boolean compress)
          Creates a HepRepWriter.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

factoryName

public static final String factoryName
Name of the interface for factory for HepRep.

See Also:
Constant Field Values

propertyFile

public static final String propertyFile
Properties filename to find out what factory to load for HepRep.

See Also:
Constant Field Values

defaultFactoryName

public static final String defaultFactoryName
Default HepRep factory classname.

See Also:
Constant Field Values
Constructor Detail

HepRepFactory

public HepRepFactory()
Method Detail

create

public static HepRepFactory create()
                            throws ClassNotFoundException,
                                   IllegalAccessException,
                                   InstantiationException
Creates a heprep factory based on the content of heprep.properties file. If not found the default HepRepFactory is created.

Returns:
HepRepFactory.
Throws:
ClassNotFoundException
IllegalAccessException
InstantiationException

createHepRepReader

public abstract HepRepReader createHepRepReader(InputStream in)
                                         throws IOException
Creates a HepRepReader from a stream.

Parameters:
in - input stream.
Throws:
IOException

createHepRepReader

public abstract HepRepReader createHepRepReader(String inputFileName)
                                         throws IOException
Creates a HepRepReader from a file name.

Parameters:
inputFileName - file name.
Throws:
IOException

createHepRepWriter

public abstract HepRepWriter createHepRepWriter(OutputStream out,
                                                boolean randomAccess,
                                                boolean compress)
                                         throws IOException
Creates a HepRepWriter.

Parameters:
out - output stream.
randomAccess - create a writer in a format that will allow random access (may be ignored).
compress - create a writer that uses compression (may be ignored).
Throws:
IOException

createHepRepPoint

public abstract HepRepPoint createHepRepPoint(HepRepInstance instance,
                                              double x,
                                              double y,
                                              double z)
Creates a HepRepPoint.

Parameters:
instance - to add the point to.
x - x coordinate of point.
y - y coordinate of point.
z - z coordinate of point.

createHepRepInstance

public abstract HepRepInstance createHepRepInstance(HepRepInstance parent,
                                                    HepRepType type)
Creates a HepRepInstance.

Parent:
to add the instance to.
Type:
type the associated type.

createHepRepInstance

public abstract HepRepInstance createHepRepInstance(HepRepInstanceTree parent,
                                                    HepRepType type)
Creates a HepRepInstance.

Parent:
to add the instance to.
Type:
type the associated type.

createHepRepTreeID

public HepRepTreeID createHepRepTreeID(String name,
                                       String version)
Creates a HepRepTreeID.

Parameters:
name - of the treeID.
version - of the treeID.

createHepRepTreeID

public abstract HepRepTreeID createHepRepTreeID(String name,
                                                String version,
                                                String qualifier)
Creates a HepRepTreeID.

Parameters:
name - of the treeID.
version - of the treeID.
qualifier - of the treeID.

createHepRepAction

public abstract HepRepAction createHepRepAction(String name,
                                                String expression)
Creates a HepRepAction.

Parameters:
name - of the action.
expression - of the action.

createHepRepInstanceTree

public abstract HepRepInstanceTree createHepRepInstanceTree(String name,
                                                            String version,
                                                            HepRepTreeID typeTree)
Creates a HepRepInstanceTree.

The tree needs to be added to the HepRep.

Parameters:
name - of the instancetree.
version - of the instancetree.
typeTree - associated typetree.

createHepRepType

public abstract HepRepType createHepRepType(HepRepTypeTree parent,
                                            String name)
Creates a HepRepType.

Parameters:
parent - to add this type to.
name - of the type to create.

createHepRepType

public abstract HepRepType createHepRepType(HepRepType parent,
                                            String name)
Creates a HepRepType.

Parameters:
parent - to add this type to.
name - of the type to create.

createHepRepTypeTree

public abstract HepRepTypeTree createHepRepTypeTree(HepRepTreeID treeID)
Creates a HepRepTypeTree.

The tree needs to be added to the HepRep.

Parameters:
treeID - to name the tree being created.

createHepRep

public abstract HepRep createHepRep()
Creates a HepRep.


FreeHEP API
Version current

Copyright © 2000-2004 FreeHEP, All Rights Reserved.