org.systemsbiology.jrap
Class Scan

java.lang.Object
  extended by org.systemsbiology.jrap.Scan
All Implemented Interfaces:
java.io.Serializable

public final class Scan
extends java.lang.Object
implements java.io.Serializable

A simple class to hold the contents of a scan from a MSXML file. This is a start. For those who want to get more fancy you should only have to modify the SAX2ScanHandler to replace this.

See Also:
Serialized Form

Field Summary
protected  double[][] doubleMassIntensityList
           
protected  float[][] floatMassIntensityList
          A 2-dimensional array, element 0 contains a list of masses of peaks, element 1 contains a list of intensities of peaks.
protected  ScanHeader header
           
 
Constructor Summary
Scan()
          Default constructor, initializes an empty Scan.
 
Method Summary
 float getBasePeakIntensity()
           
 float getBasePeakMz()
           
 java.lang.String getByteOrder()
           
 int getCentroided()
           
 int getChargeDeconvoluted()
           
 float getCollisionEnergy()
           
 int getCompressedLen()
           
 java.lang.String getCompressionType()
           
 java.lang.String getContentType()
           
 int getDeisotoped()
           
 double[][] getDoubleMassIntensityList()
           
 double getDoubleRetentionTime()
           
 float getEndMz()
           
 float[][] getFloatMassIntensityList()
          Return the peaks in this scan as two lists: one of mass values and one of intensity values.
 ScanHeader getHeader()
           
 float getHighMz()
           
 float getIonisationEnergy()
           
 float getLowMz()
           
 int getMsLevel()
           
 int getNum()
           
 float[][] getPeakList()
           
 int getPeaksCount()
           
 java.lang.String getPolarity()
           
 int getPrecision()
           
 int getPrecursorCharge()
           
 float getPrecursorMz()
           
 int getPrecursorScanNum()
           
 java.lang.String getRetentionTime()
           
 java.lang.String getScanType()
           
 float getStartMz()
           
 float getTotIonCurrent()
           
 void setBasePeakIntensity(float newValue)
          Set the intensity of the base peak
 void setBasePeakMz(float newValue)
          Set the base peak m/z value for this scan
 void setByteOrder(java.lang.String newValue)
           
 void setCentroided(int newValue)
          Set if this scan was centroided or not
 void setChargeDeconvoluted(int newValue)
          Set if this scan was charge deconvoluted or not
 void setCollisionEnergy(float newValue)
          Set the collision energy used in this scan.
 void setCompressedLen(int newValue)
           
 void setCompressionType(java.lang.String newValue)
           
 void setContentType(java.lang.String newValue)
           
 void setDeisotoped(int newValue)
          Set if this scan was deisotoped or not
 void setDoubleMassIntensityList(double[][] newValue)
           
 void setEndMz(float newValue)
           
 void setFloatMassIntensityList(float[][] newValue)
           
 void setHeader(ScanHeader header)
           
 void setHighMz(float newValue)
           
 void setIonisationEnergy(float newValue)
          Set the ionisation energy used in this scan.
 void setLowMz(float newValue)
           
 void setMsLevel(int newValue)
          Set the MS level of this scan
 void setNum(int newValue)
          Set the number of this scan in the file.
 void setPeakList(float[][] newValue)
           
 void setPeaksCount(int newValue)
          Set the number of peaks in this scan.
 void setPolarity(java.lang.String newValue)
          Set the polarity of this scan
 void setPrecision(int newValue)
           
 void setPrecursorCharge(int newValue)
          Set the charge of the precursor of this scan
 void setPrecursorMz(float newValue)
          Set the precursor m/z value for this scan
 void setPrecursorScanNum(int newValue)
          Set the scan number in which the precursor of this scan was acquired
 void setRetentionTime(java.lang.String newValue)
          Set the retention time at which this scan was acquired
 void setScanType(java.lang.String newValue)
          Set the type of this scan
 void setStartMz(float newValue)
           
 void setTotIonCurrent(float newValue)
          Set the total ion current of this scan
 java.lang.String toString()
          String respresentation of a Scan object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

header

protected ScanHeader header

floatMassIntensityList

protected float[][] floatMassIntensityList
A 2-dimensional array, element 0 contains a list of masses of peaks, element 1 contains a list of intensities of peaks.


doubleMassIntensityList

protected double[][] doubleMassIntensityList
Constructor Detail

Scan

public Scan()
Default constructor, initializes an empty Scan. A typical application probably only wants to use MSXMLParser.rap() to create Scan objects.

Method Detail

setNum

public void setNum(int newValue)
Set the number of this scan in the file.


setMsLevel

public void setMsLevel(int newValue)
Set the MS level of this scan

Parameters:
newValue - the new MS level of this scan

setPeaksCount

public void setPeaksCount(int newValue)
Set the number of peaks in this scan.

Parameters:
newValue - the new number of peaks in this scan.

setPolarity

public void setPolarity(java.lang.String newValue)
Set the polarity of this scan

Parameters:
newValue - the new polarity of this scan

setScanType

public void setScanType(java.lang.String newValue)
Set the type of this scan

Parameters:
newValue - the new type of this scan

setCentroided

public void setCentroided(int newValue)
Set if this scan was centroided or not

Parameters:
newValue - 0 if this scan was not centroided, 1 if it was

