Package net.webpdf.wsclient.openapi
Class OperationWatermarkPosition
- java.lang.Object
-
- net.webpdf.wsclient.openapi.OperationWatermarkPosition
-
public class OperationWatermarkPosition extends Object
Used to set the position of the watermark in the PDF document.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classOperationWatermarkPosition.MetricsEnumUnit for the X-axis/Y-axis position and signature field height and width arguments: * pt = Points(1/72 inch) * pc = Picas(12 points) * px = Pixels(1/96 inch) * mm = Millimeters * in = Inchesstatic classOperationWatermarkPosition.PositionEnumUses one of multiple preset positions in order to position the watermark on the page
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_PROPERTY_ASPECT_RATIOstatic StringJSON_PROPERTY_HEIGHTstatic StringJSON_PROPERTY_METRICSstatic StringJSON_PROPERTY_POSITIONstatic StringJSON_PROPERTY_WIDTHstatic StringJSON_PROPERTY_Xstatic StringJSON_PROPERTY_Y
-
Constructor Summary
Constructors Constructor Description OperationWatermarkPosition()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description OperationWatermarkPositionaspectRatio(Boolean aspectRatio)booleanequals(Object o)@Nullable BooleangetAspectRatio()Forces the aspect ratio to be maintained when a watermark is scaled if \"width\" and \"height\" are specified.@Nullable IntegergetHeight()Forces the specified height for the watermark if the values are not equal 0.@Nullable OperationWatermarkPosition.MetricsEnumgetMetrics()Unit for the X-axis/Y-axis position and signature field height and width arguments: * pt = Points(1/72 inch) * pc = Picas(12 points) * px = Pixels(1/96 inch) * mm = Millimeters * in = Inches@Nullable OperationWatermarkPosition.PositionEnumgetPosition()Uses one of multiple preset positions in order to position the watermark on the page@Nullable IntegergetWidth()Forces the specified width for the watermark if the values are not equal 0.@Nullable IntegergetX()Used to define the X-axis position (as per metrics), starting from the top left corner of the PDF document, if position is set to \"custom@Nullable IntegergetY()Used to define the Y-axis position (as per metrics), starting from the top left corner of the PDF document, if position is set to \"custominthashCode()OperationWatermarkPositionheight(Integer height)OperationWatermarkPositionmetrics(OperationWatermarkPosition.MetricsEnum metrics)OperationWatermarkPositionposition(OperationWatermarkPosition.PositionEnum position)voidsetAspectRatio(Boolean aspectRatio)voidsetHeight(Integer height)voidsetMetrics(OperationWatermarkPosition.MetricsEnum metrics)voidsetPosition(OperationWatermarkPosition.PositionEnum position)voidsetWidth(Integer width)voidsetX(Integer x)voidsetY(Integer y)StringtoString()OperationWatermarkPositionwidth(Integer width)OperationWatermarkPositionx(Integer x)OperationWatermarkPositiony(Integer y)
-
-
-
Field Detail
-
JSON_PROPERTY_ASPECT_RATIO
public static final String JSON_PROPERTY_ASPECT_RATIO
- See Also:
- Constant Field Values
-
JSON_PROPERTY_HEIGHT
public static final String JSON_PROPERTY_HEIGHT
- See Also:
- Constant Field Values
-
JSON_PROPERTY_METRICS
public static final String JSON_PROPERTY_METRICS
- See Also:
- Constant Field Values
-
JSON_PROPERTY_POSITION
public static final String JSON_PROPERTY_POSITION
- See Also:
- Constant Field Values
-
JSON_PROPERTY_WIDTH
public static final String JSON_PROPERTY_WIDTH
- See Also:
- Constant Field Values
-
JSON_PROPERTY_X
public static final String JSON_PROPERTY_X
- See Also:
- Constant Field Values
-
JSON_PROPERTY_Y
public static final String JSON_PROPERTY_Y
- See Also:
- Constant Field Values
-
-
Method Detail
-
aspectRatio
public OperationWatermarkPosition aspectRatio(Boolean aspectRatio)
-
getAspectRatio
@Nullable public @Nullable Boolean getAspectRatio()
Forces the aspect ratio to be maintained when a watermark is scaled if \"width\" and \"height\" are specified.- Returns:
- aspectRatio
-
setAspectRatio
public void setAspectRatio(Boolean aspectRatio)
-
height
public OperationWatermarkPosition height(Integer height)
-
getHeight
@Nullable public @Nullable Integer getHeight()
Forces the specified height for the watermark if the values are not equal 0. In this case, the watermark will be scaled inside the area, which may result in the image losing quality or being distorted (please refer to \"aspectRatio\" as well) minimum: 0- Returns:
- height
-
setHeight
public void setHeight(Integer height)
-
metrics
public OperationWatermarkPosition metrics(OperationWatermarkPosition.MetricsEnum metrics)
-
getMetrics
@Nullable public @Nullable OperationWatermarkPosition.MetricsEnum getMetrics()
Unit for the X-axis/Y-axis position and signature field height and width arguments: * pt = Points(1/72 inch) * pc = Picas(12 points) * px = Pixels(1/96 inch) * mm = Millimeters * in = Inches- Returns:
- metrics
-
setMetrics
public void setMetrics(OperationWatermarkPosition.MetricsEnum metrics)
-
position
public OperationWatermarkPosition position(OperationWatermarkPosition.PositionEnum position)
-
getPosition
@Nullable public @Nullable OperationWatermarkPosition.PositionEnum getPosition()
Uses one of multiple preset positions in order to position the watermark on the page. * custom = Disable the use of a preset position. * top\\_left = Positions the watermark in the upper left corner. * top\\_center = Positions the watermark in the centre at the top margin. * top\\_right = Positions the watermark in the top right corner. * center\\_left = Positions the watermark at the centre of the page, to the left. * center\\_center = Positions the watermark at the centre of the page. * center\\_right = Positions the watermark at the centre of the page, to the right. * bottom\\_left = Positions the watermark in the bottom left corner. * bottom\\_center = Positions the watermark in the centre at the bottom margin. * bottom\\_right = Positions the watermark in the bottom right corner.- Returns:
- position
-
setPosition
public void setPosition(OperationWatermarkPosition.PositionEnum position)
-
width
public OperationWatermarkPosition width(Integer width)
-
getWidth
@Nullable public @Nullable Integer getWidth()
Forces the specified width for the watermark if the values are not equal 0. In this case, the watermark will be scaled inside the area, which may result in the image losing quality or being distorted (please refer to \"aspectRatio\" as well) minimum: 0- Returns:
- width
-
setWidth
public void setWidth(Integer width)
-
x
public OperationWatermarkPosition x(Integer x)
-
getX
@Nullable public @Nullable Integer getX()
Used to define the X-axis position (as per metrics), starting from the top left corner of the PDF document, if position is set to \"custom.\". If \"position is set to a different value, these arguments will be interpreted as \"offsets\" from the selected position. This specification applies for both the text and image output. minimum: 0- Returns:
- x
-
setX
public void setX(Integer x)
-
y
public OperationWatermarkPosition y(Integer y)
-
getY
@Nullable public @Nullable Integer getY()
Used to define the Y-axis position (as per metrics), starting from the top left corner of the PDF document, if position is set to \"custom.\". If \"position is set to a different value, these arguments will be interpreted as \"offsets\" from the selected position. This specification applies for both the text and image output. minimum: 0- Returns:
- y
-
setY
public void setY(Integer y)
-
-