Package org.openscience.cdk.debug
Class DebugAdductFormula
java.lang.Object
org.openscience.cdk.formula.AdductFormula
org.openscience.cdk.debug.DebugAdductFormula
- All Implemented Interfaces:
Cloneable,Iterable<IMolecularFormula>,IAdductFormula,ICDKObject,IMolecularFormulaSet
Debugging implementation of
IAdductFormula.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidadd(IMolecularFormulaSet formulaSet) Adds all molecularFormulas in the AdductFormula to this chemObject.voidaddMolecularFormula(IMolecularFormula formula) Adds an molecularFormula to this chemObject.booleanTrue, if the AdductFormula contains the given IIsotope object and not the instance.booleancontains(IMolecularFormula formula) True, if the AdductFormula contains the given IMolecularFormula object.Returns aIChemObjectBuilderfor the data classes that extend this class.Returns the partial charge of this Adduct.intChecks a set of Nodes for the number of different isotopes in the adduct formula.intgetIsotopeCount(IIsotope isotope) Checks a set of Nodes for the occurrence of the isotope in the adduct formula from a particular isotope.getMolecularFormula(int position) Returns the MolecularFormula at positionnumberin the chemObject.isotopes()Returns an Iterator for looping over all isotopes in this adduct formula.iterator()Returns an Iterator for looping over all IMolecularFormula in this adduct formula.Returns an Iterable for looping over all IMolecularFormula in this adduct formula.voidRemoves all IMolecularFormula from this chemObject.voidremoveMolecularFormula(int position) Removes an MolecularFormula from this chemObject.voidremoveMolecularFormula(IMolecularFormula formula) Removes an IMolecularFormula from this chemObject.voidNo use this method.intsize()Returns the number of MolecularFormulas in this AdductFormula.Methods inherited from class org.openscience.cdk.formula.AdductFormula
cloneMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.openscience.cdk.interfaces.IAdductFormula
cloneMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
DebugAdductFormula
public DebugAdductFormula() -
DebugAdductFormula
-
-
Method Details
-
contains
True, if the AdductFormula contains the given IIsotope object and not the instance. The method looks for other isotopes which has the same symbol, natural abundance and exact mass.- Specified by:
containsin interfaceIAdductFormula- Overrides:
containsin classAdductFormula- Parameters:
isotope- The IIsotope this AdductFormula is searched for- Returns:
- True, if the AdductFormula contains the given isotope object
-
getCharge
Returns the partial charge of this Adduct. If the charge has not been set the return value is Double.NaN.- Specified by:
getChargein interfaceIAdductFormula- Overrides:
getChargein classAdductFormula- Returns:
- the charge of this Adduct
- See Also:
-
getIsotopeCount
Checks a set of Nodes for the occurrence of the isotope in the adduct formula from a particular isotope. It returns 0 if the does not exist.- Specified by:
getIsotopeCountin interfaceIAdductFormula- Overrides:
getIsotopeCountin classAdductFormula- Parameters:
isotope- The IIsotope to look for- Returns:
- The occurrence of this isotope in this adduct
- See Also:
-
getIsotopeCount
public int getIsotopeCount()Checks a set of Nodes for the number of different isotopes in the adduct formula.- Specified by:
getIsotopeCountin interfaceIAdductFormula- Overrides:
getIsotopeCountin classAdductFormula- Returns:
- The the number of different isotopes in this adduct formula
- See Also:
-
isotopes
Returns an Iterator for looping over all isotopes in this adduct formula.- Specified by:
isotopesin interfaceIAdductFormula- Overrides:
isotopesin classAdductFormula- Returns:
- An Iterator with the isotopes in this adduct formula
-
setCharge
No use this method. The charge is defined in each IMolecularFormula.- Specified by:
setChargein interfaceIAdductFormula- Overrides:
setChargein classAdductFormula- Parameters:
charge- The partial charge- See Also:
-
add
Adds all molecularFormulas in the AdductFormula to this chemObject.- Specified by:
addin interfaceIMolecularFormulaSet- Overrides:
addin classAdductFormula- Parameters:
formulaSet- The MolecularFormulaSet
-
addMolecularFormula
Adds an molecularFormula to this chemObject.- Specified by:
addMolecularFormulain interfaceIMolecularFormulaSet- Overrides:
addMolecularFormulain classAdductFormula- Parameters:
formula- The molecularFormula to be added to this chemObject
-
contains
True, if the AdductFormula contains the given IMolecularFormula object.- Specified by:
containsin interfaceIMolecularFormulaSet- Overrides:
containsin classAdductFormula- Parameters:
formula- The IMolecularFormula this AdductFormula is searched for- Returns:
- True, if the AdductFormula contains the given IMolecularFormula object
-
getMolecularFormula
Returns the MolecularFormula at positionnumberin the chemObject.- Specified by:
getMolecularFormulain interfaceIMolecularFormulaSet- Overrides:
getMolecularFormulain classAdductFormula- Parameters:
position- The position of the IMolecularFormula to be returned.- Returns:
- The IMolecularFormula at position
number.
-
iterator
Returns an Iterator for looping over all IMolecularFormula in this adduct formula.- Specified by:
iteratorin interfaceIterable<IMolecularFormula>- Overrides:
iteratorin classAdductFormula- Returns:
- An Iterator with the IMolecularFormula in this adduct formula
-
molecularFormulas
Returns an Iterable for looping over all IMolecularFormula in this adduct formula.- Specified by:
molecularFormulasin interfaceIMolecularFormulaSet- Overrides:
molecularFormulasin classAdductFormula- Returns:
- An Iterable with the IMolecularFormula in this adduct formula
- See Also:
-
removeAllMolecularFormulas
public void removeAllMolecularFormulas()Removes all IMolecularFormula from this chemObject.- Specified by:
removeAllMolecularFormulasin interfaceIMolecularFormulaSet- Overrides:
removeAllMolecularFormulasin classAdductFormula
-
removeMolecularFormula
Removes an IMolecularFormula from this chemObject.- Specified by:
removeMolecularFormulain interfaceIMolecularFormulaSet- Overrides:
removeMolecularFormulain classAdductFormula- Parameters:
formula- The IMolecularFormula to be removed from this chemObject
-
removeMolecularFormula
public void removeMolecularFormula(int position) Removes an MolecularFormula from this chemObject.- Specified by:
removeMolecularFormulain interfaceIMolecularFormulaSet- Overrides:
removeMolecularFormulain classAdductFormula- Parameters:
position- The position of the MolecularFormula to be removed from this chemObject
-
size
public int size()Returns the number of MolecularFormulas in this AdductFormula.- Specified by:
sizein interfaceIMolecularFormulaSet- Overrides:
sizein classAdductFormula- Returns:
- The number of MolecularFormulas in this AdductFormula
-
getBuilder
Returns aIChemObjectBuilderfor the data classes that extend this class.- Specified by:
getBuilderin interfaceICDKObject- Overrides:
getBuilderin classAdductFormula- Returns:
- The
IChemObjectBuildermatching thisICDKObject
-