Package xal.model
Class Lattice
java.lang.Object
xal.model.elem.ElementSeq
xal.model.Lattice
- All Implemented Interfaces:
Iterable<IComponent>,IComponent,IComposite
High-level container representing a machine model.
- Author:
- Christopher K. Allen, Craig McChesney
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intdefault number of element positions to reserve in list arraystatic final Stringthe string type identifier for all Lattice objects -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns a DOM document for the lattice.voidbackPropagate(IProbe probe) Backward propagation of a probe through the lattice.Get the author of the lattice definitiongetDate()Get the date of lattice descriptiongetLines()Deprecated.This method is never used.getRings()Deprecated.This method is never usedGet the version of the latticevoidprint(PrintWriter os) Dump current state and content to output stream.voidSets the author tagvoidSets the date tagvoidsetVersion(String strVersion) Sets the version tagMethods inherited from class xal.model.elem.ElementSeq
addChild, backPropagate, childIterator, compDependParams, concatenateEquals, getAlignX, getAlignY, getAlignZ, getAllElements, getChild, getChildCount, getComments, getElementList, getForwardCompList, getHardwareNodeId, getId, getLatticePosition, getLeafCount, getLength, getParent, getPhiX, getPhiY, getPhiZ, getPosition, getReverseCompList, getType, globalBackIterator, globalIterator, initializeFrom, iterator, localBackIterator, localIterator, propagate, propagate, remove, setAlign, setAlignX, setAlignY, setAlignZ, setComments, setCompList, setDirty, setHardwareNodeId, setId, setParent, setPhiX, setPhiY, setPhiZ, toString, toStringLegacyMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Field Details
-
SIZE_DEF_RESERVE
public static final int SIZE_DEF_RESERVEdefault number of element positions to reserve in list array- See Also:
-
TYPE
the string type identifier for all Lattice objects- See Also:
-
-
Constructor Details
-
Lattice
public Lattice()Creates a new instance of Lattice -
Lattice
Creates a new instance of Lattice- Parameters:
strId- identifier of the lattice
-
Lattice
Creates a new instance of Lattice and reserves space for a szReserve length lattice.- Parameters:
strId- identifier of the latticeszReserve- number of Element spaces to reserve
-
-
Method Details
-
setVersion
Sets the version tag- Parameters:
strVersion- revision number of lattice
-
setAuthor
Sets the author tag- Parameters:
strAuthor- author of lattice description
-
setDate
Sets the date tag- Parameters:
strDate- date string of lattice description
-
getVersion
Get the version of the lattice- Returns:
- lattice revision number
-
getAuthor
Get the author of the lattice definition- Returns:
- lattice author
-
getDate
Get the date of lattice description- Returns:
- lattice model date
-
getRings
Deprecated.This method is never usedReturn a list of theRingModelobjects contained in this model.- Returns:
- ordered list of all
RingModelobjects within model
-
getLines
Deprecated.This method is never used.Return a list of theLineModelobjects contained in this model.- Returns:
- ordered list of all
LineModelobjects within model
-
backPropagate
Backward propagation of a probe through the lattice.
The probe is first initialized by calling the
initialize()method of the probe then updated by calling theupdate()method in order to save the initial state of the probe into its trajectory.NOTES: CKA
· Support for backward propagation February, 2009.
· You must use the proper algorithm object for this method to work correctly!- Specified by:
backPropagatein interfaceIComponent- Overrides:
backPropagatein classElementSeq- Parameters:
probe- the state of the probe will be advance using the elements dynamics- Throws:
ModelException- an error occurred while advancing the probe state
-
asDocument
Returns a DOM document for the lattice.- Returns:
- a DOM document for the lattice
- Throws:
IOException- I guess this is thrown whenLatticeXmlWriteris unable to parse this lattice
-
print
Dump current state and content to output stream.- Overrides:
printin classElementSeq- Parameters:
os- output stream object
-