All Downloads are FREE. Search and download functionalities are using the official Maven repository.

software.amazon.textract.idp.DocumentSplitterProps Maven / Gradle / Ivy

There is a newer version: 0.0.43
Show newest version
package software.amazon.textract.idp;

/**
 */
@javax.annotation.Generated(value = "jsii-pacmak/1.90.0 (build d6bdb4d)", date = "2023-10-26T15:43:30.313Z")
@software.amazon.jsii.Jsii(module = software.amazon.textract.idp.$Module.class, fqn = "amazon-textract-idp-cdk-constructs.DocumentSplitterProps")
@software.amazon.jsii.Jsii.Proxy(DocumentSplitterProps.Jsii$Proxy.class)
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public interface DocumentSplitterProps extends software.amazon.jsii.JsiiSerializable {

    /**
     * Bucketname to output data to.
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
    @org.jetbrains.annotations.NotNull java.lang.String getS3OutputBucket();

    /**
     * The prefix to use to output files to.
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
    @org.jetbrains.annotations.NotNull java.lang.String getS3OutputPrefix();

    /**
     * List of PolicyStatements to attach to the Lambda function.
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
    default @org.jetbrains.annotations.Nullable java.util.List getInputPolicyStatements() {
        return null;
    }

    /**
     * Lambda log level.
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
    default @org.jetbrains.annotations.Nullable java.lang.String getLambdaLogLevel() {
        return null;
    }

    /**
     * Lambda function memory configuration (may need to increase for larger documents).
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
    default @org.jetbrains.annotations.Nullable java.lang.Number getLambdaMemoryMB() {
        return null;
    }

    /**
     * Lambda function timeout (may need to increase for larger documents).
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
    default @org.jetbrains.annotations.Nullable java.lang.Number getLambdaTimeout() {
        return null;
    }

    /**
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
    default @org.jetbrains.annotations.Nullable java.lang.Number getMaxNumberOfPagesPerDoc() {
        return null;
    }

    /**
     * List of PolicyStatements to attach to the Lambda function.
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
    default @org.jetbrains.annotations.Nullable java.util.List getOutputPolicyStatements() {
        return null;
    }

    /**
     * location of input S3 objects - if left empty will generate rule for s3 access to all [*].
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
    default @org.jetbrains.annotations.Nullable java.lang.String getS3InputBucket() {
        return null;
    }

    /**
     * prefix for input S3 objects - if left empty will generate rule for s3 access to all in bucket.
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
    default @org.jetbrains.annotations.Nullable java.lang.String getS3InputPrefix() {
        return null;
    }

    /**
     * retyr backoff rate.
     * 

* Default: is 1.1 */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.lang.Number getTextractDocumentSplitterBackoffRate() { return null; } /** */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.lang.Number getTextractDocumentSplitterInterval() { return null; } /** * number of retries in Step Function flow. *

* Default: is 100 */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.lang.Number getTextractDocumentSplitterMaxRetries() { return null; } /** * @return a {@link Builder} of {@link DocumentSplitterProps} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) static Builder builder() { return new Builder(); } /** * A builder for {@link DocumentSplitterProps} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public static final class Builder implements software.amazon.jsii.Builder { java.lang.String s3OutputBucket; java.lang.String s3OutputPrefix; java.util.List inputPolicyStatements; java.lang.String lambdaLogLevel; java.lang.Number lambdaMemoryMb; java.lang.Number lambdaTimeout; java.lang.Number maxNumberOfPagesPerDoc; java.util.List outputPolicyStatements; java.lang.String s3InputBucket; java.lang.String s3InputPrefix; java.lang.Number textractDocumentSplitterBackoffRate; java.lang.Number textractDocumentSplitterInterval; java.lang.Number textractDocumentSplitterMaxRetries; /** * Sets the value of {@link DocumentSplitterProps#getS3OutputBucket} * @param s3OutputBucket Bucketname to output data to. This parameter is required. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder s3OutputBucket(java.lang.String s3OutputBucket) { this.s3OutputBucket = s3OutputBucket; return this; } /** * Sets the value of {@link DocumentSplitterProps#getS3OutputPrefix} * @param s3OutputPrefix The prefix to use to output files to. This parameter is required. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder s3OutputPrefix(java.lang.String s3OutputPrefix) { this.s3OutputPrefix = s3OutputPrefix; return this; } /** * Sets the value of {@link DocumentSplitterProps#getInputPolicyStatements} * @param inputPolicyStatements List of PolicyStatements to attach to the Lambda function. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @SuppressWarnings("unchecked") public Builder inputPolicyStatements(java.util.List inputPolicyStatements) { this.inputPolicyStatements = (java.util.List)inputPolicyStatements; return this; } /** * Sets the value of {@link DocumentSplitterProps#getLambdaLogLevel} * @param lambdaLogLevel Lambda log level. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder lambdaLogLevel(java.lang.String lambdaLogLevel) { this.lambdaLogLevel = lambdaLogLevel; return this; } /** * Sets the value of {@link DocumentSplitterProps#getLambdaMemoryMb} * @param lambdaMemoryMb Lambda function memory configuration (may need to increase for larger documents). * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder lambdaMemoryMb(java.lang.Number lambdaMemoryMb) { this.lambdaMemoryMb = lambdaMemoryMb; return this; } /** * Sets the value of {@link DocumentSplitterProps#getLambdaTimeout} * @param lambdaTimeout Lambda function timeout (may need to increase for larger documents). * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder lambdaTimeout(java.lang.Number lambdaTimeout) { this.lambdaTimeout = lambdaTimeout; return this; } /** * Sets the value of {@link DocumentSplitterProps#getMaxNumberOfPagesPerDoc} * @param maxNumberOfPagesPerDoc the value to be set. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder maxNumberOfPagesPerDoc(java.lang.Number maxNumberOfPagesPerDoc) { this.maxNumberOfPagesPerDoc = maxNumberOfPagesPerDoc; return this; } /** * Sets the value of {@link DocumentSplitterProps#getOutputPolicyStatements} * @param outputPolicyStatements List of PolicyStatements to attach to the Lambda function. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @SuppressWarnings("unchecked") public Builder outputPolicyStatements(java.util.List outputPolicyStatements) { this.outputPolicyStatements = (java.util.List)outputPolicyStatements; return this; } /** * Sets the value of {@link DocumentSplitterProps#getS3InputBucket} * @param s3InputBucket location of input S3 objects - if left empty will generate rule for s3 access to all [*]. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder s3InputBucket(java.lang.String s3InputBucket) { this.s3InputBucket = s3InputBucket; return this; } /** * Sets the value of {@link DocumentSplitterProps#getS3InputPrefix} * @param s3InputPrefix prefix for input S3 objects - if left empty will generate rule for s3 access to all in bucket. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder s3InputPrefix(java.lang.String s3InputPrefix) { this.s3InputPrefix = s3InputPrefix; return this; } /** * Sets the value of {@link DocumentSplitterProps#getTextractDocumentSplitterBackoffRate} * @param textractDocumentSplitterBackoffRate retyr backoff rate. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder textractDocumentSplitterBackoffRate(java.lang.Number textractDocumentSplitterBackoffRate) { this.textractDocumentSplitterBackoffRate = textractDocumentSplitterBackoffRate; return this; } /** * Sets the value of {@link DocumentSplitterProps#getTextractDocumentSplitterInterval} * @param textractDocumentSplitterInterval the value to be set. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder textractDocumentSplitterInterval(java.lang.Number textractDocumentSplitterInterval) { this.textractDocumentSplitterInterval = textractDocumentSplitterInterval; return this; } /** * Sets the value of {@link DocumentSplitterProps#getTextractDocumentSplitterMaxRetries} * @param textractDocumentSplitterMaxRetries number of retries in Step Function flow. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder textractDocumentSplitterMaxRetries(java.lang.Number textractDocumentSplitterMaxRetries) { this.textractDocumentSplitterMaxRetries = textractDocumentSplitterMaxRetries; return this; } /** * Builds the configured instance. * @return a new instance of {@link DocumentSplitterProps} * @throws NullPointerException if any required attribute was not provided */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @Override public DocumentSplitterProps build() { return new Jsii$Proxy(this); } } /** * An implementation for {@link DocumentSplitterProps} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @software.amazon.jsii.Internal final class Jsii$Proxy extends software.amazon.jsii.JsiiObject implements DocumentSplitterProps { private final java.lang.String s3OutputBucket; private final java.lang.String s3OutputPrefix; private final java.util.List inputPolicyStatements; private final java.lang.String lambdaLogLevel; private final java.lang.Number lambdaMemoryMb; private final java.lang.Number lambdaTimeout; private final java.lang.Number maxNumberOfPagesPerDoc; private final java.util.List outputPolicyStatements; private final java.lang.String s3InputBucket; private final java.lang.String s3InputPrefix; private final java.lang.Number textractDocumentSplitterBackoffRate; private final java.lang.Number textractDocumentSplitterInterval; private final java.lang.Number textractDocumentSplitterMaxRetries; /** * Constructor that initializes the object based on values retrieved from the JsiiObject. * @param objRef Reference to the JSII managed object. */ protected Jsii$Proxy(final software.amazon.jsii.JsiiObjectRef objRef) { super(objRef); this.s3OutputBucket = software.amazon.jsii.Kernel.get(this, "s3OutputBucket", software.amazon.jsii.NativeType.forClass(java.lang.String.class)); this.s3OutputPrefix = software.amazon.jsii.Kernel.get(this, "s3OutputPrefix", software.amazon.jsii.NativeType.forClass(java.lang.String.class)); this.inputPolicyStatements = software.amazon.jsii.Kernel.get(this, "inputPolicyStatements", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.iam.PolicyStatement.class))); this.lambdaLogLevel = software.amazon.jsii.Kernel.get(this, "lambdaLogLevel", software.amazon.jsii.NativeType.forClass(java.lang.String.class)); this.lambdaMemoryMb = software.amazon.jsii.Kernel.get(this, "lambdaMemoryMB", software.amazon.jsii.NativeType.forClass(java.lang.Number.class)); this.lambdaTimeout = software.amazon.jsii.Kernel.get(this, "lambdaTimeout", software.amazon.jsii.NativeType.forClass(java.lang.Number.class)); this.maxNumberOfPagesPerDoc = software.amazon.jsii.Kernel.get(this, "maxNumberOfPagesPerDoc", software.amazon.jsii.NativeType.forClass(java.lang.Number.class)); this.outputPolicyStatements = software.amazon.jsii.Kernel.get(this, "outputPolicyStatements", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.iam.PolicyStatement.class))); this.s3InputBucket = software.amazon.jsii.Kernel.get(this, "s3InputBucket", software.amazon.jsii.NativeType.forClass(java.lang.String.class)); this.s3InputPrefix = software.amazon.jsii.Kernel.get(this, "s3InputPrefix", software.amazon.jsii.NativeType.forClass(java.lang.String.class)); this.textractDocumentSplitterBackoffRate = software.amazon.jsii.Kernel.get(this, "textractDocumentSplitterBackoffRate", software.amazon.jsii.NativeType.forClass(java.lang.Number.class)); this.textractDocumentSplitterInterval = software.amazon.jsii.Kernel.get(this, "textractDocumentSplitterInterval", software.amazon.jsii.NativeType.forClass(java.lang.Number.class)); this.textractDocumentSplitterMaxRetries = software.amazon.jsii.Kernel.get(this, "textractDocumentSplitterMaxRetries", software.amazon.jsii.NativeType.forClass(java.lang.Number.class)); } /** * Constructor that initializes the object based on literal property values passed by the {@link Builder}. */ @SuppressWarnings("unchecked") protected Jsii$Proxy(final Builder builder) { super(software.amazon.jsii.JsiiObject.InitializationMode.JSII); this.s3OutputBucket = java.util.Objects.requireNonNull(builder.s3OutputBucket, "s3OutputBucket is required"); this.s3OutputPrefix = java.util.Objects.requireNonNull(builder.s3OutputPrefix, "s3OutputPrefix is required"); this.inputPolicyStatements = (java.util.List)builder.inputPolicyStatements; this.lambdaLogLevel = builder.lambdaLogLevel; this.lambdaMemoryMb = builder.lambdaMemoryMb; this.lambdaTimeout = builder.lambdaTimeout; this.maxNumberOfPagesPerDoc = builder.maxNumberOfPagesPerDoc; this.outputPolicyStatements = (java.util.List)builder.outputPolicyStatements; this.s3InputBucket = builder.s3InputBucket; this.s3InputPrefix = builder.s3InputPrefix; this.textractDocumentSplitterBackoffRate = builder.textractDocumentSplitterBackoffRate; this.textractDocumentSplitterInterval = builder.textractDocumentSplitterInterval; this.textractDocumentSplitterMaxRetries = builder.textractDocumentSplitterMaxRetries; } @Override public final java.lang.String getS3OutputBucket() { return this.s3OutputBucket; } @Override public final java.lang.String getS3OutputPrefix() { return this.s3OutputPrefix; } @Override public final java.util.List getInputPolicyStatements() { return this.inputPolicyStatements; } @Override public final java.lang.String getLambdaLogLevel() { return this.lambdaLogLevel; } @Override public final java.lang.Number getLambdaMemoryMB() { return this.lambdaMemoryMb; } @Override public final java.lang.Number getLambdaTimeout() { return this.lambdaTimeout; } @Override public final java.lang.Number getMaxNumberOfPagesPerDoc() { return this.maxNumberOfPagesPerDoc; } @Override public final java.util.List getOutputPolicyStatements() { return this.outputPolicyStatements; } @Override public final java.lang.String getS3InputBucket() { return this.s3InputBucket; } @Override public final java.lang.String getS3InputPrefix() { return this.s3InputPrefix; } @Override public final java.lang.Number getTextractDocumentSplitterBackoffRate() { return this.textractDocumentSplitterBackoffRate; } @Override public final java.lang.Number getTextractDocumentSplitterInterval() { return this.textractDocumentSplitterInterval; } @Override public final java.lang.Number getTextractDocumentSplitterMaxRetries() { return this.textractDocumentSplitterMaxRetries; } @Override @software.amazon.jsii.Internal public com.fasterxml.jackson.databind.JsonNode $jsii$toJson() { final com.fasterxml.jackson.databind.ObjectMapper om = software.amazon.jsii.JsiiObjectMapper.INSTANCE; final com.fasterxml.jackson.databind.node.ObjectNode data = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode(); data.set("s3OutputBucket", om.valueToTree(this.getS3OutputBucket())); data.set("s3OutputPrefix", om.valueToTree(this.getS3OutputPrefix())); if (this.getInputPolicyStatements() != null) { data.set("inputPolicyStatements", om.valueToTree(this.getInputPolicyStatements())); } if (this.getLambdaLogLevel() != null) { data.set("lambdaLogLevel", om.valueToTree(this.getLambdaLogLevel())); } if (this.getLambdaMemoryMB() != null) { data.set("lambdaMemoryMB", om.valueToTree(this.getLambdaMemoryMB())); } if (this.getLambdaTimeout() != null) { data.set("lambdaTimeout", om.valueToTree(this.getLambdaTimeout())); } if (this.getMaxNumberOfPagesPerDoc() != null) { data.set("maxNumberOfPagesPerDoc", om.valueToTree(this.getMaxNumberOfPagesPerDoc())); } if (this.getOutputPolicyStatements() != null) { data.set("outputPolicyStatements", om.valueToTree(this.getOutputPolicyStatements())); } if (this.getS3InputBucket() != null) { data.set("s3InputBucket", om.valueToTree(this.getS3InputBucket())); } if (this.getS3InputPrefix() != null) { data.set("s3InputPrefix", om.valueToTree(this.getS3InputPrefix())); } if (this.getTextractDocumentSplitterBackoffRate() != null) { data.set("textractDocumentSplitterBackoffRate", om.valueToTree(this.getTextractDocumentSplitterBackoffRate())); } if (this.getTextractDocumentSplitterInterval() != null) { data.set("textractDocumentSplitterInterval", om.valueToTree(this.getTextractDocumentSplitterInterval())); } if (this.getTextractDocumentSplitterMaxRetries() != null) { data.set("textractDocumentSplitterMaxRetries", om.valueToTree(this.getTextractDocumentSplitterMaxRetries())); } final com.fasterxml.jackson.databind.node.ObjectNode struct = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode(); struct.set("fqn", om.valueToTree("amazon-textract-idp-cdk-constructs.DocumentSplitterProps")); struct.set("data", data); final com.fasterxml.jackson.databind.node.ObjectNode obj = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode(); obj.set("$jsii.struct", struct); return obj; } @Override public final boolean equals(final Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; DocumentSplitterProps.Jsii$Proxy that = (DocumentSplitterProps.Jsii$Proxy) o; if (!s3OutputBucket.equals(that.s3OutputBucket)) return false; if (!s3OutputPrefix.equals(that.s3OutputPrefix)) return false; if (this.inputPolicyStatements != null ? !this.inputPolicyStatements.equals(that.inputPolicyStatements) : that.inputPolicyStatements != null) return false; if (this.lambdaLogLevel != null ? !this.lambdaLogLevel.equals(that.lambdaLogLevel) : that.lambdaLogLevel != null) return false; if (this.lambdaMemoryMb != null ? !this.lambdaMemoryMb.equals(that.lambdaMemoryMb) : that.lambdaMemoryMb != null) return false; if (this.lambdaTimeout != null ? !this.lambdaTimeout.equals(that.lambdaTimeout) : that.lambdaTimeout != null) return false; if (this.maxNumberOfPagesPerDoc != null ? !this.maxNumberOfPagesPerDoc.equals(that.maxNumberOfPagesPerDoc) : that.maxNumberOfPagesPerDoc != null) return false; if (this.outputPolicyStatements != null ? !this.outputPolicyStatements.equals(that.outputPolicyStatements) : that.outputPolicyStatements != null) return false; if (this.s3InputBucket != null ? !this.s3InputBucket.equals(that.s3InputBucket) : that.s3InputBucket != null) return false; if (this.s3InputPrefix != null ? !this.s3InputPrefix.equals(that.s3InputPrefix) : that.s3InputPrefix != null) return false; if (this.textractDocumentSplitterBackoffRate != null ? !this.textractDocumentSplitterBackoffRate.equals(that.textractDocumentSplitterBackoffRate) : that.textractDocumentSplitterBackoffRate != null) return false; if (this.textractDocumentSplitterInterval != null ? !this.textractDocumentSplitterInterval.equals(that.textractDocumentSplitterInterval) : that.textractDocumentSplitterInterval != null) return false; return this.textractDocumentSplitterMaxRetries != null ? this.textractDocumentSplitterMaxRetries.equals(that.textractDocumentSplitterMaxRetries) : that.textractDocumentSplitterMaxRetries == null; } @Override public final int hashCode() { int result = this.s3OutputBucket.hashCode(); result = 31 * result + (this.s3OutputPrefix.hashCode()); result = 31 * result + (this.inputPolicyStatements != null ? this.inputPolicyStatements.hashCode() : 0); result = 31 * result + (this.lambdaLogLevel != null ? this.lambdaLogLevel.hashCode() : 0); result = 31 * result + (this.lambdaMemoryMb != null ? this.lambdaMemoryMb.hashCode() : 0); result = 31 * result + (this.lambdaTimeout != null ? this.lambdaTimeout.hashCode() : 0); result = 31 * result + (this.maxNumberOfPagesPerDoc != null ? this.maxNumberOfPagesPerDoc.hashCode() : 0); result = 31 * result + (this.outputPolicyStatements != null ? this.outputPolicyStatements.hashCode() : 0); result = 31 * result + (this.s3InputBucket != null ? this.s3InputBucket.hashCode() : 0); result = 31 * result + (this.s3InputPrefix != null ? this.s3InputPrefix.hashCode() : 0); result = 31 * result + (this.textractDocumentSplitterBackoffRate != null ? this.textractDocumentSplitterBackoffRate.hashCode() : 0); result = 31 * result + (this.textractDocumentSplitterInterval != null ? this.textractDocumentSplitterInterval.hashCode() : 0); result = 31 * result + (this.textractDocumentSplitterMaxRetries != null ? this.textractDocumentSplitterMaxRetries.hashCode() : 0); return result; } } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy