BratDocument (Apache OpenNLP :: Core :: Formats 3.0.0-M4 API)
Description: declaration: package: opennlp.tools.formats.brat, class: BratDocument

Package opennlp.tools.formats.brat

# Class BratDocument

java.lang.Object
opennlp.tools.formats.brat.BratDocument

public class BratDocument extends Object
Brat (brat rapid annotation tool) is based on the stav visualiser which was originally made in order to visualise BioNLP'11 Shared Task data.

Data can be found on this web site.

Information about the format are found on this web site.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `BratDocument(AnnotationConfiguration config, String id, String text, Collection<BratAnnotation> annotations)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `BratAnnotation`
  `getAnnotation(String id)`
  `Collection<BratAnnotation>`
  `getAnnotations()`
  `AnnotationConfiguration`
  `getConfig()`
  `String`
  `getId()`
  `String`
  `getText()`
  `static BratDocument`
  `parseDocument(AnnotationConfiguration config, String id, InputStream txtIn, InputStream annIn)`

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

  `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### BratDocument

    public BratDocument(AnnotationConfiguration config, String id, String text, Collection<BratAnnotation> annotations)

- ## Method Details

  - ### getConfig

    public AnnotationConfiguration getConfig()

  - ### getId

    public String getId()

  - ### getText

    public String getText()

  - ### getAnnotation

    public BratAnnotation getAnnotation(String id)

  - ### getAnnotations

    public Collection<BratAnnotation> getAnnotations()

  - ### parseDocument

    public static BratDocument parseDocument(AnnotationConfiguration config, String id, InputStream txtIn, InputStream annIn) throws IOException
    Throws:
      `IOException`