Class pmr.cml.CRYSTNode
All Packages Class Hierarchy This Package Previous Next Index
Class pmr.cml.CRYSTNode
java.lang.Object
|
+----pmr.sgml.SGMLNode
|
+----pmr.sgml.DrawableSGMLNode
|
+----pmr.cml.DrawableX_Node
|
+----pmr.cml.CRYSTNode
- public class CRYSTNode
- extends DrawableX_Node
holds crystallographic data (cell parameters , spacegroup and symmetry).
NOTE: The cell lengths must be given but the angles default to right
angles
- Author:
- (C) P. Murray-Rust, 1996
-
CRYSTNode(String, SGMLTree)
-
-
addCellAngles(Angle, Angle, Angle)
- add cell angles as a Angle[3] If angles already present, returns false
without action.
-
addCellLengths(double, double, double)
- add cell lengths as a double[3] If cell already present, returns false
without action.
-
addSpacegroup(String)
- adds spacegroup as String; No checks at present, and no defined convention
-
addSpacegroupNumber(int)
- adds spacegroup as number; No checks at present.
-
addSymmetryOperator(RealMatrix)
- adds symmetry operator as 4*3 matrix; No checks at present (apart from shape).
-
createAndAdd(SGMLTree, int)
-
-
display()
- Kicks off a ScrollableTopLevel which contains the object.
-
drawIcon(Graphics, int, int)
- draw a CML icon
-
getAngles()
- get cell angles IN DEGREES or null if not present
-
getLengths()
- get cell lengths IN ANGSTROM or null if not present
-
getOrthogonalisationMatrix()
-
-
getSpacegroup()
- gets spacegroup as String; No checks at present, and no defined convention
null string ("") if not set
-
getSpacegroupNumber(int)
- gets spacegroup as number; No checks at present.
-
getSymmetryOperators()
- gets symmetry operators as an array of RealMatrix'es (3 rows, 4 columns)
-
mayContain(SGMLNode)
- can this node contain others.
-
process()
- process the data so far.
-
showHelp()
- display Help
CRYSTNode
public CRYSTNode(String giName,
SGMLTree tree)
createAndAdd
public static int createAndAdd(SGMLTree tree,
int parentIndex)
addCellLengths
public boolean addCellLengths(double a,
double b,
double c)
- add cell lengths as a double[3] If cell already present, returns false
without action. Arguments MUST BE IN ANGSTROM.
addCellAngles
public boolean addCellAngles(Angle alpha,
Angle beta,
Angle gamma)
- add cell angles as a Angle[3] If angles already present, returns false
without action.
getLengths
public double[] getLengths()
- get cell lengths IN ANGSTROM or null if not present
getAngles
public double[] getAngles()
- get cell angles IN DEGREES or null if not present
addSpacegroup
public void addSpacegroup(String spg)
- adds spacegroup as String; No checks at present, and no defined convention
addSpacegroupNumber
public void addSpacegroupNumber(int nsp)
- adds spacegroup as number; No checks at present.
getSpacegroup
public String getSpacegroup()
- gets spacegroup as String; No checks at present, and no defined convention
null string ("") if not set
getSpacegroupNumber
public int getSpacegroupNumber(int nsp)
- gets spacegroup as number; No checks at present. 0 if not set;
addSymmetryOperator
public void addSymmetryOperator(RealMatrix m) throws UnconformableMatricesException
- adds symmetry operator as 4*3 matrix; No checks at present (apart from shape).
- Throws: UnconformableMatricesException
- Matrix must be 3 * 4
getSymmetryOperators
public RealMatrix[] getSymmetryOperators()
- gets symmetry operators as an array of RealMatrix'es (3 rows, 4 columns)
showHelp
public void showHelp()
- display Help
- Overrides:
- showHelp in class DrawableX_Node
mayContain
public boolean mayContain(SGMLNode n)
- can this node contain others.
- Overrides:
- mayContain in class DrawableX_Node
process
public void process()
- process the data so far. A CRYSTNode may not have been supplied with
have all lengths or all angles; The lengths will default
to NaN; the angles to Math.PI/2
- Overrides:
- process in class DrawableSGMLNode
getOrthogonalisationMatrix
public RealSquareMatrix getOrthogonalisationMatrix()
display
public void display()
- Kicks off a ScrollableTopLevel which contains the object.
- Overrides:
- display in class DrawableSGMLNode
drawIcon
public int drawIcon(Graphics g,
int x,
int y)
- draw a CML icon
- Overrides:
- drawIcon in class DrawableX_Node
All Packages Class Hierarchy This Package Previous Next Index