Package com.compomics.util.protein
Class MolecularFormula
java.lang.Object
com.compomics.util.protein.MolecularFormula
This class represents the molecular formula. Basically it count the number of atoms.
Created by IntelliJ IDEA.
User: Niklaas
Date: 16-Aug-2010
Time: 08:25:22
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddElement(MolecularElement lMolecularElement, Integer lCount) Method to add MolecularElements to this formulavoidaddMolecularFormula(MolecularFormula lMolecularFormula) Method to add whole formulas to this formulaintgetElementCount(MolecularElement lMolecularElement) Getter for the count of a specific elementtoString()To string method
-
Constructor Details
-
MolecularFormula
public MolecularFormula()Default constructor -
MolecularFormula
Constructor.- Parameters:
lSequence- the amino acid sequence
-
-
Method Details
-
addElement
Method to add MolecularElements to this formula- Parameters:
lMolecularElement- The molecular elementlCount- The count
-
addMolecularFormula
Method to add whole formulas to this formula- Parameters:
lMolecularFormula- The MolecularFormula to add
-
getElementCount
Getter for the count of a specific element- Parameters:
lMolecularElement- The MolecularElement to get to count for- Returns:
- Int with the count
-
toString
To string method
-