Package net.sf.okapi.common.filters
Class CodeTypeForPairedTagsHelper
- java.lang.Object
-
- net.sf.okapi.common.filters.CodeTypeForPairedTagsHelper
-
public class CodeTypeForPairedTagsHelper extends Object
Helper class that manages ctype attributes for paired tags (<bx>,<ex>,<bpt>,<ept>). The tags use either theiridorridattribute for linking the other tag. The value of theridattribute should be preferred if present.- Since:
- 26.01.2017
- Author:
- ccudennec
-
-
Field Summary
Fields Modifier and Type Field Description static StringDEFAULT_CODE_TYPE
-
Constructor Summary
Constructors Constructor Description CodeTypeForPairedTagsHelper()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Stringfind(String rid, String id)Stringstore(String rid, String id, String ctype)Stores the givenctypeorDEFAULT_CODE_TYPEunder the given rid or id.
-
-
-
Field Detail
-
DEFAULT_CODE_TYPE
public static final String DEFAULT_CODE_TYPE
- See Also:
- Constant Field Values
-
-
Method Detail
-
store
public String store(String rid, String id, String ctype)
Stores the givenctypeorDEFAULT_CODE_TYPEunder the given rid or id.- Returns:
- the ctype or
DEFAULT_CODE_TYPE
-
find
public String find(String rid, String id)
- Returns:
- the code type stored under the given rid (or id) or
DEFAULT_CODE_TYPE
-
-