Class AnnotationConfiguration

Namespace
NOpenNLP.Tools.Formats.Brat
Assembly
NOpenNLP.Tools.dll
public class AnnotationConfiguration
Inheritance
AnnotationConfiguration
Inherited Members

Constructors

AnnotationConfiguration(IDictionary<string, string>)

public AnnotationConfiguration(IDictionary<string, string> typeToClassMap)

Parameters

typeToClassMap IDictionary<string, string>

Fields

ATTRIBUTE_TYPE

public const string ATTRIBUTE_TYPE = "Attribute"

Field Value

string

ENTITY_TYPE

public const string ENTITY_TYPE = "Entity"

Field Value

string

EVENT_TYPE

public const string EVENT_TYPE = "Event"

Field Value

string

RELATION_TYPE

public const string RELATION_TYPE = "Relation"

Field Value

string

SPAN_TYPE

public const string SPAN_TYPE = "Span"

Field Value

string

Methods

GetTypeClass(string)

Gets the type class registered for type.

public string? GetTypeClass(string type)

Parameters

type string

the annotation type to look up

Returns

string

the type class, or null if type is not configured

Parse(FileInfo)

Parses an annotation configuration from the given annConfigFile.

public static AnnotationConfiguration Parse(FileInfo annConfigFile)

Parameters

annConfigFile FileInfo

the annotation.conf file to read

Returns

AnnotationConfiguration

the parsed AnnotationConfiguration

Exceptions

IOException

if there is an error during reading

Parse(Stream)

Parses an annotation configuration from the given in stream.

public static AnnotationConfiguration Parse(Stream @in)

Parameters

in Stream

the stream to read the annotation.conf contents from

Returns

AnnotationConfiguration

the parsed AnnotationConfiguration

Exceptions

IOException

if there is an error during reading