public class PsmIterator extends Object
Modifier and Type | Field and Description |
---|---|
int |
defaultBatchSize
The default batch size.
|
double |
defaultMargin
The default margin to use to start batch loading before the loading index
is reached.
|
Constructor and Description |
---|
PsmIterator(ArrayList<String> spectrumKeys,
Identification identification,
ArrayList<UrParameter> psmParameters,
boolean loadAssumptions,
WaitingHandler waitingHandler)
Constructor.
|
PsmIterator(ArrayList<String> spectrumKeys,
Identification identification,
boolean loadAssumptions,
WaitingHandler waitingHandler)
Constructor.
|
PsmIterator(Identification identification,
ArrayList<UrParameter> psmParameters,
boolean loadAssumptions,
WaitingHandler waitingHandler)
Constructor.
|
PsmIterator(Identification identification,
boolean loadAssumptions,
WaitingHandler waitingHandler)
Constructor.
|
PsmIterator(String spectrumFile,
ArrayList<String> spectrumKeys,
Identification identification,
ArrayList<UrParameter> psmParameters,
boolean loadAssumptions,
WaitingHandler waitingHandler)
Constructor.
|
PsmIterator(String spectrumFile,
ArrayList<String> spectrumKeys,
Identification identification,
boolean loadAssumptions,
WaitingHandler waitingHandler)
Constructor.
|
PsmIterator(String spectrumFile,
Identification identification,
ArrayList<UrParameter> psmParameters,
boolean loadAssumptions,
WaitingHandler waitingHandler)
Constructor.
|
PsmIterator(String spectrumFile,
Identification identification,
boolean loadAssumptions,
ArrayList<UrParameter> psmParameters,
WaitingHandler waitingHandler)
Constructor.
|
PsmIterator(String spectrumFile,
Identification identification,
boolean loadAssumptions,
WaitingHandler waitingHandler)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean |
hasNext()
Indicates whether the iterator is done iterating.
|
SpectrumMatch |
next()
Returns the next match and updates the buffer.
|
void |
setBatchSize(int batchSize)
Set the batch size.
|
public final int defaultBatchSize
public final double defaultMargin
public PsmIterator(String spectrumFile, ArrayList<String> spectrumKeys, Identification identification, ArrayList<UrParameter> psmParameters, boolean loadAssumptions, WaitingHandler waitingHandler)
spectrumFile
- the spectrum file to iteratespectrumKeys
- the keys to iterateidentification
- the identification where to get the matches frompsmParameters
- the parameters to load along with the matchesloadAssumptions
- if true the assumptions will be loaded as wellwaitingHandler
- the waiting handlerpublic PsmIterator(ArrayList<String> spectrumKeys, Identification identification, ArrayList<UrParameter> psmParameters, boolean loadAssumptions, WaitingHandler waitingHandler)
spectrumKeys
- the keys to iterateidentification
- the identification where to get the matches frompsmParameters
- the parameters to load along with the matchesloadAssumptions
- if true the assumptions will be loaded as wellwaitingHandler
- the waiting handlerpublic PsmIterator(ArrayList<String> spectrumKeys, Identification identification, boolean loadAssumptions, WaitingHandler waitingHandler)
spectrumKeys
- the keys to iterateidentification
- the identification where to get the matches fromloadAssumptions
- if true the assumptions will be loaded as wellwaitingHandler
- the waiting handlerpublic PsmIterator(String spectrumFile, ArrayList<String> spectrumKeys, Identification identification, boolean loadAssumptions, WaitingHandler waitingHandler)
spectrumFile
- the spectrum file to iteratespectrumKeys
- the keys to iterateidentification
- the identification where to get the matches fromloadAssumptions
- if true the assumptions will be loaded as wellwaitingHandler
- the waiting handlerpublic PsmIterator(String spectrumFile, Identification identification, ArrayList<UrParameter> psmParameters, boolean loadAssumptions, WaitingHandler waitingHandler)
spectrumFile
- the spectrum file to iterateidentification
- the identification where to get the matches frompsmParameters
- the parameters to load along with the matchesloadAssumptions
- if true the assumptions will be loaded as wellwaitingHandler
- the waiting handlerpublic PsmIterator(String spectrumFile, Identification identification, boolean loadAssumptions, WaitingHandler waitingHandler)
spectrumFile
- the spectrum file to iterateidentification
- the identification where to get the matches fromloadAssumptions
- if true the assumptions will be loaded as wellwaitingHandler
- the waiting handlerpublic PsmIterator(String spectrumFile, Identification identification, boolean loadAssumptions, ArrayList<UrParameter> psmParameters, WaitingHandler waitingHandler)
spectrumFile
- the spectrum file to iterateidentification
- the identification where to get the matches frompsmParameters
- the parameters to load along with the matchesloadAssumptions
- if true the assumptions will be loaded as wellwaitingHandler
- the waiting handlerpublic PsmIterator(Identification identification, boolean loadAssumptions, WaitingHandler waitingHandler)
identification
- the identification where to get the matches fromloadAssumptions
- if true the assumptions will be loaded as wellwaitingHandler
- the waiting handlerpublic PsmIterator(Identification identification, ArrayList<UrParameter> psmParameters, boolean loadAssumptions, WaitingHandler waitingHandler)
identification
- the identification where to get the matches frompsmParameters
- the parameters to load along with the matchesloadAssumptions
- if true the assumptions will be loaded as wellwaitingHandler
- the waiting handlerpublic boolean hasNext()
public SpectrumMatch next() throws SQLException, IOException, ClassNotFoundException, InterruptedException
SQLException
- exception thrown whenever an error occurred while
interacting with the matches databaseIOException
- exception thrown whenever an error occurred while
interacting with the matches databaseClassNotFoundException
- exception thrown whenever an error
occurred while deserializing a match from the databaseInterruptedException
- exception thrown whenever a threading issue
occurred while retrieving the matchpublic void setBatchSize(int batchSize)
batchSize
- the batch sizeCopyright © 2016. All rights reserved.