public class MzDbAsyncReader extends AbstractMzDbReader
_paramNameGetter, acquisitionMode, bbSizes, computationThreadPool, dbLocation, diaIsolationWindows, entityCache, instrumentConfigs, isNoLossMode, mzDbHeader, runs, rxCompScheduler, samples, softwareList, sourceFiles
Constructor and Description |
---|
MzDbAsyncReader(File dbLocation,
boolean cacheEntities)
Instantiates a new mzDB reader (secondary constructor).
|
MzDbAsyncReader(File dbLocation,
MzDbEntityCache entityCache,
boolean logConnections)
Instantiates a new mzDB reader (primary constructor).
|
MzDbAsyncReader(String dbPath,
boolean cacheEntities)
Instantiates a new mzDB reader (secondary constructor).
|
Modifier and Type | Method and Description |
---|---|
void |
close()
close the connection to avoid memory leaks.
|
protected com.almworks.sqlite4java.SQLiteConnection |
createBlockingSQLiteConnection() |
rx.Observable<AcquisitionMode> |
getAcquisitionMode()
Lazy loading of the acquisition mode, parameter
|
rx.Observable<byte[]> |
getBoundingBoxData(int bbId)
Gets the bounding box data.
|
rx.Observable<Integer> |
getBoundingBoxesCount()
Gets the bounding box count.
|
rx.Observable<Integer> |
getBoundingBoxesCount(int runSliceId)
Gets the bounding box count.
|
rx.Observable<Long> |
getBoundingBoxFirstSpectrumId(long spectrumId)
Gets the bounding box first spectrum index.
|
rx.Observable<Float> |
getBoundingBoxMinMz(int bbId)
Gets the bounding box min mz.
|
rx.Observable<Float> |
getBoundingBoxMinTime(int bbId)
Gets the bounding box min time.
|
rx.Observable<Integer> |
getBoundingBoxMsLevel(int bbId)
Gets the bounding box ms level.
|
rx.Observable<BoundingBox> |
getBoundingBoxStream(int msLevel)
Gets the bounding box iterator.
|
rx.Observable<Integer> |
getCyclesCount()
Gets the cycle count.
|
rx.Observable<DataEncoding> |
getDataEncoding(int id)
Gets the data encoding.
|
rx.Observable<Map<Long,DataEncoding>> |
getDataEncodingBySpectrumId()
Gets the data encoding by spectrum id.
|
DataEncodingAsyncReader |
getDataEncodingReader() |
rx.Observable<Integer> |
getDataEncodingsCount()
Gets the data encoding count.
|
rx.Observable<IsolationWindow[]> |
getDIAIsolationWindows()
ImmutablePair can not be wrapped into an array
|
List<InstrumentConfiguration> |
getInstrumentConfigurations() |
rx.Observable<Float> |
getLastTime()
Gets the last time.
|
rx.Observable<RunSlice> |
getLcMsnRunSliceStream(double minParentMz,
double maxParentMz)
Gets a DIA data RunSlice iterator
|
rx.Observable<RunSlice> |
getLcMsnRunSliceStream(double minParentMz,
double maxParentMz,
double minRunSliceMz,
double maxRunSliceMz)
Gets a DIA data RunSlice iterator for a given m/z range
|
rx.Observable<RunSlice> |
getLcMsRunSliceStream()
Gets a RunSlice iterator.
|
rx.Observable<RunSlice> |
getLcMsRunSliceStream(double minRunSliceMz,
double maxRunSliceMz)
Gets a RunSlice iterator for a given m/z range
|
rx.Observable<Integer> |
getMaxMsLevel()
Gets the max ms level.
|
rx.Observable<String> |
getModelVersion() |
rx.Observable<Map<Long,SpectrumHeader>> |
getMs1SpectrumHeaderById()
Gets the MS1 spectrum header by id.
|
rx.Observable<SpectrumHeader[]> |
getMs1SpectrumHeaders()
Gets the MS1 spectrum headers.
|
rx.Observable<Map<Long,SpectrumHeader>> |
getMs2SpectrumHeaderById()
Gets the MS2 spectrum header by id.
|
rx.Observable<SpectrumHeader[]> |
getMs2SpectrumHeaders()
Gets the MS2 spectrum headers.
|
rx.Observable<Peak[]> |
getMsnPeaksInMzRtRanges(double parentMz,
double minFragMz,
double maxFragMz,
float minRt,
float maxRt) |
rx.Observable<SpectrumSlice[]> |
getMsnSpectrumSlices(double parentMz,
double minFragMz,
double maxFragMz,
float minRt,
float maxRt) |
rx.Observable<Peak[]> |
getMsnXic(double parentMz,
double fragmentMz,
double fragmentMzTolInDa,
float minRt,
float maxRt,
XicMethod method) |
rx.Observable<Peak[]> |
getMsPeaksInMzRtRanges(double minMz,
double maxMz,
float minRt,
float maxRt) |
rx.Observable<SpectrumSlice[]> |
getMsSpectrumSlices(double minMz,
double maxMz,
float minRt,
float maxRt)
Gets the spectrum slices.
|
rx.Observable<Peak[]> |
getMsXic(double mz,
double mzTolInDa,
float minRt,
float maxRt,
XicMethod method) |
rx.Observable<Peak[]> |
getMsXicInMzRange(double minMz,
double maxMz,
XicMethod method) |
rx.Observable<Peak[]> |
getMsXicInMzRtRanges(double minMz,
double maxMz,
float minRt,
float maxRt,
XicMethod method) |
rx.Observable<int[]> |
getMzRange(int msLevel)
Gets the mz range.
|
rx.Observable<String> |
getPwizMzDbVersion() |
List<Run> |
getRuns() |
rx.Observable<RunSliceData> |
getRunSliceData(int runSliceId)
Gets the run slice data.
|
rx.Observable<HashMap<Integer,RunSliceHeader>> |
getRunSliceHeaderById(int msLevel)
Gets the run slice header by id.
|
RunSliceHeaderAsyncReader |
getRunSliceHeaderReader() |
rx.Observable<RunSliceHeader[]> |
getRunSliceHeaders(int msLevel)
Gets the run slices.
|
rx.Observable<Integer> |
getRunSlicesCount()
Gets the run slice count.
|
List<Sample> |
getSamples() |
List<Software> |
getSoftwareList() |
List<SourceFile> |
getSourceFiles() |
rx.Observable<Integer> |
getSpectraCount()
Gets the spectrum count.
|
rx.Observable<Integer> |
getSpectraCount(int msLevel)
Gets the spectrum count.
|
rx.Observable<Spectrum> |
getSpectrum(long spectrumId)
Gets the spectrum.
|
rx.Observable<SpectrumData> |
getSpectrumData(long spectrumId)
Gets the spectrum data.
|
rx.Observable<DataEncoding> |
getSpectrumDataEncoding(long spectrumId)
Gets the spectrum data encoding.
|
rx.Observable<SpectrumHeader> |
getSpectrumHeader(long id)
Gets the spectrum header.
|
rx.Observable<Map<Long,SpectrumHeader>> |
getSpectrumHeaderById()
Gets each spectrum header mapped by its id.
|
rx.Observable<SpectrumHeader> |
getSpectrumHeaderForTime(float time,
int msLevel)
Gets the spectrum header for time.
|
SpectrumHeaderAsyncReader |
getSpectrumHeaderReader() |
rx.Observable<SpectrumHeader[]> |
getSpectrumHeaders()
Gets all spectrum headers.
|
rx.Observable<Peak[]> |
getSpectrumPeaks(int spectrumId)
Gets the spectrum peaks.
|
rx.Observable<Spectrum> |
getSpectrumStream() |
rx.Observable<Spectrum> |
getSpectrumStream(int msLevel)
Gets the ms spectrum iterator.
|
rx.Observable<Integer> |
getTableRecordsCount(String tableName)
Gets the table records count.
|
<T> SQLiteObservableJob<T> |
observeJobExecution(ISQLiteConnectionFunction<T> sqliteConnFunction) |
void |
waitForQueries()
Waits for the reader to stop execution of queries.
|
_setBBSizes, enableParamTreeLoading, enablePrecursorListLoading, enableScanListLoading, getAcquisitionMode, getBBSizes, getDbLocation, getDIAIsolationWindows, getEntityCache, getFirstSourceFileName, getMsnPeaksInMzRtRanges, getMsnSpectrumSlices, getMsnXic, getMsPeaksInMzRtRanges, getMsSpectrumSlices, getMsXic, getMsXicInMzRange, getMsXicInMzRtRanges, getMzDbHeader, getRunSliceData, getSpectrum, getSpectrumData, getSpectrumPeaks, isNoLossMode, isParamTreeLoadingEnabled, isPrecursorListLoadingEnabled, isScanListLoadingEnabled
public MzDbAsyncReader(File dbLocation, MzDbEntityCache entityCache, boolean logConnections) throws ClassNotFoundException, FileNotFoundException, com.almworks.sqlite4java.SQLiteException
dbLocation
- the db locationcacheEntities
- the cache entitieslogConnections
- the log connectionsClassNotFoundException
- the class not found exceptionFileNotFoundException
- the file not found exceptioncom.almworks.sqlite4java.SQLiteException
- the SQLite exceptionpublic MzDbAsyncReader(File dbLocation, boolean cacheEntities) throws ClassNotFoundException, FileNotFoundException, com.almworks.sqlite4java.SQLiteException
dbLocation
- the db locationcacheEntities
- the cache entitiesClassNotFoundException
- the class not found exceptionFileNotFoundException
- the file not found exceptioncom.almworks.sqlite4java.SQLiteException
- the sQ lite exceptionpublic MzDbAsyncReader(String dbPath, boolean cacheEntities) throws ClassNotFoundException, FileNotFoundException, com.almworks.sqlite4java.SQLiteException
dbPath
- the db pathcacheEntities
- the cache entitiesClassNotFoundException
- the class not found exceptionFileNotFoundException
- the file not found exceptioncom.almworks.sqlite4java.SQLiteException
- the sQ lite exceptionpublic void close()
close
in class AbstractMzDbReader
InterruptedException
public DataEncodingAsyncReader getDataEncodingReader()
getDataEncodingReader
in class AbstractMzDbReader
public SpectrumHeaderAsyncReader getSpectrumHeaderReader()
getSpectrumHeaderReader
in class AbstractMzDbReader
public RunSliceHeaderAsyncReader getRunSliceHeaderReader()
getRunSliceHeaderReader
in class AbstractMzDbReader
public void waitForQueries() throws InterruptedException
InterruptedException
protected com.almworks.sqlite4java.SQLiteConnection createBlockingSQLiteConnection() throws com.almworks.sqlite4java.SQLiteException
com.almworks.sqlite4java.SQLiteException
FileNotFoundException
ClassNotFoundException
public <T> SQLiteObservableJob<T> observeJobExecution(ISQLiteConnectionFunction<T> sqliteConnFunction)
public rx.Observable<String> getModelVersion()
public rx.Observable<String> getPwizMzDbVersion()
public rx.Observable<Float> getLastTime()
public rx.Observable<Integer> getMaxMsLevel()
public rx.Observable<int[]> getMzRange(int msLevel)
msLevel
- the ms levelpublic rx.Observable<Integer> getBoundingBoxesCount()
public rx.Observable<Integer> getBoundingBoxesCount(int runSliceId)
runSliceId
- the run slice idpublic rx.Observable<Integer> getCyclesCount()
public rx.Observable<Integer> getDataEncodingsCount()
public rx.Observable<Integer> getSpectraCount()
public rx.Observable<Integer> getSpectraCount(int msLevel)
public rx.Observable<Integer> getRunSlicesCount()
public rx.Observable<Integer> getTableRecordsCount(String tableName)
tableName
- the table namepublic rx.Observable<DataEncoding> getDataEncoding(int id)
id
- the idpublic rx.Observable<Map<Long,DataEncoding>> getDataEncodingBySpectrumId()
public rx.Observable<DataEncoding> getSpectrumDataEncoding(long spectrumId)
spectrumId
- the spectrum idpublic rx.Observable<RunSliceHeader[]> getRunSliceHeaders(int msLevel)
public rx.Observable<HashMap<Integer,RunSliceHeader>> getRunSliceHeaderById(int msLevel)
msLevel
- the ms levelpublic rx.Observable<RunSliceData> getRunSliceData(int runSliceId)
runSliceId
- the run slice idpublic rx.Observable<byte[]> getBoundingBoxData(int bbId)
bbId
- the bb idpublic rx.Observable<Long> getBoundingBoxFirstSpectrumId(long spectrumId)
spectrumId
- the spectrum idpublic rx.Observable<Float> getBoundingBoxMinMz(int bbId)
bbId
- the bb idpublic rx.Observable<Float> getBoundingBoxMinTime(int bbId)
bbId
- the bb idpublic rx.Observable<Integer> getBoundingBoxMsLevel(int bbId)
bbId
- the bb idpublic rx.Observable<SpectrumHeader[]> getMs1SpectrumHeaders()
public rx.Observable<Map<Long,SpectrumHeader>> getMs1SpectrumHeaderById()
public rx.Observable<SpectrumHeader[]> getMs2SpectrumHeaders()
public rx.Observable<Map<Long,SpectrumHeader>> getMs2SpectrumHeaderById()
public rx.Observable<SpectrumHeader[]> getSpectrumHeaders()
public rx.Observable<Map<Long,SpectrumHeader>> getSpectrumHeaderById()
public rx.Observable<SpectrumHeader> getSpectrumHeader(long id)
id
- the idpublic rx.Observable<SpectrumHeader> getSpectrumHeaderForTime(float time, int msLevel)
time
- the timemsLevel
- the ms levelpublic rx.Observable<SpectrumData> getSpectrumData(long spectrumId)
spectrumId
- the spectrum idpublic rx.Observable<Spectrum> getSpectrum(long spectrumId)
spectrumId
- the spectrum idpublic rx.Observable<Peak[]> getSpectrumPeaks(int spectrumId)
spectrumId
- the spectrum idpublic rx.Observable<SpectrumSlice[]> getMsSpectrumSlices(double minMz, double maxMz, float minRt, float maxRt)
minmz
- the minMzmaxmz
- the maxMzminrt
- the minRtmaxrt
- the maxRtmsLevel
- the ms levelpublic rx.Observable<SpectrumSlice[]> getMsnSpectrumSlices(double parentMz, double minFragMz, double maxFragMz, float minRt, float maxRt)
public rx.Observable<BoundingBox> getBoundingBoxStream(int msLevel)
msLevel
- the ms levelpublic rx.Observable<Spectrum> getSpectrumStream()
public rx.Observable<Spectrum> getSpectrumStream(int msLevel)
msLevel
- the ms levelpublic rx.Observable<RunSlice> getLcMsRunSliceStream()
public rx.Observable<RunSlice> getLcMsRunSliceStream(double minRunSliceMz, double maxRunSliceMz)
minRunSliceMz
- minRunSliceMz
- public rx.Observable<RunSlice> getLcMsnRunSliceStream(double minParentMz, double maxParentMz)
minParentMz
- maxParentMz
- public rx.Observable<RunSlice> getLcMsnRunSliceStream(double minParentMz, double maxParentMz, double minRunSliceMz, double maxRunSliceMz)
msLevel
- minParentMz
- maxParentMz
- public rx.Observable<AcquisitionMode> getAcquisitionMode()
public rx.Observable<IsolationWindow[]> getDIAIsolationWindows()
public List<InstrumentConfiguration> getInstrumentConfigurations() throws com.almworks.sqlite4java.SQLiteException
getInstrumentConfigurations
in class AbstractMzDbReader
com.almworks.sqlite4java.SQLiteException
public List<Run> getRuns() throws com.almworks.sqlite4java.SQLiteException
getRuns
in class AbstractMzDbReader
com.almworks.sqlite4java.SQLiteException
public List<Sample> getSamples() throws com.almworks.sqlite4java.SQLiteException
getSamples
in class AbstractMzDbReader
com.almworks.sqlite4java.SQLiteException
public List<Software> getSoftwareList() throws com.almworks.sqlite4java.SQLiteException
getSoftwareList
in class AbstractMzDbReader
com.almworks.sqlite4java.SQLiteException
public List<SourceFile> getSourceFiles() throws com.almworks.sqlite4java.SQLiteException
getSourceFiles
in class AbstractMzDbReader
com.almworks.sqlite4java.SQLiteException
public rx.Observable<Peak[]> getMsXicInMzRange(double minMz, double maxMz, XicMethod method)
public rx.Observable<Peak[]> getMsXicInMzRtRanges(double minMz, double maxMz, float minRt, float maxRt, XicMethod method)
public rx.Observable<Peak[]> getMsXic(double mz, double mzTolInDa, float minRt, float maxRt, XicMethod method)
public rx.Observable<Peak[]> getMsnXic(double parentMz, double fragmentMz, double fragmentMzTolInDa, float minRt, float maxRt, XicMethod method)
public rx.Observable<Peak[]> getMsPeaksInMzRtRanges(double minMz, double maxMz, float minRt, float maxRt)
public rx.Observable<Peak[]> getMsnPeaksInMzRtRanges(double parentMz, double minFragMz, double maxFragMz, float minRt, float maxRt)
Copyright © 2019. All rights reserved.