org.jscience.physics.solids
Class AtlasModel

java.lang.Object
  extended by org.jscience.physics.solids.AtlasModel

public class AtlasModel
extends java.lang.Object

DOCUMENT ME!


Constructor Summary
AtlasModel()
          Creates a new AtlasModel object.
AtlasModel(java.lang.String name)
          Creates a new instance of AtlasModel.
AtlasModel(java.lang.String name, AtlasPreferences prefer)
          Creates a new instance of AtlasModel.
 
Method Summary
 void addObject(AtlasObject o)
          Adds the specified object to this model.
 void clear()
          Removes all enitites from the model.
 AtlasObject[] getAllObjects()
          Returns all of the entities in the model.
 AtlasObject[] getAllObjects(java.lang.String type)
          Returns all of the entities of a specified type.
 java.lang.String[] getAllObjectTypes()
          Returns all of the types in this model.
 AtlasConstraint[] getConstraints()
          Returns all constraint objects in this model.
 AtlasElement[] getElements()
          Returns all finite element objects in this model.
 AtlasLoad[] getLoads()
          Returns all applied load objects in this model.
 AtlasMaterial getMaterial(java.lang.String matId)
          Returns material specified by id, or null if it cannot be found.
 AtlasMaterial[] getMaterials()
          Returns all material objects in this model.
 java.lang.String getName()
          Returns the name of the model.
 AtlasNode getNode(java.lang.String nid)
          Retursn the specified node, or null if it cannot be found.
 AtlasNode[] getNodes()
          Returns all of the nodes in the model.
 AtlasObject getObject(java.lang.String type, java.lang.String id)
          Returns the object, or null if ot cannot be found
 AtlasPreferences getPref()
          DOCUMENT ME!
 SolutionMatrices getSolutionMatrices()
          Returns populated solution matrices.
static void main(java.lang.String[] args)
          Method to test reading in an XML file.
 void populateGeometry(javax.media.j3d.BranchGroup geometryRoot)
          Returns BranchGroup needed to visualize this model.
 void readXML(java.lang.String filename)
          Loads a model from an XML file.
 void setName(java.lang.String name)
          Sets the name of the model.
 void setPref(AtlasPreferences pref)
          DOCUMENT ME!
 java.lang.String toString()
          Convenience method to print out information about the model.
 void writeXML(java.lang.String filename)
          DOCUMENT ME!
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AtlasModel

public AtlasModel()
Creates a new AtlasModel object.


AtlasModel

public AtlasModel(java.lang.String name)
Creates a new instance of AtlasModel.


AtlasModel

public AtlasModel(java.lang.String name,
                  AtlasPreferences prefer)
Creates a new instance of AtlasModel.

Method Detail

getName

public java.lang.String getName()
Returns the name of the model.

Returns:
DOCUMENT ME!

setName

public void setName(java.lang.String name)
Sets the name of the model.

Parameters:
name - DOCUMENT ME!

addObject

public void addObject(AtlasObject o)
Adds the specified object to this model. If there is an existing entity with the same ID and TYPE, then it is replaced.

Parameters:
o - DOCUMENT ME!

getAllObjectTypes

public java.lang.String[] getAllObjectTypes()
Returns all of the types in this model.

Returns:
DOCUMENT ME!

getAllObjects

public AtlasObject[] getAllObjects()
Returns all of the entities in the model.

Returns:
DOCUMENT ME!

getAllObjects

public AtlasObject[] getAllObjects(java.lang.String type)
Returns all of the entities of a specified type.

Parameters:
type - DOCUMENT ME!
Returns:
DOCUMENT ME!

getObject

public AtlasObject getObject(java.lang.String type,
                             java.lang.String id)
Returns the object, or null if ot cannot be found

Parameters:
type - DOCUMENT ME!
id - DOCUMENT ME!
Returns:
DOCUMENT ME!

toString

public java.lang.String toString()
Convenience method to print out information about the model.

Overrides:
toString in class java.lang.Object
Returns:
DOCUMENT ME!

getNodes

public AtlasNode[] getNodes()
Returns all of the nodes in the model.

Returns:
DOCUMENT ME!

getNode

public AtlasNode getNode(java.lang.String nid)
Retursn the specified node, or null if it cannot be found.

Parameters:
nid - DOCUMENT ME!
Returns:
DOCUMENT ME!

getElements

public AtlasElement[] getElements()
Returns all finite element objects in this model. This is not terribly efficient yet...

Returns:
DOCUMENT ME!

getLoads

public AtlasLoad[] getLoads()
Returns all applied load objects in this model. This is not terribly efficient yet...

Returns:
DOCUMENT ME!

getConstraints

public AtlasConstraint[] getConstraints()
Returns all constraint objects in this model. This is not terribly efficient yet...

Returns:
DOCUMENT ME!

getMaterials

public AtlasMaterial[] getMaterials()
Returns all material objects in this model. This is not terribly efficient yet...

Returns:
DOCUMENT ME!

getMaterial

public AtlasMaterial getMaterial(java.lang.String matId)
Returns material specified by id, or null if it cannot be found.

Parameters:
matId - DOCUMENT ME!
Returns:
DOCUMENT ME!

getSolutionMatrices

public SolutionMatrices getSolutionMatrices()
Returns populated solution matrices.

Returns:
DOCUMENT ME!

clear

public void clear()
Removes all enitites from the model.


writeXML

public void writeXML(java.lang.String filename)
              throws java.io.IOException
DOCUMENT ME!

Parameters:
filename - DOCUMENT ME!
Throws:
java.io.IOException - DOCUMENT ME!

readXML

public void readXML(java.lang.String filename)
             throws java.io.IOException
Loads a model from an XML file. NOTE: this will clear the model out... this might change in the future- I'm just trying to get something to work right now.

Parameters:
filename - DOCUMENT ME!
Throws:
java.io.IOException - DOCUMENT ME!

main

public static void main(java.lang.String[] args)
Method to test reading in an XML file.

Parameters:
args - DOCUMENT ME!

populateGeometry

public void populateGeometry(javax.media.j3d.BranchGroup geometryRoot)
Returns BranchGroup needed to visualize this model.

Parameters:
geometryRoot - DOCUMENT ME!

getPref

public AtlasPreferences getPref()
DOCUMENT ME!

Returns:
Returns the pref.

setPref

public void setPref(AtlasPreferences pref)
DOCUMENT ME!

Parameters:
pref - The pref to set.