Class Anchor
java.lang.Object
com.pnfsoftware.jeb.core.output.text.impl.Anchor
- All Implemented Interfaces:
IAnchor
A simple implementation of an anchor.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionlong
Get the anchor identifier.int
Get the line index, within the document part, of the first line (the anchor line) of the anchored chunk.void
setIdentifier
(long id) void
setLineIndex
(int index) toString()
-
Constructor Details
-
Anchor
public Anchor(long id, int lineindex) Create an anchor.- Parameters:
id
- anchor identifier, positive or nulllineindex
- the index of the first line (relative to the document part this anchor belongs to)
-
-
Method Details
-
getIdentifier
public long getIdentifier()Description copied from interface:IAnchor
Get the anchor identifier. The identifier is a zero+ index number.- Specified by:
getIdentifier
in interfaceIAnchor
- Returns:
- the identifier
-
setIdentifier
public void setIdentifier(long id) -
getLineIndex
public int getLineIndex()Description copied from interface:IAnchor
Get the line index, within the document part, of the first line (the anchor line) of the anchored chunk.- Specified by:
getLineIndex
in interfaceIAnchor
- Returns:
- the identifier
-
setLineIndex
public void setLineIndex(int index) -
toString
-