Class ModifiedCompoundImpl
java.lang.Object
org.biojava.nbio.protmod.structure.ModifiedCompoundImpl
- All Implemented Interfaces:
Serializable
,Comparable<ModifiedCompound>
,ModifiedCompound
public class ModifiedCompoundImpl
extends Object
implements ModifiedCompound, Serializable, Comparable<ModifiedCompound>
- Since:
- 3.0
- Author:
- Jianjiong Gao
- See Also:
-
Field Summary
-
Constructor Summary
ConstructorDescriptionModifiedCompoundImpl
(ProteinModification modification, Collection<StructureAtomLinkage> linkages) ModifiedCompoundImpl
(ProteinModification modification, StructureGroup modifiedResidue) Create a ModifiedCompoundImpl that has only one involved component. -
Method Summary
Modifier and TypeMethodDescriptionboolean
addAtomLinkage
(StructureAtomLinkage linkage) Add a linkage.void
addAtomLinkages
(Collection<StructureAtomLinkage> linkages) Add a collections of linkages.int
compareTo
(ModifiedCompound compound) boolean
boolean
return a description of this compoundgetGroups
(boolean isAminoAcid) Deprecated.use getModification().getId()int
hashCode()
void
setAtomLinkages
(Set<StructureAtomLinkage> linkages) Set atom linkagesvoid
setDescription
(String desc) void
setGroups
(Set<StructureGroup> groups) void
setModification
(ProteinModification protmod) toString()
-
Field Details
-
newline
-
-
Constructor Details
-
ModifiedCompoundImpl
public ModifiedCompoundImpl() -
ModifiedCompoundImpl
Create a ModifiedCompoundImpl that has only one involved component. Use this constructor for a modified residue.- Parameters:
modification
-ProteinModification
.modifiedResidue
- modified group.- Throws:
IllegalArgumentException
- if either argument is null.
-
ModifiedCompoundImpl
public ModifiedCompoundImpl(ProteinModification modification, Collection<StructureAtomLinkage> linkages) - Parameters:
modification
- ProteinModification.linkages
- a collection of atom linkages.- See Also:
-
-
Method Details
-
setModification
- Specified by:
setModification
in interfaceModifiedCompound
-
getModification
- Specified by:
getModification
in interfaceModifiedCompound
- Returns:
ProteinModificationBean
occurred on the residue.
-
getOriginalModificationId
Deprecated.use getModification().getId()- Returns:
- the original modification ID.
-
getGroups
- Specified by:
getGroups
in interfaceModifiedCompound
- Returns:
- a set of involved group.
-
getGroups
- Specified by:
getGroups
in interfaceModifiedCompound
- Parameters:
isAminoAcid
- true if amino acids.- Returns:
- a set of involved group of the type.
-
setGroups
- Specified by:
setGroups
in interfaceModifiedCompound
-
getAtomLinkages
- Specified by:
getAtomLinkages
in interfaceModifiedCompound
- Returns:
- a set of atom linkages.
- See Also:
-
#getLinkedGroupPairs
StructureAtomLinkage
-
setAtomLinkages
Description copied from interface:ModifiedCompound
Set atom linkages- Specified by:
setAtomLinkages
in interfaceModifiedCompound
-
addAtomLinkage
Description copied from interface:ModifiedCompound
Add a linkage. Add new the involved groups first usingaddGroup
.- Specified by:
addAtomLinkage
in interfaceModifiedCompound
- Parameters:
linkage
- an atom linkage.- Returns:
- true if this linkage was not already contained.
- See Also:
-
addAtomLinkages
Description copied from interface:ModifiedCompound
Add a collections of linkages.- Specified by:
addAtomLinkages
in interfaceModifiedCompound
- Parameters:
linkages
- an atom linkage.
-
crossChains
public boolean crossChains()- Specified by:
crossChains
in interfaceModifiedCompound
- Returns:
- true if groups from multiple chains were involved
-
toString
-
getDescription
Description copied from interface:ModifiedCompound
return a description of this compound- Specified by:
getDescription
in interfaceModifiedCompound
- Returns:
- a description
-
setDescription
- Specified by:
setDescription
in interfaceModifiedCompound
-
compareTo
- Specified by:
compareTo
in interfaceComparable<ModifiedCompound>
-
equals
-
hashCode
public int hashCode()
-