Class TagFragmentIon
java.lang.Object
com.compomics.util.experiment.personalization.ExperimentObject
com.compomics.util.experiment.biology.ions.Ion
com.compomics.util.experiment.biology.ions.impl.TagFragmentIon
- All Implemented Interfaces:
Serializable
public class TagFragmentIon extends Ion
A fragment ion obtained from a tag.
- Author:
- Marc Vaudel
- See Also:
- Serialized Form
-
Nested Class Summary
Nested classes/interfaces inherited from class com.compomics.util.experiment.biology.ions.Ion
Ion.IonType
-
Field Summary
Fields Modifier and Type Field Description static int
A_ION
Identifier for an a ion.static int
B_ION
Identifier for a b ion.static int
C_ION
Identifier for a c ion.static int
X_ION
Identifier for an x ion.static int
Y_ION
Identifier for a y ion.static int
Z_ION
Identifier for a z ion.Fields inherited from class com.compomics.util.experiment.biology.ions.Ion
atomChain, theoreticMass, theoreticMass1, type
-
Constructor Summary
Constructors Constructor Description TagFragmentIon()
Empty default constructorTagFragmentIon(int fragmentType)
Constructor for a generic ion without neutral losses.TagFragmentIon(int fragmentType, int number, int subNumber, double mass, NeutralLoss[] neutralLosses, double massGap)
Constructor.TagFragmentIon(int fragmentType, NeutralLoss[] neutralLosses)
Constructor for a generic ion. -
Method Summary
Modifier and Type Method Description double
getMassGap()
Returns the mass gap comprised in this ion.String
getName()
Returns the name of the ion.String
getNameWithGapAndNumber()
Returns the name with number and mass gap.String
getNameWithNumber()
Returns the name with number.NeutralLoss[]
getNeutralLosses()
Returns the possible neutral losses of this ion type.int
getNumber()
Returns the number of the fragment in the tag.static int[]
getPossibleSubtypes()
Returns the possible subtypes.CvTerm
getPrideCvTerm()
Returns the CV term adapted to the fragment ion.CvTerm
getPsiMsCvTerm()
Returns the CV term adapted to the fragment ion.int
getSubNumber()
Returns the number of the fragment in the current amino acid sequence.int
getSubType()
Returns the ion subtype.String
getSubTypeAsString()
Returns the subtype as string.static String
getSubTypeAsString(int subType)
Returns the type of fragment ion as a letter.boolean
isSameAs(Ion anotherIon)
Returns a boolean indicating whether the ion is the same as another ion.Methods inherited from class com.compomics.util.experiment.biology.ions.Ion
getAtomicComposition, getGenericIon, getGenericIon, getImplementedIonTypes, getNeutralLossesAsString, getNeutralLossesAsString, getPossibleSubtypes, getPossibleSubtypesAsSet, getTheoreticMass, getTheoreticMz, getType, getTypeAsString, getTypeAsString, hasNeutralLosses, setAtomicComposition, setTheoreticMass
Methods inherited from class com.compomics.util.experiment.personalization.ExperimentObject
addUrParam, asLong, clearParametersMap, getId, getUrParam, getUrParams, removeUrParam, setId, setUrParams
-
Field Details
-
A_ION
public static final int A_IONIdentifier for an a ion.- See Also:
- Constant Field Values
-
B_ION
public static final int B_IONIdentifier for a b ion.- See Also:
- Constant Field Values
-
C_ION
public static final int C_IONIdentifier for a c ion.- See Also:
- Constant Field Values
-
X_ION
public static final int X_IONIdentifier for an x ion.- See Also:
- Constant Field Values
-
Y_ION
public static final int Y_IONIdentifier for a y ion.- See Also:
- Constant Field Values
-
Z_ION
public static final int Z_IONIdentifier for a z ion.- See Also:
- Constant Field Values
-
-
Constructor Details
-
TagFragmentIon
public TagFragmentIon()Empty default constructor -
TagFragmentIon
public TagFragmentIon(int fragmentType, int number, int subNumber, double mass, NeutralLoss[] neutralLosses, double massGap)Constructor.- Parameters:
fragmentType
- the type of peptide fragment ion as indexed by the static fieldsnumber
- the number of the fragment ionsubNumber
- the number of the fragment ion in the current amino acid sequencemass
- the mass of the fragment ionneutralLosses
- the neutral losses of the ionmassGap
- the mass gap before this tag fragment ions
-
TagFragmentIon
Constructor for a generic ion.- Parameters:
fragmentType
- the type of peptide fragment ion as indexed by the static fieldsneutralLosses
- the neutral losses of the ion
-
TagFragmentIon
public TagFragmentIon(int fragmentType)Constructor for a generic ion without neutral losses.- Parameters:
fragmentType
- the type of peptide fragment ion as indexed by the static fields
-
-
Method Details
-
getNumber
public int getNumber()Returns the number of the fragment in the tag. 0 based.- Returns:
- the number of the fragment in the tag
-
getSubNumber
public int getSubNumber()Returns the number of the fragment in the current amino acid sequence. 0 based.- Returns:
- the number of the fragment in the current amino acid sequence
-
getNeutralLosses
Description copied from class:Ion
Returns the possible neutral losses of this ion type. An empty list if none.- Specified by:
getNeutralLosses
in classIon
- Returns:
- the possible neutral losses of this ion type
-
getName
Description copied from class:Ion
Returns the name of the ion. The name should be short enough to be displayed on a spectrum. -
getNameWithNumber
Returns the name with number. For example b5-H2O.- Returns:
- the name with number
-
getNameWithGapAndNumber
Returns the name with number and mass gap. For example 110.0...b5-H2O.- Returns:
- the name with number
-
getPrideCvTerm
Description copied from class:Ion
Returns the CV term adapted to the fragment ion. Null if none corresponding.- Specified by:
getPrideCvTerm
in classIon
- Returns:
- the CV term adapted to the fragment ion. Null if none corresponding
-
getPsiMsCvTerm
Description copied from class:Ion
Returns the CV term adapted to the fragment ion. Null if none corresponding.- Specified by:
getPsiMsCvTerm
in classIon
- Returns:
- the CV term adapted to the fragment ion. Null if none corresponding
-
getSubType
public int getSubType()Description copied from class:Ion
Returns the ion subtype.- Specified by:
getSubType
in classIon
- Returns:
- the ion subtype as integer
-
getSubTypeAsString
Description copied from class:Ion
Returns the subtype as string.- Specified by:
getSubTypeAsString
in classIon
- Returns:
- the subtype as string
-
getSubTypeAsString
Returns the type of fragment ion as a letter.- Parameters:
subType
- the subtype- Returns:
- the type of fragment ion as a letter
-
getPossibleSubtypes
public static int[] getPossibleSubtypes()Returns the possible subtypes.- Returns:
- the possible subtypes
-
isSameAs
Description copied from class:Ion
Returns a boolean indicating whether the ion is the same as another ion. -
getMassGap
public double getMassGap()Returns the mass gap comprised in this ion.- Returns:
- the mass gap
-