Package com.pdfgate

Class WatermarkPdfParams.Builder

java.lang.Object
com.pdfgate.WatermarkPdfParams.Builder
Enclosing class:
WatermarkPdfParams

public static final class WatermarkPdfParams.Builder extends Object
Builder for WatermarkPdfParams.
  • Method Details

    • documentId

      public WatermarkPdfParams.Builder documentId(String documentId)
      Sets the document id for the source PDF.
      Parameters:
      documentId - the document id for the source PDF.
      Returns:
      this builder.
    • watermark

      public WatermarkPdfParams.Builder watermark(FileParam watermark)
      Sets the watermark image file.
      Parameters:
      watermark - watermark image file.
      Returns:
      this builder.
    • type

      Sets the watermark type.
      Parameters:
      type - watermark type.
      Returns:
      this builder.
    • text

      public WatermarkPdfParams.Builder text(String text)
      Sets the watermark text.
      Parameters:
      text - watermark text.
      Returns:
      this builder.
    • font

      public WatermarkPdfParams.Builder font(String font)
      Sets the text watermark font.
      Parameters:
      font - text watermark font.
      Returns:
      this builder.
    • fontSize

      public WatermarkPdfParams.Builder fontSize(Integer fontSize)
      Sets the text watermark font size.
      Parameters:
      fontSize - text watermark font size.
      Returns:
      this builder.
    • fontColor

      public WatermarkPdfParams.Builder fontColor(String fontColor)
      Sets the text watermark font color.
      Parameters:
      fontColor - text watermark font color.
      Returns:
      this builder.
    • opacity

      public WatermarkPdfParams.Builder opacity(Double opacity)
      Sets the watermark opacity.
      Parameters:
      opacity - watermark opacity.
      Returns:
      this builder.
    • xPosition

      public WatermarkPdfParams.Builder xPosition(Integer xPosition)
      Sets the watermark horizontal position.
      Parameters:
      xPosition - watermark horizontal position.
      Returns:
      this builder.
    • yPosition

      public WatermarkPdfParams.Builder yPosition(Integer yPosition)
      Sets the watermark vertical position.
      Parameters:
      yPosition - watermark vertical position.
      Returns:
      this builder.
    • imageWidth

      public WatermarkPdfParams.Builder imageWidth(Integer imageWidth)
      Sets the watermark image width.
      Parameters:
      imageWidth - watermark image width.
      Returns:
      this builder.
    • imageHeight

      public WatermarkPdfParams.Builder imageHeight(Integer imageHeight)
      Sets the watermark image height.
      Parameters:
      imageHeight - watermark image height.
      Returns:
      this builder.
    • rotate

      public WatermarkPdfParams.Builder rotate(Double rotate)
      Sets the watermark rotation in degrees.
      Parameters:
      rotate - watermark rotation in degrees.
      Returns:
      this builder.
    • preSignedUrlExpiresIn

      public WatermarkPdfParams.Builder preSignedUrlExpiresIn(Long preSignedUrlExpiresIn)
      Sets the pre-signed URL expiration time in seconds.
      Parameters:
      preSignedUrlExpiresIn - expiration time in seconds.
      Returns:
      this builder.
    • metadata

      public WatermarkPdfParams.Builder metadata(Object metadata)
      Sets metadata to attach to the document.
      Parameters:
      metadata - metadata to attach to the document.
      Returns:
      this builder.
    • build

      public WatermarkPdfParams build()
      Builds watermark PDF parameters for JSON responses.
      Returns:
      parameters configured for JSON responses.