showMol
Class Atom

java.lang.Object
  extended by showMol.Atom

public class Atom
extends java.lang.Object

Atom contains the coordinate and display properties for an atom.

Version:
1.0
Author:
David N. Blauch

Field Summary
protected static javax.vecmath.Color3f BLACK
           
protected static javax.vecmath.Color3f WHITE
           
protected  double x
           
protected  double y
           
protected  double z
           
 
Constructor Summary
Atom()
          The default constructor creates an Atom object for an unspecified element (X) located at the origin.
Atom(int Z, double xx, double yy, double zz)
          The Atom object is created for the element identified by its atomic number at the specified location.
Atom(java.lang.String sym, double xx, double yy, double zz)
          The Atom object is created for the element identified by its symbol at the specified location.
 
Method Summary
 int getAtomicNumber()
          Provides the atomic number of the atom.
 javax.media.j3d.TransformGroup getBallAndStickTransformGroup()
          Provides the TransformGroup for the Ball and Stick representation of the atom.
 float getCovalentRadius()
          Provides the covalent radius (in angstroms) for the atom.
 javax.vecmath.Color3f getCPKColor()
          Provides the Color3f object for the atom's CPK color.
 javax.media.j3d.TransformGroup getSpaceFillingTransformGroup()
          Provides the TransformGroup for the Space Filling representation of the atom.
 java.lang.String getSymbol()
          Provides the atomic symbol for this atom
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

x

protected double x

y

protected double y

z

protected double z

BLACK

protected static javax.vecmath.Color3f BLACK

WHITE

protected static javax.vecmath.Color3f WHITE
Constructor Detail

Atom

public Atom()
The default constructor creates an Atom object for an unspecified element (X) located at the origin.


Atom

public Atom(java.lang.String sym,
            double xx,
            double yy,
            double zz)
The Atom object is created for the element identified by its symbol at the specified location. If parameters are not available for the specified atom, parameters for the generic atom (X) are used.

Parameters:
sym - symbol for the element (case insensitive)
xx - position along x axis
yy - position along y axis
zz - position along z axis

Atom

public Atom(int Z,
            double xx,
            double yy,
            double zz)
The Atom object is created for the element identified by its atomic number at the specified location. If parameters are not available for the specified atom, parameters for the generic atom (X) are used.

Parameters:
Z - atomic number
xx - position along x axis
yy - position along y axis
zz - position along z axis
Method Detail

getAtomicNumber

public int getAtomicNumber()
Provides the atomic number of the atom.

Returns:
atomic number

getBallAndStickTransformGroup

public javax.media.j3d.TransformGroup getBallAndStickTransformGroup()
Provides the TransformGroup for the Ball and Stick representation of the atom.

Returns:
TransformGroup for the Ball and Stick ball

getCovalentRadius

public float getCovalentRadius()
Provides the covalent radius (in angstroms) for the atom.

Returns:
covalent radius

getCPKColor

public javax.vecmath.Color3f getCPKColor()
Provides the Color3f object for the atom's CPK color.

Returns:
CPK color

getSpaceFillingTransformGroup

public javax.media.j3d.TransformGroup getSpaceFillingTransformGroup()
Provides the TransformGroup for the Space Filling representation of the atom.

Returns:
TransformGroup for the space filling sphere

getSymbol

public java.lang.String getSymbol()
Provides the atomic symbol for this atom

Returns:
atomic symbol