Class EditJsonSchema.Builder
- java.lang.Object
-
- ai.extend.types.EditJsonSchema.Builder
-
- Enclosing class:
- EditJsonSchema
public static final class EditJsonSchema.Builder extends java.lang.Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description EditJsonSchema.BuilderadditionalProperties(java.lang.Boolean additionalProperties)EditJsonSchema.BuilderadditionalProperties(java.util.Optional<java.lang.Boolean> additionalProperties)Whether additional properties are allowed (for object types)EditJsonSchemabuild()EditJsonSchema.Builderdescription(java.lang.String description)EditJsonSchema.Builderdescription(java.util.Optional<java.lang.String> description)Description of the fieldEditJsonSchema.Builderenum_(java.util.List<java.lang.String> enum_)EditJsonSchema.Builderenum_(java.util.Optional<java.util.List<java.lang.String>> enum_)Allowed values for enum/dropdown/radio fieldsEditJsonSchema.BuilderextendEditBbox(EditBoundingBox extendEditBbox)EditJsonSchema.BuilderextendEditBbox(java.util.Optional<EditBoundingBox> extendEditBbox)EditJsonSchema.BuilderextendEditColumnWidth(java.lang.Double extendEditColumnWidth)EditJsonSchema.BuilderextendEditColumnWidth(java.util.Optional<java.lang.Double> extendEditColumnWidth)Width of the column as a percentage (for table fields)EditJsonSchema.BuilderextendEditFieldType(EditJsonSchemaExtendEditFieldType extendEditFieldType)EditJsonSchema.BuilderextendEditFieldType(java.util.Optional<EditJsonSchemaExtendEditFieldType> extendEditFieldType)The PDF field type to edit.EditJsonSchema.BuilderextendEditPageIndex(java.lang.Integer extendEditPageIndex)EditJsonSchema.BuilderextendEditPageIndex(java.util.Optional<java.lang.Integer> extendEditPageIndex)Zero-based page index where the field should be placedEditJsonSchema.BuilderextendEditRowHeights(java.util.List<java.lang.Double> extendEditRowHeights)EditJsonSchema.BuilderextendEditRowHeights(java.util.Optional<java.util.List<java.lang.Double>> extendEditRowHeights)Array of row height percentages for array/table fields (e.g.EditJsonSchema.BuilderextendEditTextEditOptions(EditTextOptions extendEditTextEditOptions)EditJsonSchema.BuilderextendEditTextEditOptions(java.util.Optional<EditTextOptions> extendEditTextEditOptions)EditJsonSchema.BuilderextendEditValue(java.lang.Object extendEditValue)EditJsonSchema.BuilderextendEditValue(java.util.Optional<java.lang.Object> extendEditValue)The value to fill into this field.EditJsonSchema.Builderfrom(EditJsonSchema other)EditJsonSchema.Builderitems(EditObjectJsonSchema items)EditJsonSchema.Builderitems(java.util.Optional<EditObjectJsonSchema> items)Schema for array items (when type is "array").EditJsonSchema.BuildermaxItems(java.lang.Integer maxItems)EditJsonSchema.BuildermaxItems(java.util.Optional<java.lang.Integer> maxItems)Maximum number of rows for array/table fieldsEditJsonSchema.Builderproperties(java.util.Map<java.lang.String,EditJsonSchema> properties)EditJsonSchema.Builderproperties(java.util.Optional<java.util.Map<java.lang.String,EditJsonSchema>> properties)Nested properties for object types.EditJsonSchema.Builderrequired(java.util.List<java.lang.String> required)EditJsonSchema.Builderrequired(java.util.Optional<java.util.List<java.lang.String>> required)List of required property names (for object types)EditJsonSchema.Buildertype(java.lang.Object type)EditJsonSchema.Buildertype(java.util.Optional<java.lang.Object> type)The JSON schema type of the field.
-
-
-
Method Detail
-
from
public EditJsonSchema.Builder from(EditJsonSchema other)
-
type
public EditJsonSchema.Builder type(java.util.Optional<java.lang.Object> type)
The JSON schema type of the field. Can be:
- A string: "array" or "object"
- A nullable tuple array: ["string", "null"], ["number", "null"], ["integer", "null"], ["boolean", "null"]
- Omitted for enum fields (use enum property instead)
-
type
public EditJsonSchema.Builder type(java.lang.Object type)
-
description
public EditJsonSchema.Builder description(java.util.Optional<java.lang.String> description)
Description of the field
-
description
public EditJsonSchema.Builder description(java.lang.String description)
-
extendEditFieldType
public EditJsonSchema.Builder extendEditFieldType(java.util.Optional<EditJsonSchemaExtendEditFieldType> extendEditFieldType)
The PDF field type to edit. Allowed values depend on the schema type:
["string", "null"]→text,signature["number", "null"]→text["integer", "null"]→text["boolean", "null"]→checkbox,radio"array"→text,table"object"→signature- enum fields (no type) →
radio,optionList,dropdown
-
extendEditFieldType
public EditJsonSchema.Builder extendEditFieldType(EditJsonSchemaExtendEditFieldType extendEditFieldType)
-
extendEditBbox
public EditJsonSchema.Builder extendEditBbox(java.util.Optional<EditBoundingBox> extendEditBbox)
-
extendEditBbox
public EditJsonSchema.Builder extendEditBbox(EditBoundingBox extendEditBbox)
-
extendEditPageIndex
public EditJsonSchema.Builder extendEditPageIndex(java.util.Optional<java.lang.Integer> extendEditPageIndex)
Zero-based page index where the field should be placed
-
extendEditPageIndex
public EditJsonSchema.Builder extendEditPageIndex(java.lang.Integer extendEditPageIndex)
-
extendEditTextEditOptions
public EditJsonSchema.Builder extendEditTextEditOptions(java.util.Optional<EditTextOptions> extendEditTextEditOptions)
-
extendEditTextEditOptions
public EditJsonSchema.Builder extendEditTextEditOptions(EditTextOptions extendEditTextEditOptions)
-
extendEditColumnWidth
public EditJsonSchema.Builder extendEditColumnWidth(java.util.Optional<java.lang.Double> extendEditColumnWidth)
Width of the column as a percentage (for table fields)
-
extendEditColumnWidth
public EditJsonSchema.Builder extendEditColumnWidth(java.lang.Double extendEditColumnWidth)
-
extendEditValue
public EditJsonSchema.Builder extendEditValue(java.util.Optional<java.lang.Object> extendEditValue)
The value to fill into this field. Can be any type. This will force the value at this field to be filled with this value. If a value is not provided, we will attempt to generate or infer one based on the instructions.
-
extendEditValue
public EditJsonSchema.Builder extendEditValue(java.lang.Object extendEditValue)
-
extendEditRowHeights
public EditJsonSchema.Builder extendEditRowHeights(java.util.Optional<java.util.List<java.lang.Double>> extendEditRowHeights)
Array of row height percentages for array/table fields (e.g. [0.25, 0.50, 0.25])
-
extendEditRowHeights
public EditJsonSchema.Builder extendEditRowHeights(java.util.List<java.lang.Double> extendEditRowHeights)
-
items
public EditJsonSchema.Builder items(java.util.Optional<EditObjectJsonSchema> items)
Schema for array items (when type is "array"). Must be an EditObjectJSONSchema.
-
items
public EditJsonSchema.Builder items(EditObjectJsonSchema items)
-
properties
public EditJsonSchema.Builder properties(java.util.Optional<java.util.Map<java.lang.String,EditJsonSchema>> properties)
Nested properties for object types. Each property follows the EditJSONSchema structure.
-
properties
public EditJsonSchema.Builder properties(java.util.Map<java.lang.String,EditJsonSchema> properties)
-
enum_
public EditJsonSchema.Builder enum_(java.util.Optional<java.util.List<java.lang.String>> enum_)
Allowed values for enum/dropdown/radio fields
-
enum_
public EditJsonSchema.Builder enum_(java.util.List<java.lang.String> enum_)
-
maxItems
public EditJsonSchema.Builder maxItems(java.util.Optional<java.lang.Integer> maxItems)
Maximum number of rows for array/table fields
-
maxItems
public EditJsonSchema.Builder maxItems(java.lang.Integer maxItems)
-
required
public EditJsonSchema.Builder required(java.util.Optional<java.util.List<java.lang.String>> required)
List of required property names (for object types)
-
required
public EditJsonSchema.Builder required(java.util.List<java.lang.String> required)
-
additionalProperties
public EditJsonSchema.Builder additionalProperties(java.util.Optional<java.lang.Boolean> additionalProperties)
Whether additional properties are allowed (for object types)
-
additionalProperties
public EditJsonSchema.Builder additionalProperties(java.lang.Boolean additionalProperties)
-
build
public EditJsonSchema build()
-
-