info.bioinfweb.jphyloio.events.type

## Enum EventContentType

- java.lang.Object
- - java.lang.Enum<EventContentType>
  - - info.bioinfweb.jphyloio.events.type.EventContentType

- All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<EventContentType>

      public enum EventContentType
      extends java.lang.Enum<EventContentType>

  Enumerates the content types of a `JPhyloIOEvent`. Elements of each content type can either occur in one version in combination with `EventTopologyType.SOLE` or in two versions in combination with `EventTopologyType.START` or `EventTopologyType.END`.

  The documentation of the single types includes information on which event classes are used with each type and whether it is separated into a start and end event or not. In addition, the documentation of `JPhyloIOEventReader` contains a full grammar of JPhyloIO event streams.

  Author:
    Ben Stöver, Sarah Wiechers
  See Also:
    `JPhyloIOEventReader`, `EventTopologyType`, `EventType`

- - ### Enum Constant Summary

    Enum Constants
    Enum Constant and Description
    `ALIGNMENT` Indicates the start or the end of the contents of a matrix.
    `CHARACTER_DEFINITION` Indicates a defined character (alignment column).
    `CHARACTER_SET` Indicates the start or end of a sequence of `CHARACTER_SET_INTERVAL` events.
    `CHARACTER_SET_INTERVAL` Indicates a single interval of a character set.
    `COMMENT` Indicates a comment found in the underlying data source.
    `DOCUMENT` Indicates the start or the end of the read document.
    `EDGE` Indicates an edge in a phylogenetic tree or network.
    `LITERAL_META` Indicates the start or the end of a literal meta information.
    `LITERAL_META_CONTENT` Indicates literal metadata content was found in the underlying data source.
    `NETWORK` Indicates the start or the end of the contents of a phylogenetic network.
    `NODE` Indicates a node in a phylogenetic tree or network.
    `NODE_EDGE_SET` Indicates the start or end of a sequence of `SET_ELEMENT` events that define a set of node and edges (including root edges).
    `OTU` Indicates the start or the end of an OTU/taxon definition.
    `OTU_LIST` Indicates the start or the end of a list of OTU/taxon definitions.
    `OTU_SET` Indicates the start or end of a sequence of `SET_ELEMENT` events that define a set of OTUs.
    `RESOURCE_META` Indicates the start or the end of a resource meta information.
    `ROOT_EDGE` Indicates a root edge in a phylogenetic tree.
    `SEQUENCE` Indicates the start or the end of the contents of a sequence in a matrix.
    `SEQUENCE_SET` Indicates the start or end of a sequence of `SET_ELEMENT` events that define a set of sequences.
    `SEQUENCE_TOKENS` Indicates a number of sequence tokens.
    `SET_ELEMENT` Indicates a member of a set that is linked by its ID.
    `SINGLE_SEQUENCE_TOKEN` Indicates a number a single sequence token.
    `SINGLE_TOKEN_DEFINITION` Indicates the definition of a single sequence token symbol.
    `TOKEN_SET_DEFINITION` Indicates the start or end of a token set definition.
    `TREE` Indicates the start or the end of the contents of a phylogenetic tree.
    `TREE_NETWORK_GROUP` Indicates the start or the end of a sequence of phylogenetic trees and network.
    `TREE_NETWORK_SET` Indicates the start or end of a sequence of `SET_ELEMENT` events that define a set of trees and networks.
    `UNKNOWN_COMMAND` Events of this type are used by some readers to provide the application with contents of unknown commands in a format.

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static EventContentType` | `valueOf(java.lang.String name)` Returns the enum constant of this type with the specified name.
    `static EventContentType[]` | `values()` Returns an array containing the constants of this enum type, in the order they are declared.

    - ### Methods inherited from class java.lang.Enum

      `clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf`

    - ### Methods inherited from class java.lang.Object

      `getClass, notify, notifyAll, wait, wait, wait`

- - ### Enum Constant Detail

    - #### DOCUMENT

          public static final EventContentType DOCUMENT

      Indicates the start or the end of the read document.

      Both start and end events of this type are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### RESOURCE_META

          public static final EventContentType RESOURCE_META

      Indicates the start or the end of a resource meta information.

      Start events of this type are instances of `ResourceMetadataEvent`, end events are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### LITERAL_META

          public static final EventContentType LITERAL_META

      Indicates the start or the end of a literal meta information.

      Start events of this type are instances of `LiteralMetadataEvent`, end events are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### LITERAL_META_CONTENT

          public static final EventContentType LITERAL_META_CONTENT

      Indicates literal metadata content was found in the underlying data source.

      Events of this type are instances of `LiteralMetadataContentEvent` and always have the topology type `EventTopologyType.SOLE` and therefore no nested events.

    - #### UNKNOWN_COMMAND

          public static final EventContentType UNKNOWN_COMMAND

      Events of this type are used by some readers to provide the application with contents of unknown commands in a format.

      Events of this type are instances of `UnknownCommandEvent` and always have the topology type `EventTopologyType.SOLE`.

    - #### COMMENT

          public static final EventContentType COMMENT

      Indicates a comment found in the underlying data source.

      Events of this type are instances of `CommentEvent` and always have the topology type `EventTopologyType.SOLE` and therefore no nested events.

    - #### OTU_LIST

          public static final EventContentType OTU_LIST

      Indicates the start or the end of a list of OTU/taxon definitions.

      Start events of this type are instances of `LabeledIDEvent`, end events are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### OTU

          public static final EventContentType OTU

      Indicates the start or the end of an OTU/taxon definition.

      Start events of this type are instances of `LabeledIDEvent`, end events are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### ALIGNMENT

          public static final EventContentType ALIGNMENT

      Indicates the start or the end of the contents of a matrix.

      Start events of this type are instances of `LinkedLabeledIDEvent`, end events are instances of `ConcreteJPhyloIOEvent`. Start events optionally link an OTU list.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### CHARACTER_DEFINITION

          public static final EventContentType CHARACTER_DEFINITION

      Indicates a defined character (alignment column). Events of this type may have nested elements. Events of this type are optional and most readers will create them only if a character label or associated metadata is present or if an ID has explicitly been defined in the document that is read.

      Start events of this type are instances of `CharacterDefinitionEvent`, end events are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### SEQUENCE

          public static final EventContentType SEQUENCE

      Indicates the start or the end of the contents of a sequence in a matrix.

      Start events of this type are instances of `LinkedLabeledIDEvent`, end events are instances of `PartEndEvent`. Start events optionally link a single OTU.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### SEQUENCE_TOKENS

          public static final EventContentType SEQUENCE_TOKENS

      Indicates a number of sequence tokens. Events of this type never have nested elements.

      Events of this type are instances of `SequenceTokensEvent` and always have the topology type `EventTopologyType.SOLE`.

    - #### SINGLE_SEQUENCE_TOKEN

          public static final EventContentType SINGLE_SEQUENCE_TOKEN

      Indicates a number a single sequence token. Events of this type may have nested elements.

      Start events of this type are instances of `SingleSequenceTokenEvent`, end events are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### TREE_NETWORK_GROUP

          public static final EventContentType TREE_NETWORK_GROUP

      Indicates the start or the end of a sequence of phylogenetic trees and network. (Such group corresponds e.g. to the contents of a `TREES` block in Nexus or a `trees` tag in NeXML.)

      Start events of this type are instances of `LinkedLabeledIDEvent`, end events are instances of `ConcreteJPhyloIOEvent`. Start events optionally link an OTU list that is valid for all contained trees and networks.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### NETWORK

          public static final EventContentType NETWORK

      Indicates the start or the end of the contents of a phylogenetic network.

      Start events of this type are instances of `LabeledIDEvent`, end events are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### TREE

          public static final EventContentType TREE

      Indicates the start or the end of the contents of a phylogenetic tree.

      Start events of this type are instances of `LabeledIDEvent`, end events are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

      In some formats metaevents indicating whether the tree shall be displayed rooted or unrooted may follow the start event of this type.

    - #### NODE

          public static final EventContentType NODE

      Indicates a node in a phylogenetic tree or network.

      Start events of this type are instances of `NodeEvent`, end events are instances of `ConcreteJPhyloIOEvent`. Start events optionally link a single OTU.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### EDGE

          public static final EventContentType EDGE

      Indicates an edge in a phylogenetic tree or network.

      Start events of this type are instances of `EdgeEvent`, end events are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### ROOT_EDGE

          public static final EventContentType ROOT_EDGE

      Indicates a root edge in a phylogenetic tree. Events of this type are not allowed to be nested under networks and at most one may be nested under a tree.

      Start events of this type are instances of `EdgeEvent`, end events are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### TOKEN_SET_DEFINITION

          public static final EventContentType TOKEN_SET_DEFINITION

      Indicates the start or end of a token set definition.

      Start events of this type are instances of `TokenSetDefinitionEvent`, end events are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### SINGLE_TOKEN_DEFINITION

          public static final EventContentType SINGLE_TOKEN_DEFINITION

      Indicates the definition of a single sequence token symbol. Such events are nested in `TOKEN_SET_DEFINITION`.

      Start events of this type are instances of `SingleTokenDefinitionEvent`, end events are instances of `ConcreteJPhyloIOEvent`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### CHARACTER_SET

          public static final EventContentType CHARACTER_SET

      Indicates the start or end of a sequence of `CHARACTER_SET_INTERVAL` events.

      Start events of this type are instances of `LinkedLabeledIDEvent`, end events are instances of `PartEndEvent`. The start events link a matrix by their ID using `LinkedLabeledIDEvent.getLinkedID()`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### CHARACTER_SET_INTERVAL

          public static final EventContentType CHARACTER_SET_INTERVAL

      Indicates a single interval of a character set. Such events are nested in `CHARACTER_SET` and `TOKEN_SET_DEFINITION`.

      Events of this type are instances of `CharacterSetIntervalEvent` and always have the topology type `EventTopologyType.SOLE`.

    - #### SET_ELEMENT

          public static final EventContentType SET_ELEMENT

      Indicates a member of a set that is linked by its ID. Such events are nested e.g. in `OTU_SET` and `TREE_NETWORK_SET`. (Note that character and token sets represent their members in a different way).

      Events of this type are instances of `SetElementEvent` and always have the topology type `EventTopologyType.SOLE`.

    - #### OTU_SET

          public static final EventContentType OTU_SET

      Indicates the start or end of a sequence of `SET_ELEMENT` events that define a set of OTUs.

      Start events of this type are instances of `LinkedLabeledIDEvent`, end events are instances of `PartEndEvent`. The start events link an OTU list by their ID using `LinkedLabeledIDEvent.getLinkedID()`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### SEQUENCE_SET

          public static final EventContentType SEQUENCE_SET

      Indicates the start or end of a sequence of `SET_ELEMENT` events that define a set of sequences.

      Start events of this type are instances of `LinkedLabeledIDEvent`, end events are instances of `PartEndEvent`. The start events link an alignment by their ID using `LinkedLabeledIDEvent.getLinkedID()`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### TREE_NETWORK_SET

          public static final EventContentType TREE_NETWORK_SET

      Indicates the start or end of a sequence of `SET_ELEMENT` events that define a set of trees and networks.

      Start events of this type are instances of `LinkedLabeledIDEvent`, end events are instances of `PartEndEvent`. The start events link a tree/network group by their ID using `LinkedLabeledIDEvent.getLinkedID()`.

      This content type will never be combined with `EventTopologyType.SOLE`.

    - #### NODE_EDGE_SET

          public static final EventContentType NODE_EDGE_SET

      Indicates the start or end of a sequence of `SET_ELEMENT` events that define a set of node and edges (including root edges).

      Start events of this type are instances of `LinkedLabeledIDEvent`, end events are instances of `PartEndEvent`. The start events link a tree or network by their ID using `LinkedLabeledIDEvent.getLinkedID()`.

      This content type will never be combined with `EventTopologyType.SOLE`.

  - ### Method Detail

    - #### values

          public static EventContentType[] 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 (EventContentType c : EventContentType.values())
              System.out.println(c);

      Returns:
        an array containing the constants of this enum type, in the order they are declared

    - #### valueOf

          public static EventContentType valueOf(java.lang.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:
        `java.lang.IllegalArgumentException` - if this enum type has no constant with the specified name
        `java.lang.NullPointerException` - if the argument is null