setDeisotoped

public void setDeisotoped(int newValue)
Set if this scan was deisotoped or not

Parameters:
newValue - 0 if this scan was not deisotoped, 1 if it was

setChargeDeconvoluted

public void setChargeDeconvoluted(int newValue)
Set if this scan was charge deconvoluted or not

Parameters:
newValue - 0 if this scan was not charge deconvoluted, 1 if it was

setRetentionTime

public void setRetentionTime(java.lang.String newValue)
Set the retention time at which this scan was acquired

Parameters:
newValue - the new value for the retention time.

setStartMz

public void setStartMz(float newValue)

setEndMz

public void setEndMz(float newValue)

setLowMz

public void setLowMz(float newValue)

setHighMz

public void setHighMz(float newValue)

setBasePeakMz

public void setBasePeakMz(float newValue)
Set the base peak m/z value for this scan

Parameters:
newValue - the new value to set

setBasePeakIntensity

public void setBasePeakIntensity(float newValue)
Set the intensity of the base peak

Parameters:
newValue - the new value to set

setTotIonCurrent

public void setTotIonCurrent(float newValue)
Set the total ion current of this scan

Parameters:
newValue - the new value to set

setPrecursorMz

public void setPrecursorMz(float newValue)
Set the precursor m/z value for this scan

Parameters:
newValue - the new value to set.

setPrecursorScanNum

public void setPrecursorScanNum(int newValue)
Set the scan number in which the precursor of this scan was acquired

Parameters:
newValue - the new value to set

setPrecursorCharge

public void setPrecursorCharge(int newValue)
Set the charge of the precursor of this scan

Parameters:
newValue - the new value to set.

setCollisionEnergy

public void setCollisionEnergy(float newValue)
Set the collision energy used in this scan.

Parameters:
newValue - the new value to set.

setIonisationEnergy

public void setIonisationEnergy(float newValue)
Set the ionisation energy used in this scan.

Parameters:
newValue - the new value to set

setPrecision

public void setPrecision(int newValue)

setPeakList

public void setPeakList(float[][] newValue)

setFloatMassIntensityList

public void setFloatMassIntensityList(float[][] newValue)

setDoubleMassIntensityList

public void setDoubleMassIntensityList(double[][] newValue)

setByteOrder

public void setByteOrder(java.lang.String newValue)

setContentType

public void setContentType(java.lang.String newValue)

setCompressionType

public void setCompressionType(java.lang.String newValue)

setCompressedLen

public void setCompressedLen(int newValue)

getNum

public int getNum()
Returns:
the number of this scan in the mzXML file

getMsLevel

public int getMsLevel()
Returns:
the MS level of this scan

getPeaksCount

public int getPeaksCount()
Returns:
the number of peaks in this Scan

getPolarity

public java.lang.String getPolarity()
Returns:
the polarity of this scan

getScanType

public java.lang.String getScanType()
Returns:
the type of this scan

getCentroided

public int getCentroided()
Returns:
1 if the scan was centroided, 0 if it was not

getDeisotoped

public int getDeisotoped()
Returns:
1 if the scan was deisotoped, 0 if it was not

getChargeDeconvoluted

public int getChargeDeconvoluted()
Returns:
1 if the scan was charge deconvoluted, 0 if it was not

getRetentionTime

public java.lang.String getRetentionTime()
Returns:
the retention time at which this scan was acquired.

getStartMz

public float getStartMz()

getEndMz

public float getEndMz()

getLowMz

public float getLowMz()

getHighMz

public float getHighMz()

getBasePeakMz

public float getBasePeakMz()

getBasePeakIntensity

public float getBasePeakIntensity()

getTotIonCurrent

public float getTotIonCurrent()

getPrecursorMz

public float getPrecursorMz()

getPrecursorScanNum

public int getPrecursorScanNum()

getPrecursorCharge

public int getPrecursorCharge()

getCollisionEnergy

public float getCollisionEnergy()

getIonisationEnergy

public float getIonisationEnergy()

getPrecision

public int getPrecision()

getByteOrder

public java.lang.String getByteOrder()

getContentType

public java.lang.String getContentType()

getCompressionType

public java.lang.String getCompressionType()

getCompressedLen

public int getCompressedLen()

getPeakList

public float[][] getPeakList()

getFloatMassIntensityList

public float[][] getFloatMassIntensityList()
Return the peaks in this scan as two lists: one of mass values and one of intensity values.
Peak 0 mass = list[0][0], peak 0 intensity = list[1][0]
Peak 1 mass = list[0][1], peak 1 intensity = list[1][1]
Peak 2 mass = list[0][2], peak 2 intensity = list[1][2]
etc.

Returns:
The list of mass values and intensity values.

getDoubleMassIntensityList

public double[][] getDoubleMassIntensityList()

toString

public java.lang.String toString()
String respresentation of a Scan object. Note: This is most likely not an optimal way to build the string. Hopefully this method will only be used for testing.

Overrides:
toString in class java.lang.Object

getDoubleRetentionTime

public double getDoubleRetentionTime()

getHeader

public ScanHeader getHeader()
Returns:
Returns the ScanHeader.

setHeader

public void setHeader(ScanHeader header)
Parameters:
header - The ScanHeader to set.


SASHIMI Project