Package org.biojava.nbio.structure
Enum EntityType
- java.lang.Object
-
- java.lang.Enum<EntityType>
-
- org.biojava.nbio.structure.EntityType
-
- All Implemented Interfaces:
Serializable
,Comparable<EntityType>
public enum EntityType extends Enum<EntityType>
The type of entity (polymer, non-polymer, water, macrolide) as defined in the mmCIF dictionary:Entities are of four types: polymer, non-polymer, macrolide and water.
Note that the water category includes only water; ordered solvent such as sulfate ion or acetone would be described as individual non-polymer entities. It is not clear what macrolides are, but they appear to be supported since mmCIF 4.0.
- Author:
- Anthony Bradley, Jose Duarte
-
-
Enum Constant Summary
Enum Constants Enum Constant Description MACROLIDE
Macrolide.NONPOLYMER
Non-polymeric entities: ligands, metal ions, buffer molecules, etcPOLYMER
Polymeric entities: poly-peptides and nucleotide chainsWATER
Water
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static EntityType
entityTypeFromString(String entityType)
Creates a new EntityType from a String value.String
getEntityType()
Returns the type of the Entity as a Stringstatic EntityType
valueOf(String name)
Returns the enum constant of this type with the specified name.static EntityType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
POLYMER
public static final EntityType POLYMER
Polymeric entities: poly-peptides and nucleotide chains
-
NONPOLYMER
public static final EntityType NONPOLYMER
Non-polymeric entities: ligands, metal ions, buffer molecules, etc
-
WATER
public static final EntityType WATER
Water
-
MACROLIDE
public static final EntityType MACROLIDE
Macrolide. Supported in mmCIF 4.0 dictionary. Not clear what it refers to.
-
-
Method Detail
-
values
public static EntityType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (EntityType c : EntityType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static EntityType valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
getEntityType
public String getEntityType()
Returns the type of the Entity as a String- Returns:
- String representation of the entity type.
-
entityTypeFromString
public static EntityType entityTypeFromString(String entityType)
Creates a new EntityType from a String value. Returns null if entityType is null or not one of the supported standard types.- Parameters:
entityType
- String value , should be one of "polymer","non-polymer","water","macrolide"- Returns:
- an EntityType object
-
-