Class Annotation
java.lang.Object
com.saperion.ngc.viewer.hylandviewer.annotation.json.Annotation
- Direct Known Subclasses:
LineAnnotation,RectangleAnnotation,Redaction,TextAnnotation
Contains configuration of annotation
- Author:
- schowdhury
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected StringId of the annotationprotected com.saperion.hyrcs.models.DocDimensionDimension of the document.protected booleanTo check whether the document is opened in edit mode or notprotected booleanToggle to show fill colorprotected StringFill color of the annotationprotected booleanToggle to fix annotation rotation (Annotation does not rotate with the page it belongs to).protected doubleHeight of the annotationprotected booleanAnnotation is movableprotected doubleOpacity of the annotationprotected StringId of the content item the annotation belongs toprotected booleanAnnotation is resizableprotected StrokeStroke info of the annotationprotected doubleWidth of the annotationprotected doubleX position of the annotationprotected doubleY position of the annotation -
Constructor Summary
ConstructorsConstructorDescriptionAnnotation(com.saperion.hyrcs.models.DocDimension docDimension, boolean editMode) -
Method Summary
Modifier and TypeMethodDescriptionabstract voidThis is an abstract method for filling up the annotation configuration by different types of annotations subclassesgetAnnId()doubledoubleabstract AnnotationTypegetType()doublegetWidth()doublegetX()doublegetY()booleanbooleanbooleanbooleanprotected doublenormalizeX(int x) The CoreServer delivers all coordinates for a normalized document sized 10000px x 10000px.protected doublenormalizeY(int y) voidvoid
-
Field Details
-
annId
Id of the annotation -
pageNo
Id of the content item the annotation belongs to -
x
protected double xX position of the annotation -
y
protected double yY position of the annotation -
width
protected double widthWidth of the annotation -
height
protected double heightHeight of the annotation -
fillColor
Fill color of the annotation -
fillable
protected boolean fillableToggle to show fill color -
fixRotation
protected boolean fixRotationToggle to fix annotation rotation (Annotation does not rotate with the page it belongs to). -
resizable
protected boolean resizableAnnotation is resizable -
movable
protected boolean movableAnnotation is movable -
opacity
protected double opacityOpacity of the annotation -
stroke
Stroke info of the annotation -
docDimension
protected com.saperion.hyrcs.models.DocDimension docDimensionDimension of the document. It will not be serialized. -
editMode
protected boolean editModeTo check whether the document is opened in edit mode or not
-
-
Constructor Details
-
Annotation
public Annotation() -
Annotation
public Annotation(com.saperion.hyrcs.models.DocDimension docDimension, boolean editMode)
-
-
Method Details
-
getAnnId
-
setAnnId
-
getPageNo
-
setPageNo
-
getX
public double getX() -
getY
public double getY() -
getWidth
public double getWidth() -
getHeight
public double getHeight() -
getFillColor
-
isFillable
public boolean isFillable() -
isFixRotation
public boolean isFixRotation() -
isResizable
public boolean isResizable() -
isMovable
public boolean isMovable() -
getOpacity
public double getOpacity() -
getStroke
-
normalizeX
protected double normalizeX(int x) The CoreServer delivers all coordinates for a normalized document sized 10000px x 10000px. So we have to calculate the real coordinates here. -
normalizeY
protected double normalizeY(int y) -
getType
-
draw
This is an abstract method for filling up the annotation configuration by different types of annotations subclasses- Parameters:
section- contains information about an annotation (e.g. - annotation type and key value pairs)
-