Package nzilbb.labbcat.model
Class MatchId
java.lang.Object
nzilbb.labbcat.model.MatchId
Interpreter for match ID strings.
The schema is:
-
when there's a defining annotation UID:
g_ag_id;uid
e.g.g_243;em_12_20035
-
when there's anchor IDs:
g_ag_id;startuid-enduid
e.g.g_243;n_72700-n_72709
-
when there's anchor offsets:
g_ag_id;startoffset-endoffset
e.g.g_243;39.400-46.279
-
when there's a participant/speaker number, it will be appended:
...;p_speakernumber
e.g.g_243;n_72700-n_72709;p_76
-
a target annotation by appending a uid prefixed by #=:
...;#=uid
e.g. g_243;n_72700-n_72709;#=ew_0_123 -
other items (search name or prefix) could then come after all that, and key=value pairs:
...;key=value
e.g.g_243;n_72700-n_72709;ew_0_123-ew_0_234;prefix=024-;name=the_aeiou
These can be something like:
g_3;em_11_23;n_19985-n_20003;p_4;#=ew_0_12611;prefix=001-;[0]=ew_0_12611
AgnesShacklock-01.trs;60.897-67.922;prefix=001-
AgnesShacklock-01.trs;60.897-67.922;m_-1_23-
- Author:
- Robert Fromont robert@fromont.net.nz
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGetter forattributes
: Other attributes in the MatchId.Getter forendAnchorId
: ID of the end anchor.Getter forendOffset
: Offset of the end anchor.Getter forprefix
: Match prefix for fragments.Getter forstartAnchorId
: ID of the start anchor.Getter forstartOffset
: Offset of the start anchor.Getter fortargetId
: ID of the match target annotation.Getter fortranscriptId
: The transcript identifier.Getter forutteranceId
: ID of the match utterance.Parses the given match ID string.
-
Constructor Details
-
MatchId
public MatchId()Default constructor. -
MatchId
String constructor.- Parameters:
matchId
- An composite ID that identifies the match.
-
MatchId
Constructor.- Parameters:
match
- An ID that identifies the match.
-
-
Method Details
-
getTranscriptId
Getter fortranscriptId
: The transcript identifier.- Returns:
- The transcript identifier.
-
getStartAnchorId
Getter forstartAnchorId
: ID of the start anchor.- Returns:
- ID of the start anchor.
-
getEndAnchorId
Getter forendAnchorId
: ID of the end anchor.- Returns:
- ID of the end anchor.
-
getStartOffset
Getter forstartOffset
: Offset of the start anchor.- Returns:
- Offset of the start anchor.
-
getEndOffset
Getter forendOffset
: Offset of the end anchor.- Returns:
- Offset of the end anchor.
-
getUtteranceId
Getter forutteranceId
: ID of the match utterance.- Returns:
- ID of the match utterance.
-
getTargetId
Getter fortargetId
: ID of the match target annotation.- Returns:
- ID of the match target annotation.
-
getPrefix
Getter forprefix
: Match prefix for fragments.- Returns:
- Match prefix for fragments.
-
getAttributes
Getter forattributes
: Other attributes in the MatchId.- Returns:
- Other attributes in the MatchId.
-
parseId
Parses the given match ID string.- Parameters:
matchId
- The composite string ID that identifies the match.- Returns:
- A reference to this object.
-