Class PosTableLookup8Format3.PosRuleFormat3
- java.lang.Object
-
- com.itextpdf.io.font.otf.ContextualRule
-
- com.itextpdf.io.font.otf.ContextualPositionRule
-
- com.itextpdf.io.font.otf.lookuptype8.PosTableLookup8Format3.PosRuleFormat3
-
- Enclosing class:
- PosTableLookup8Format3
public static class PosTableLookup8Format3.PosRuleFormat3 extends ContextualPositionRule
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.List<java.util.Set<java.lang.Integer>>
backtrackCoverages
private java.util.List<java.util.Set<java.lang.Integer>>
inputCoverages
private java.util.List<java.util.Set<java.lang.Integer>>
lookaheadCoverages
private PosLookupRecord[]
posLookupRecords
-
Constructor Summary
Constructors Constructor Description PosRuleFormat3(java.util.List<java.util.Set<java.lang.Integer>> backtrackCoverages, java.util.List<java.util.Set<java.lang.Integer>> inputCoverages, java.util.List<java.util.Set<java.lang.Integer>> lookaheadCoverages, PosLookupRecord[] posLookupRecords)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getBacktrackContextLength()
Gets the length of the backtrack context glyph sequence defined by this ruleint
getContextLength()
Gets the length of the context glyph sequence defined by this rulejava.util.Set<java.lang.Integer>
getInputCoverage(int idx)
int
getLookaheadContextLength()
Gets the length of the lookahead context glyph sequence defined by this rulePosLookupRecord[]
getPosLookupRecords()
Retrieves the position lookup records.boolean
isGlyphMatchesBacktrack(int glyphId, int atIdx)
Checks if glyph line element matches element from backtrack sequence of the rule.boolean
isGlyphMatchesInput(int glyphId, int atIdx)
Checks if glyph line element matches element from input sequence of the rule.boolean
isGlyphMatchesLookahead(int glyphId, int atIdx)
Checks if glyph line element matches element from lookahead sequence of the rule.
-
-
-
Field Detail
-
inputCoverages
private java.util.List<java.util.Set<java.lang.Integer>> inputCoverages
-
backtrackCoverages
private java.util.List<java.util.Set<java.lang.Integer>> backtrackCoverages
-
lookaheadCoverages
private java.util.List<java.util.Set<java.lang.Integer>> lookaheadCoverages
-
posLookupRecords
private PosLookupRecord[] posLookupRecords
-
-
Constructor Detail
-
PosRuleFormat3
public PosRuleFormat3(java.util.List<java.util.Set<java.lang.Integer>> backtrackCoverages, java.util.List<java.util.Set<java.lang.Integer>> inputCoverages, java.util.List<java.util.Set<java.lang.Integer>> lookaheadCoverages, PosLookupRecord[] posLookupRecords)
-
-
Method Detail
-
getPosLookupRecords
public PosLookupRecord[] getPosLookupRecords()
Description copied from class:ContextualPositionRule
Retrieves the position lookup records. Each record specifies a position in the context glyph sequence and a LookupListIndex to the position lookup that is applied at that position.- Specified by:
getPosLookupRecords
in classContextualPositionRule
- Returns:
- an array of
PosLookupRecord
.
-
getContextLength
public int getContextLength()
Description copied from class:ContextualRule
Gets the length of the context glyph sequence defined by this rule- Specified by:
getContextLength
in classContextualRule
- Returns:
- length of the context
-
getInputCoverage
public java.util.Set<java.lang.Integer> getInputCoverage(int idx)
-
isGlyphMatchesInput
public boolean isGlyphMatchesInput(int glyphId, int atIdx)
Description copied from class:ContextualRule
Checks if glyph line element matches element from input sequence of the rule.
NOTE: rules do not contain the first element of the input sequence, the first element is defined by rule position in substitution table. Therefore atIdx shall not be 0.- Specified by:
isGlyphMatchesInput
in classContextualRule
- Parameters:
glyphId
- glyph code idatIdx
- index in the rule sequence. Shall be: 0 < atIdx <ContextualRule.getContextLength()
- Returns:
true
if glyph matches element
-
getLookaheadContextLength
public int getLookaheadContextLength()
Description copied from class:ContextualRule
Gets the length of the lookahead context glyph sequence defined by this rule- Overrides:
getLookaheadContextLength
in classContextualRule
- Returns:
- length of the lookahead context
-
isGlyphMatchesLookahead
public boolean isGlyphMatchesLookahead(int glyphId, int atIdx)
Description copied from class:ContextualRule
Checks if glyph line element matches element from lookahead sequence of the rule.- Overrides:
isGlyphMatchesLookahead
in classContextualRule
- Parameters:
glyphId
- glyph code idatIdx
- index in rule sequence. Shall be: 0 <= atIdx <ContextualRule.getLookaheadContextLength()
- Returns:
true
if glyph matches element from lookahead sequence
-
getBacktrackContextLength
public int getBacktrackContextLength()
Description copied from class:ContextualRule
Gets the length of the backtrack context glyph sequence defined by this rule- Overrides:
getBacktrackContextLength
in classContextualRule
- Returns:
- length of the backtrack context
-
isGlyphMatchesBacktrack
public boolean isGlyphMatchesBacktrack(int glyphId, int atIdx)
Description copied from class:ContextualRule
Checks if glyph line element matches element from backtrack sequence of the rule.- Overrides:
isGlyphMatchesBacktrack
in classContextualRule
- Parameters:
glyphId
- glyph code idatIdx
- index in rule sequence. Shall be: 0 <= atIdx <ContextualRule.getBacktrackContextLength()
- Returns:
true
if glyph matches element from backtrack sequence
-
-