Package com.compomics.util.io
Class MascotEnzymeReader
java.lang.Object
com.compomics.util.io.MascotEnzymeReader
public class MascotEnzymeReader extends Object
This class will load Enzyme properties from a Mascot
(www.matrixscience.com)
formatted text file.
- Author:
- Lennart Martens
-
Constructor Summary
Constructors Constructor Description MascotEnzymeReader()
Empty default constructorMascotEnzymeReader(InputStream aEnzymeStream)
The constructor allows you specify to specify an inputstream from which to load the enzyme information.MascotEnzymeReader(String aEnzymeFile)
The constructor requires that you specify the file from which to load the enzyme information. -
Method Summary
Modifier and Type Method Description Enzyme
getEnzyme(String aTitle)
This method will return a copy of an Enzyme instance for the given name, or 'null' if the enzyme was not found in the current list.String[]
getEnzymeNames()
This method reports on all the known names for enzymes in this reader.
-
Constructor Details
-
MascotEnzymeReader
public MascotEnzymeReader()Empty default constructor -
MascotEnzymeReader
The constructor requires that you specify the file from which to load the enzyme information. Information is immediately loaded upon construction.- Parameters:
aEnzymeFile
- String with the filename of the mascot enzyme file.- Throws:
IOException
- when the enzyme file could not be read.
-
MascotEnzymeReader
The constructor allows you specify to specify an inputstream from which to load the enzyme information. Note that the stream is closed after loading!!! Information is immediately loaded upon construction.- Parameters:
aEnzymeStream
- InputStream to the mascot enzyme file.- Throws:
IOException
- when the enzyme file could not be read.
-
-
Method Details
-
getEnzymeNames
This method reports on all the known names for enzymes in this reader.- Returns:
- String[] with all the names.
-
getEnzyme
This method will return a copy of an Enzyme instance for the given name, or 'null' if the enzyme was not found in the current list.- Parameters:
aTitle
- String with the title (name) of the Enzyme to retrieve.- Returns:
- Enzyme when the specified enzyme was found, 'null' otherwise!
-