Package com.compomics.util.pride
Class PrideObjectsFactory
java.lang.Object
com.compomics.util.pride.PrideObjectsFactory
This factory manages the pride objects saved in the user folder.
- Author:
- Marc Vaudel
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionvoidaddContactGroup(ContactGroup contactGroup) Adds a contact group in the PRIDE objects.voidaddInstrument(Instrument instrument) Adds a instrument in the PRIDE objects.voidaddProtocol(Protocol protocol) Adds a protocol in the PRIDE objects.voidaddReferenceGroup(ReferenceGroup referenceGroup) Adds a reference group in the PRIDE objects.voidAdds a sample in the PRIDE objects.voiddeleteContactGroup(ContactGroup contactGroup) Delete the given contact group.voiddeleteInstrument(Instrument instrument) Delete the given instrument.voiddeleteProtocol(Protocol protocol) Delete the given protocol.voiddeleteReferenceGroup(ReferenceGroup referenceGroup) Delete the given reference group.voiddeleteSample(Sample sample) Delete the given sample.Returns the contact groups.static PrideObjectsFactoryMethod returning the instance of the factory.Returns the instruments.static StringReturns the folder where pride annotation information should be saved.Returns the protocols.Returns the utilities PTM to pride map.Returns the reference groups.Returns the samples.static voidsetPrideFolder(String prideFolder) Sets the folder where pride annotation information should be saved.voidsetPtmToPrideMap(PtmToPrideMap ptmToPrideMap) Sets a new PTM to PRIDE map.
-
Field Details
-
extension
The extension to use when saving objects. By default cus for compomics utilities serialization- See Also:
-
-
Method Details
-
getInstance
public static PrideObjectsFactory getInstance() throws FileNotFoundException, IOException, ClassNotFoundExceptionMethod returning the instance of the factory.- Returns:
- the instance of the factory
- Throws:
FileNotFoundException- exception thrown whenever the file was not foundIOException- exception thrown whenever an error occurred while writing the fileClassNotFoundException- exception thrown whenever an error occurred while serializing the file
-
addContactGroup
Adds a contact group in the PRIDE objects.- Parameters:
contactGroup- the contact group to add- Throws:
IOException- exception thrown whenever an error occurred while saving
-
deleteContactGroup
Delete the given contact group.- Parameters:
contactGroup- the group to delete
-
addProtocol
Adds a protocol in the PRIDE objects.- Parameters:
protocol- the protocol to add- Throws:
IOException- exception thrown whenever an error occurred while saving
-
deleteProtocol
Delete the given protocol.- Parameters:
protocol- the protocol to delete
-
addInstrument
Adds a instrument in the PRIDE objects.- Parameters:
instrument- the instrument to add- Throws:
IOException- exception thrown whenever an error occurred while saving
-
deleteInstrument
Delete the given instrument.- Parameters:
instrument- the instrument to delete
-
addReferenceGroup
Adds a reference group in the PRIDE objects.- Parameters:
referenceGroup- the reference group to add- Throws:
IOException- exception thrown whenever an error occurred while saving
-
deleteReferenceGroup
Delete the given reference group.- Parameters:
referenceGroup- the reference group to delete
-
addSample
Adds a sample in the PRIDE objects.- Parameters:
sample- the sample to add- Throws:
IOException- exception thrown whenever an error occurred while saving
-
deleteSample
Delete the given sample.- Parameters:
sample- the sample to delete
-
setPtmToPrideMap
Sets a new PTM to PRIDE map.- Parameters:
ptmToPrideMap- a new PTM to pride map- Throws:
FileNotFoundException- if a FileNotFoundException occursIOException- if an IOException occurs
-
getContactGroups
Returns the contact groups.- Returns:
- the contact groups
-
getInstruments
Returns the instruments.- Returns:
- the instruments
-
getProtocols
Returns the protocols.- Returns:
- the protocols
-
getPtmToPrideMap
Returns the utilities PTM to pride map.- Returns:
- the utilities PTM to pride map
-
getReferenceGroups
Returns the reference groups.- Returns:
- the reference groups
-
getSamples
Returns the samples.- Returns:
- the samples
-
getPrideFolder
Returns the folder where pride annotation information should be saved.- Returns:
- the folder where pride annotation information should be saved
-
setPrideFolder
Sets the folder where pride annotation information should be saved.- Parameters:
prideFolder- the folder where pride annotation information should be saved
-