Package org.openscience.cdk
Class Isotope
java.lang.Object
org.openscience.cdk.ChemObject
org.openscience.cdk.Element
org.openscience.cdk.Isotope
- All Implemented Interfaces:
Serializable
,Cloneable
,ICDKObject
,IChemObject
,IElement
,IIsotope
- Direct Known Subclasses:
AtomType
,DebugIsotope
Used to store and retrieve data of a particular isotope.
For example, an carbon 13 isotope can be created with:
Isotope carbon = new Isotope("C", 13);
A full specification can be constructed with:
// make deuterium Isotope carbon = new Isotope(1, "H", 2, 2.01410179, 100.0);
Once instantiated all field not filled by passing parameters to the constructor are null. Isotopes can be configured by using the IsotopeFactory.configure() method:
Isotope isotope = new Isotope("C", 13); IsotopeFactory if = IsotopeFactory.getInstance(isotope.getNewBuilder()); if.configure(isotope);
- Author:
- steinbeck
- See Also:
- Source code:
- main
- Belongs to CDK module:
- data
- Keywords:
- isotope
- Created on:
- 2001-08-21
-
Field Summary
FieldsModifier and TypeFieldDescriptionExact mass of this isotope.Natural abundance of this isotope.Fields inherited from class org.openscience.cdk.Element
atomicNumber
Fields inherited from interface org.openscience.cdk.interfaces.IElement
Ac, Ag, Al, Am, Ar, As, At, Au, B, Ba, Be, Bh, Bi, Bk, Br, C, Ca, Cd, Ce, Cf, Cl, Cm, Cn, Co, Cr, Cs, Cu, Db, Ds, Dy, Er, Es, Eu, F, Fe, Fl, Fm, Fr, Ga, Gd, Ge, H, He, Hf, Hg, Ho, Hs, I, In, Ir, K, Kr, La, Li, Lr, Lu, Lv, Mc, Md, Mg, Mn, Mo, Mt, N, Na, Nb, Nd, Ne, Nh, Ni, No, Np, O, Og, Os, P, Pa, Pb, Pd, Pm, Po, Pr, Pt, Pu, Ra, Rb, Re, Rf, Rg, Rh, Rn, Ru, S, Sb, Sc, Se, Sg, Si, Sm, Sn, Sr, Ta, Tb, Tc, Te, Th, Ti, Tl, Tm, Ts, U, V, W, Wildcard, Xe, Y, Yb, Zn, Zr
-
Constructor Summary
ConstructorsConstructorDescriptionConstructor for the Isotope object.Constructor for the Isotope object.Constructor for the Isotope object.Constructor for the Isotope object.Constructs an empty by copying the symbol, atomic number, flags, and identifier from the given IElement. -
Method Summary
Modifier and TypeMethodDescriptionclone()
Clones thisIChemObject
.boolean
Compares a atom type with this atom type.Gets the ExactMass attribute of the Isotope object.Returns the atomic mass of this element.Gets the NaturalAbundance attribute of the Isotope object.void
setExactMass
(Double exactMass) Sets the ExactMass attribute of the Isotope object.void
setMassNumber
(Integer massNumber) Sets the atomic mass of this element.void
setNaturalAbundance
(Double naturalAbundance) Sets the NaturalAbundance attribute of the Isotope object.toString()
A string representation of this isotope.Methods inherited from class org.openscience.cdk.Element
getAtomicNumber, getSymbol, setAtomicNumber, setSymbol
Methods inherited from class org.openscience.cdk.ChemObject
addListener, addProperties, getBuilder, getFlag, getFlags, getFlagValue, getID, getListenerCount, getNotification, getProperties, getProperty, getProperty, notifyChanged, notifyChanged, removeListener, removeProperty, setFlag, setFlags, setID, setNotification, setProperties, setProperty, shallowCopy
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.openscience.cdk.interfaces.ICDKObject
getBuilder
Methods inherited from interface org.openscience.cdk.interfaces.IChemObject
addListener, addProperties, getFlag, getFlags, getFlagValue, getID, getListenerCount, getNotification, getProperties, getProperty, getProperty, notifyChanged, notifyChanged, removeListener, removeProperty, setFlag, setFlags, setID, setNotification, setProperties, setProperty
Methods inherited from interface org.openscience.cdk.interfaces.IElement
getAtomicNumber, getSymbol, setAtomicNumber, setSymbol
-
Field Details
-
exactMass
Exact mass of this isotope. -
naturalAbundance
Natural abundance of this isotope.
-
-
Constructor Details
-
Isotope
Constructor for the Isotope object.- Parameters:
elementSymbol
- The element symbol, "O" for Oxygen, etc.
-
Isotope
public Isotope(int atomicNumber, String elementSymbol, int massNumber, double exactMass, double abundance) Constructor for the Isotope object.- Parameters:
atomicNumber
- The atomic number of the isotopeelementSymbol
- The element symbol, "O" for Oxygen, etc.massNumber
- The atomic mass of the isotope, 16 for Oxygen, e.g.exactMass
- The exact mass of the isotope, be a little more explicit here :-)abundance
- The natural abundance of the isotope
-
Isotope
Constructor for the Isotope object.- Parameters:
atomicNumber
- The atomic number of the isotope, 8 for OxygenelementSymbol
- The element symbol, "O" for Oxygen, etc.exactMass
- The exact mass of the isotope, be a little more explicit here :-)abundance
- The natural abundance of the isotope
-
Isotope
Constructor for the Isotope object.- Parameters:
elementSymbol
- The element symbol, "O" for Oxygen, etc.massNumber
- The atomic mass of the isotope, 16 for Oxygen, e.g.
-
Isotope
Constructs an empty by copying the symbol, atomic number, flags, and identifier from the given IElement. It does not copy the listeners and properties. If the element is an instance of IIsotope, then the exact mass, natural abundance and mass number are copied too.- Parameters:
element
- IElement to copy information from
-
-
Method Details
-
setNaturalAbundance
Sets the NaturalAbundance attribute of the Isotope object.- Specified by:
setNaturalAbundance
in interfaceIIsotope
- Parameters:
naturalAbundance
- The new NaturalAbundance value- See Also:
-
setExactMass
Sets the ExactMass attribute of the Isotope object.- Specified by:
setExactMass
in interfaceIIsotope
- Parameters:
exactMass
- The new ExactMass value- See Also:
-
getNaturalAbundance
Gets the NaturalAbundance attribute of the Isotope object.Once instantiated all field not filled by passing parameters to the constructor are null. Isotopes can be configured by using the IsotopeFactory.configure() method:
Isotope isotope = new Isotope("C", 13); IsotopeFactory if = IsotopeFactory.getInstance(isotope.getNewBuilder()); if.configure(isotope);
- Specified by:
getNaturalAbundance
in interfaceIIsotope
- Returns:
- The NaturalAbundance value
- See Also:
-
getExactMass
Gets the ExactMass attribute of the Isotope object.Once instantiated all field not filled by passing parameters to the constructor are null. Isotopes can be configured by using the IsotopeFactory.configure() method:
Isotope isotope = new Isotope("C", 13); IsotopeFactory if = IsotopeFactory.getInstance(isotope.getNewBuilder()); if.configure(isotope);
- Specified by:
getExactMass
in interfaceIIsotope
- Returns:
- The ExactMass value
- See Also:
-
getMassNumber
Returns the atomic mass of this element.Once instantiated all field not filled by passing parameters to the constructor are null. Isotopes can be configured by using the IsotopeFactory.configure() method:
Isotope isotope = new Isotope("C", 13); IsotopeFactory if = IsotopeFactory.getInstance(isotope.getNewBuilder()); if.configure(isotope);
- Specified by:
getMassNumber
in interfaceIIsotope
- Returns:
- The atomic mass of this element
- See Also:
-
setMassNumber
Sets the atomic mass of this element.- Specified by:
setMassNumber
in interfaceIIsotope
- Parameters:
massNumber
- The atomic mass to be assigned to this element- See Also:
-
toString
A string representation of this isotope.- Specified by:
toString
in interfaceIChemObject
- Overrides:
toString
in classElement
- Returns:
- A string representation of this isotope
-
compare
Compares a atom type with this atom type. -
clone
Description copied from class:ChemObject
Clones thisIChemObject
. It clones the identifier, flags, properties and pointer vectors. The ChemObjectListeners are not cloned, and neither is the content of the pointer vectors.- Specified by:
clone
in interfaceIChemObject
- Overrides:
clone
in classElement
- Returns:
- The cloned object
- Throws:
CloneNotSupportedException
- if the IChemObject cannot be cloned
-