@@ -9,6 +9,8 @@ import lombok.EqualsAndHashCode;
|
||||
@EqualsAndHashCode
|
||||
public class UrlToPdfRequest {
|
||||
|
||||
@Schema(description = "The input URL to be converted to a PDF file", required = true)
|
||||
@Schema(
|
||||
description = "The input URL to be converted to a PDF file",
|
||||
requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
private String urlInput;
|
||||
}
|
||||
|
||||
@@ -10,6 +10,6 @@ import stirling.software.SPDF.model.api.PDFWithPageNums;
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
public class ContainsTextRequest extends PDFWithPageNums {
|
||||
|
||||
@Schema(description = "The text to check for", required = true)
|
||||
@Schema(description = "The text to check for", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
private String text;
|
||||
}
|
||||
|
||||
@@ -10,6 +10,6 @@ import stirling.software.SPDF.model.api.PDFComparison;
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
public class FileSizeRequest extends PDFComparison {
|
||||
|
||||
@Schema(description = "File Size", required = true)
|
||||
@Schema(description = "File Size", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
private String fileSize;
|
||||
}
|
||||
|
||||
@@ -10,6 +10,6 @@ import stirling.software.SPDF.model.api.PDFComparison;
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
public class PageRotationRequest extends PDFComparison {
|
||||
|
||||
@Schema(description = "Rotation in degrees", required = true)
|
||||
@Schema(description = "Rotation in degrees", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
private int rotation;
|
||||
}
|
||||
|
||||
@@ -10,6 +10,6 @@ import stirling.software.SPDF.model.api.PDFComparison;
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
public class PageSizeRequest extends PDFComparison {
|
||||
|
||||
@Schema(description = "Standard Page Size", required = true)
|
||||
@Schema(description = "Standard Page Size", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
private String standardPageSize;
|
||||
}
|
||||
|
||||
@@ -20,13 +20,13 @@ public class OverlayPdfsRequest extends PDFFile {
|
||||
@Schema(
|
||||
description =
|
||||
"The mode of overlaying: 'SequentialOverlay' for sequential application, 'InterleavedOverlay' for round-robin application, 'FixedRepeatOverlay' for fixed repetition based on provided counts",
|
||||
required = true)
|
||||
requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
private String overlayMode;
|
||||
|
||||
@Schema(
|
||||
description =
|
||||
"An array of integers specifying the number of times each corresponding overlay file should be applied in the 'FixedRepeatOverlay' mode. This should match the length of the overlayFiles array.",
|
||||
required = false)
|
||||
requiredMode = Schema.RequiredMode.NOT_REQUIRED)
|
||||
private int[] counts;
|
||||
|
||||
@Schema(description = "Overlay position 0 is Foregound, 1 is Background")
|
||||
|
||||
@@ -13,14 +13,14 @@ public class SplitPdfBySizeOrCountRequest extends PDFFile {
|
||||
@Schema(
|
||||
description =
|
||||
"Determines the type of split: 0 for size, 1 for page count, 2 for document count",
|
||||
required = false,
|
||||
requiredMode = Schema.RequiredMode.NOT_REQUIRED,
|
||||
defaultValue = "0")
|
||||
private int splitType;
|
||||
|
||||
@Schema(
|
||||
description =
|
||||
"Value for split: size in MB (e.g., '10MB') or number of pages (e.g., '5')",
|
||||
required = false,
|
||||
requiredMode = Schema.RequiredMode.NOT_REQUIRED,
|
||||
defaultValue = "10MB")
|
||||
private String splitValue;
|
||||
}
|
||||
|
||||
@@ -15,7 +15,7 @@ public class AddStampRequest extends PDFWithPageNums {
|
||||
@Schema(
|
||||
description = "The stamp type (text or image)",
|
||||
allowableValues = {"text", "image"},
|
||||
required = true)
|
||||
requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
private String stampType;
|
||||
|
||||
@Schema(description = "The stamp text")
|
||||
|
||||
@@ -13,7 +13,7 @@ public class AutoSplitPdfRequest extends PDFFile {
|
||||
@Schema(
|
||||
description =
|
||||
"Flag indicating if the duplex mode is active, where the page after the divider also gets removed.",
|
||||
required = false,
|
||||
requiredMode = Schema.RequiredMode.NOT_REQUIRED,
|
||||
defaultValue = "false")
|
||||
private boolean duplexMode;
|
||||
}
|
||||
|
||||
@@ -13,7 +13,7 @@ public class ExtractHeaderRequest extends PDFFile {
|
||||
@Schema(
|
||||
description =
|
||||
"Flag indicating whether to use the first text as a fallback if no suitable title is found. Defaults to false.",
|
||||
required = false,
|
||||
requiredMode = Schema.RequiredMode.NOT_REQUIRED,
|
||||
defaultValue = "false")
|
||||
private boolean useFirstTextAsFallback;
|
||||
}
|
||||
|
||||
@@ -10,7 +10,9 @@ import lombok.EqualsAndHashCode;
|
||||
@Data
|
||||
@EqualsAndHashCode
|
||||
public class ExtractImageScansRequest {
|
||||
@Schema(description = "The input file containing image scans", required = true)
|
||||
@Schema(
|
||||
description = "The input file containing image scans",
|
||||
requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
private MultipartFile fileInput;
|
||||
|
||||
@Schema(
|
||||
|
||||
@@ -10,6 +10,8 @@ import stirling.software.SPDF.model.api.PDFFile;
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
public class PrintFileRequest extends PDFFile {
|
||||
|
||||
@Schema(description = "Name of printer to match against", required = true)
|
||||
@Schema(
|
||||
description = "Name of printer to match against",
|
||||
requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
private String printerName;
|
||||
}
|
||||
|
||||
@@ -15,7 +15,7 @@ public class AddWatermarkRequest extends PDFFile {
|
||||
@Schema(
|
||||
description = "The watermark type (text or image)",
|
||||
allowableValues = {"text", "image"},
|
||||
required = true)
|
||||
requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
private String watermarkType;
|
||||
|
||||
@Schema(description = "The watermark text")
|
||||
|
||||
@@ -10,6 +10,8 @@ import stirling.software.SPDF.model.api.PDFFile;
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
public class PDFPasswordRequest extends PDFFile {
|
||||
|
||||
@Schema(description = "The password of the PDF file", required = true)
|
||||
@Schema(
|
||||
description = "The password of the PDF file",
|
||||
requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
private String password;
|
||||
}
|
||||
|
||||
@@ -10,7 +10,10 @@ import stirling.software.SPDF.model.api.PDFFile;
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
public class RedactPdfRequest extends PDFFile {
|
||||
|
||||
@Schema(description = "List of text to redact from the PDF", type = "string", required = true)
|
||||
@Schema(
|
||||
description = "List of text to redact from the PDF",
|
||||
type = "string",
|
||||
requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
private String listOfText;
|
||||
|
||||
@Schema(description = "Whether to use regex for the listOfText", defaultValue = "false")
|
||||
|
||||
Reference in New Issue
Block a user