Documentation ¶
Overview ¶
Represents the pdf response.
Represents the base class for response.
Index ¶
- Variables
- func NewDlexWithAdditionalResource(resourcePath string, resourceName string) resource.Resource
- func SetLogger(logger log.Logger)
- type Action
- type Aes128Security
- type Aes256Security
- type ButtonFieldInformation
- type ButtonFieldType
- type ChoiceFieldInformation
- type ChoiceFieldType
- type Dlex
- type EncryptDocumentComponents
- type Endpoint
- type EndpointProcessor
- type FormField
- type FormFieldInformation
- type GoToAction
- type ImageInfo
- type ImageInformation
- type ImageResponse
- type JsonResponse
- func (r *JsonResponse) ClientError() error
- func (r *JsonResponse) ErrorId() uuid.UUID
- func (r *JsonResponse) ErrorJson() string
- func (r *JsonResponse) ErrorMessage() string
- func (r *JsonResponse) IsSuccessful() bool
- func (r *JsonResponse) SetStatusMessage(statusMessage string)
- func (r *JsonResponse) StatusCode() int
- type MultiSelectListBoxInformation
- type Outline
- type OutlineList
- func (p *OutlineList) Add(value string) *Outline
- func (p *OutlineList) AddPdfOutlines(value input.Pdf)
- func (p *OutlineList) AddWithInputValue(text string, input input.Input, pageOffSet int, pageZoom PageZoom) *Outline
- func (p *OutlineList) AddWithURL(value string, url Action) *Outline
- func (p OutlineList) MarshalJSON() ([]byte, error)
- type OutlineStyle
- type PageInformation
- type PageZoom
- type Pdf
- func (p *Pdf) AddDlexWithCloudResourceNLayoutData(cloudResourcePath string, layoutData resource.LayoutDataResource) *input.Dlex
- func (p *Pdf) AddDlexWithCloudResourceNLayoutDataPath(cloudResourcePath string, layoutDataPath string) *input.Dlex
- func (p *Pdf) AddDlexWithDlexResourceNLayoutDataPath(resource resource.DlexResource, layoutDataPath string) *input.Dlex
- func (p *Pdf) AddImage(resource resource.ImageResource) *input.Image
- func (p *Pdf) AddImageCloudPath(cloudResourcePath string) *input.Image
- func (p *Pdf) AddNewDlexWithDlexNLayoutResources(resource resource.DlexResource, layoutData resource.LayoutDataResource) *input.Dlex
- func (p *Pdf) AddPage() *input.Page
- func (p *Pdf) AddPageWithDimension(width float32, height float32) *input.Page
- func (p *Pdf) AddPdf(resource resource.PdfResource, option input.MergeOptions) *input.Pdf
- func (p *Pdf) AddPdfCloudPath(cloudResourcePath string, option input.MergeOptions) *input.Pdf
- func (p *Pdf) ApiKey() string
- func (p *Pdf) BaseUrl() string
- func (p *Pdf) EndpointName() string
- func (p *Pdf) GetInstructionsJson(indent bool) *bytes.Buffer
- func (p *Pdf) Process() <-chan PdfResponse
- type PdfContent
- type PdfInfo
- type PdfInfoResponse
- type PdfInformation
- type PdfInstruction
- type PdfResponse
- type PdfText
- func (p *PdfText) ApiKey() string
- func (p *PdfText) BaseUrl() string
- func (p *PdfText) EndpointName() string
- func (p *PdfText) GetPageCount(pageCount int)
- func (p *PdfText) GetStartPage(startPage int)
- func (p PdfText) MarshalJSON() ([]byte, error)
- func (p *PdfText) PageCount() int
- func (p *PdfText) Process() <-chan PdfTextResponse
- func (p *PdfText) StartPage() int
- type PdfTextResponse
- func (r *PdfTextResponse) ClientError() error
- func (pr *PdfTextResponse) Content() *bytes.Buffer
- func (r *PdfTextResponse) ErrorId() uuid.UUID
- func (r *PdfTextResponse) ErrorJson() string
- func (r *PdfTextResponse) ErrorMessage() string
- func (r *PdfTextResponse) IsSuccessful() bool
- func (r *PdfTextResponse) StatusCode() int
- type PdfXmp
- type PdfXmpResponse
- func (r *PdfXmpResponse) ClientError() error
- func (pr *PdfXmpResponse) Content() *bytes.Buffer
- func (r *PdfXmpResponse) ErrorId() uuid.UUID
- func (r *PdfXmpResponse) ErrorJson() string
- func (r *PdfXmpResponse) ErrorMessage() string
- func (r *PdfXmpResponse) IsSuccessful() bool
- func (r *PdfXmpResponse) StatusCode() int
- type PushButtonInformation
- type RC4128Security
- type Response
- type Securiter
- type Security
- type SecurityType
- type SignatureFieldInformation
- type TextFieldInformation
- type UrlAction
- type XmlResponse
Constants ¶
This section is empty.
Variables ¶
var ( // Default ApiKey for all endpoints. DefaultApiKey string = "" // Default base URL DefaultBaseUrl string = "https://api.dynamicpdf.com/" )
Functions ¶
func NewDlexWithAdditionalResource ¶ added in v1.3.0
Adds additional resource to the endpoint.
- @param {resourcePath} The resource file path.
- @param {resourceName} The name of the resource.
Types ¶
type Action ¶
type Action interface { }
Base class representing an action to perform tasks in many places such as in outlines, links, buttons etc.
type Aes128Security ¶
type Aes128Security struct {
Security
}
Represents AES 128 bit PDF document security.
AES 128 bit PDF security is compatible with PDF version 1.5 and higher and, Adobe Acrobat Reader version 7 or higher is needed to open these documents. Older readers will not be able to read documents encrypted with this security.
func NewAes128Security ¶
func NewAes128Security(userPwd string, ownerPwd string) *Aes128Security
Initializes a new instance of the `Aes128Security` class by taking the owner and user passwords as parameters to create PDF.
- @param {string} userPassword The owner password to open the document.
- @param {string} ownerPassword The user password to open the document.
func (*Aes128Security) DocumentComponents ¶
func (p *Aes128Security) DocumentComponents() EncryptDocumentComponents
Gets the `EncryptDocumentComponents` components of the document to be encrypted.
We can encrypt all the PDF content or the content, excluding the metadata.
func (*Aes128Security) SetDocumentComponents ¶
func (p *Aes128Security) SetDocumentComponents(value EncryptDocumentComponents)
sets the `EncryptDocumentComponents` components of the document to be encrypted.
We can encrypt all the PDF content or the content, excluding the metadata.
type Aes256Security ¶
type Aes256Security struct {
Security
}
Represents AES 256 bit PDF document security.
AES 128 bit PDF security is compatible with PDF version 1.5 and higher.
func NewAes256Security ¶
func NewAes256Security(userPwd string, ownerPwd string) *Aes256Security
Initializes a new instance of the `Aes256Security` class by taking the owner and user passwords as parameters to create PDF.
- @param {string} userPassword The owner password to open the document.
- @param {string} ownerPassword The user password to open the document.
func (*Aes256Security) DocumentComponents ¶
func (p *Aes256Security) DocumentComponents() EncryptDocumentComponents
Gets the `EncryptDocumentComponents`, components of the document to be encrypted.
We can encrypt all the PDF content or the content, excluding the metadata.
func (*Aes256Security) SetDocumentComponents ¶
func (p *Aes256Security) SetDocumentComponents(value EncryptDocumentComponents)
Sets the `EncryptDocumentComponents`, components of the document to be encrypted.
We can encrypt all the PDF content or the content, excluding the metadata.
type ButtonFieldInformation ¶
type ButtonFieldInformation struct { // Gets or Sets the name of the button field. Name string `json:"name,omitempty"` // Gets or sets the type of the button field, ex: RadioButton, CheckBox etc. Type int `json:"type,omitempty"` // Gets or sets the value of the button field. Value string `json:"value,omitempty"` /*Gets or Sets the default value of the button field. */ DefaultValue string `json:"defaultValue,omitempty"` /* Gets or Sets the export value. These values will be exported when submitting the form. To create a set of mutually exclusive radio buttons (i.e., where only one can be selected at a time), create the fields with the same name but different export values. */ ExportValue string `json:"exportValue,omitempty"` // Gets the collection of export value. ExportValues []string `json:"exportValues,omitempty"` }
type ButtonFieldType ¶
type ButtonFieldType int
Specifies the type of a button field.
const ( // Represents a Radio Button. RadioButton ButtonFieldType = 1 // Represents a Checkbox. CheckBox ButtonFieldType = 2 )
type ChoiceFieldInformation ¶
type ChoiceFieldInformation struct { // Gets or Sets the name of the button field. Name string `json:"name,omitempty"` // Gets or sets the type of the button field, ex: RadioButton, CheckBox etc. Type int `json:"type,omitempty"` // Gets or sets the value of the button field. Value string `json:"value,omitempty"` // Gets or Sets the default value of the button field. DefaultValue string `json:"default,omitempty"` // Gets or Sets the export value. ExportValue string `json:"exportValue,omitempty"` // Gets the collection of items. Items []string `json:"items,omitempty"` ItemExportValues []string `json:"itemExportValues,omitempty"` }
Represents the information of a choice field in interactive forms.
A choice field contains several text items, one or more of which may be selected as the field value.
type ChoiceFieldType ¶
type ChoiceFieldType int
Specifies type of the Choice Field.
const ( // Represents a List box. ListBox ChoiceFieldType = 1 // Represents a Combo box. ComboBox ChoiceFieldType = 2 )
type Dlex ¶
type Dlex struct { Endpoint `json:"-"` // This will bekipped in JSON // Gets or sets the DLEX file path present in the resource manager. DlexPath string `json:"dlexPath,omitempty"` Resources []resource.Resource // contains filtered or unexported fields }
Represents a Dlex layout endpoint.
func NewDlexEndpoint ¶
func NewDlexEndpoint(cloudDlexPath string, resource resource.LayoutDataResource) *Dlex
Initializes a new instance of the <see cref="DlexLayout"/> class using the
DLEX file path present in the cloud environment and the JSON data for the PDF report.
- @param {string} cloudDlexPath The DLEX file path present in the resource manager
- @param {LayoutDataResource} layoutData The `LayoutDataResource` json data file used to create the PDF report.
func NewDlexEndpointWithResource ¶ added in v1.3.0
func NewDlexEndpointWithResource(dlexResource resource.DlexResource, resource resource.LayoutDataResource) *Dlex
Initializes a new instance of the <see cref="DlexInput"/> class by posting the
DLEX file and the JSON data file from the client to the API to create the PDF report.
- @param {DlexResource} dlexResource The DLEX file created as per the desired PDF report layout design.
- @param {LayoutDataResource} layoutData The `LayoutDataResource` json data file used to create the PDF report.
func (*Dlex) EndpointName ¶
func (*Dlex) Process ¶
func (p *Dlex) Process() <-chan PdfResponse
Process the DLEX and layout data to create PDF report.
- @returns A Promise of DlexResponse callback.
type EncryptDocumentComponents ¶
type EncryptDocumentComponents int
Specifies the document components to be encrypted.
const ( // Encrypts all document contents. All EncryptDocumentComponents = iota // Encrypts all document contents except metadata. AllExceptMetadata EncryptDocumentComponents = iota )
type Endpoint ¶
type Endpoint struct { EndpointProcessor BaseUrl, ApiKey string }
type EndpointProcessor ¶
Represents the base class for endpoint and has settings for base url, api key and creates a rest request object.
type FormField ¶
type FormField struct { // Gets or sets name of the form field. Name string `json:"name,omitempty"` // Gets or sets value of the form field. Value string `json:"value,omitempty"` // Gets or sets a boolean indicating whether to flatten the form field. Flatten bool `json:"flatten,omitempty"` // Gets or sets a boolean indicating whether to remove the form field. Remove bool `json:"remove,omitempty"` }
Represents a form field in the PDF document.
func NewFormField ¶
Initializes a new instance of the `FormField` class
- using the name of the form field as a parameter.
- @param {string} name The name of the form field.
func NewFormFieldWithValue ¶
Initializes a new instance of the `FormField` class
- using the name of the form field as a parameter.
- @param {string} name The name of the form field.
- @param {string} value The value of the form field.
type FormFieldInformation ¶
type FormFieldInformation struct { resource.Resource // Gets or sets a collection of `SignatureFieldInformation` SignatureFields []string `json:"signatureFields,omitempty"` // Gets or sets a collection of `TextFieldInformation` TextFields []string `json:"textFields,omitempty"` // Gets or sets a collection of `ChoiceFieldInformation` . ChoiceFields []string `json:"choiceFields,omitempty"` // Gets or sets a collection of `ButtonFieldInformation` ButtonFields []string `json:"buttonFields,omitempty"` // Gets or sets a collection of `PushButtonInformation` PushButtons []string `json:"pushButtons,omitempty"` // Gets or sets a collection of `MultiSelectListBoxInformation` MultiSelectListBoxFields []string `json:"multiSelectListBoxFields,omitempty"` }
Represents the form field information containing the collection of different types of field information.
type GoToAction ¶
type GoToAction struct { Action `json:"-"` // Gets or sets `PageZoom` to display the destination. PageZoom PageZoom `json:"pageZoom,omitempty"` // Gets or sets page Offset. PageOffset int `json:"pageOffset,omitempty"` // contains filtered or unexported fields }
Represents a goto action in a PDF document that navigates to a specific page using page number and zoom options.
func NewGoToAction ¶
func NewGoToAction(input input.Input, pageOffset int, pageZoom PageZoom) *GoToAction
Initializes a new instance of the `GoToAction` class
- using an input to create the PDF, page number, and a zoom option.
- @param {Input} input Any of the `ImageInput`, `DlexInput`, `PdfInput` or `PageInput` objects to create PDF.
- @param {int} pgOffset Page number to navigate.
- @param {pageZoom} pgZoom Page Zoom to display the destination.
func (GoToAction) MarshalJSON ¶ added in v1.1.1
func (p GoToAction) MarshalJSON() ([]byte, error)
type ImageInfo ¶
type ImageInfo struct { Endpoint // contains filtered or unexported fields }
Represents an image information endpoint.
func NewImageInfo ¶
func NewImageInfo(image resource.ImageResource) *ImageInfo
Initializes a new instance of the `ImageInfo` class.
- @param {ImageResource} resource The image resource of type `ImageResource`.
func (*ImageInfo) EndpointName ¶
func (ImageInfo) MarshalJSON ¶
func (*ImageInfo) Process ¶
func (p *ImageInfo) Process() <-chan ImageResponse
Process the image resource to get image's information.
- @returns A Promise of ImageResponse callback.
type ImageInformation ¶
type ImageInformation struct { Endpoint // Gets page number of the pdf where the image is present. PageNumber int `json:"pageNumber,omitempty"` // Gets the width of the image. Width float32 `json:"width,omitempty"` // Gets the height of the image. Height float32 `json:"height,omitempty"` // Gets the horizontalDpi of the image. HorizontalDpi float32 `json:"horizontalDpi,omitempty"` // Gets the verticalDpi of the image. VerticalDpi float32 `json:"verticalDpi,omitempty"` // Gets the number of color components present in the image. NumberOfComponents float32 `json:"numberOfComponents,omitempty"` // Gets the bits per component of the image. BitsPerComponent float32 `json:"bitsPerComponent,omitempty"` // Gets the color space of the image. ColorSpace int `json:"colorSpace,omitempty"` }
type ImageResponse ¶
type ImageResponse struct {
JsonResponse
}
Represents an image response.
func NewImageResponse ¶
func NewImageResponse(jsonContent string) *ImageResponse
Initializes a new instance of the `ImageResponse` class.
- @param {string} imageResponse The image content of the response.
func (*ImageResponse) Content ¶
func (pr *ImageResponse) Content() *bytes.Buffer
type JsonResponse ¶
type JsonResponse struct { Response // contains filtered or unexported fields }
Represents the base class for json response.
func (*JsonResponse) ClientError ¶
func (r *JsonResponse) ClientError() error
func (*JsonResponse) ErrorMessage ¶
func (r *JsonResponse) ErrorMessage() string
Gets the error message.
func (*JsonResponse) IsSuccessful ¶
func (r *JsonResponse) IsSuccessful() bool
Gets the boolean, indicating the response's status.
func (*JsonResponse) SetStatusMessage ¶
func (r *JsonResponse) SetStatusMessage(statusMessage string)
type MultiSelectListBoxInformation ¶
type MultiSelectListBoxInformation struct { // Gets or Sets the name of a MultiSelectListBox. Name string `json:"name,omitempty"` // Gets or sets a collection of values of the MultiSelectListBox. Values []string `json:"values,omitempty"` // Gets or sets a collection of default values of the MultiSelectListBox. DefaultValues []string `json:"defaultValues,omitempty"` // Gets or sets a collection of export values of the MultiSelectListBox. ExportValues []string `json:"exportValues,omitempty"` // Gets or sets a collection of items of the MultiSelectListBox. Items []string `json:"items,omitempty"` // Gets or sets a collection of export values of the MultiSelectListBox. ItemsExportValues []string `json:"itemsExportValues,omitempty"` }
Represents information of a MultiSelectListBox.
type Outline ¶
type Outline struct { // Gets or sets the text of the outline. Text string `json:"text,omitempty"` // Gets or sets a value specifying if the outline is expanded. Expanded bool `json:"expanded,omitempty"` // Gets or sets the style of the outline. Style OutlineStyle `json:"style,omitempty"` // contains filtered or unexported fields }
Represents an outline.
func (*Outline) Children ¶
func (p *Outline) Children() *OutlineList
func (*Outline) GetChildren ¶
Gets a collection of child outlines.
func (Outline) MarshalJSON ¶
type OutlineList ¶
type OutlineList struct {
// contains filtered or unexported fields
}
Represents an outlineList.
func (*OutlineList) Add ¶
func (p *OutlineList) Add(value string) *Outline
Adds an `Outline` object to the outline list.
- @param {string} text Text of the outline.
- @returns outline
func (*OutlineList) AddPdfOutlines ¶
func (p *OutlineList) AddPdfOutlines(value input.Pdf)
func (*OutlineList) AddWithInputValue ¶
func (p *OutlineList) AddWithInputValue(text string, input input.Input, pageOffSet int, pageZoom PageZoom) *Outline
Adds an `Outline` object to the outline list.
- @param {string} text Text of the outline.
- @param {Input} Any of the `ImageInput`, `DlexInput`, `PdfInput`,
- @param {*} pgOffset Page number to navigate.
- @param {*} pgZoom Page Zoom to display the destination.
- @returns outline
func (*OutlineList) AddWithURL ¶
func (p *OutlineList) AddWithURL(value string, url Action) *Outline
Adds an `Outline` object to the outline list.
- @param {string} text Text of the outline.
- @param {string} input URL the action launches.
- @returns outline
func (OutlineList) MarshalJSON ¶
func (p OutlineList) MarshalJSON() ([]byte, error)
type OutlineStyle ¶
type OutlineStyle int
const ( // Bold. Bold OutlineStyle = 0 // BoldItalic. BoldItalic OutlineStyle = 1 // Italic. Italic OutlineStyle = 2 // Regular. Regular OutlineStyle = 3 )
type PageInformation ¶
type Pdf ¶
type Pdf struct { Endpoint `json:"-"` // This will be skipped in JSON Author string Title string Subject string Creator string Keywords string Producer string Tag bool Templates []element.Template Fonts []font.Font FormFields []FormField Outlines OutlineList Inputs []input.InputCollector Security Security FlattenAllFormFields bool RetainSignatureFormFields bool // contains filtered or unexported fields }
Represents a pdf endpoint.
func (*Pdf) AddDlexWithCloudResourceNLayoutData ¶
func (p *Pdf) AddDlexWithCloudResourceNLayoutData(cloudResourcePath string, layoutData resource.LayoutDataResource) *input.Dlex
Returns a `DlexInput` object containing the input pdf.
- @param {String} The resource path in cloud resource manager.
- @param {LayoutDataResource} value1 The layout data resource of type `LayoutDataResource`
- @returns DlexInput
func (*Pdf) AddDlexWithCloudResourceNLayoutDataPath ¶
func (p *Pdf) AddDlexWithCloudResourceNLayoutDataPath(cloudResourcePath string, layoutDataPath string) *input.Dlex
Returns a `DlexInput` object containing the input pdf.
- @param {String} The resource path in cloud resource manager.
- @param {String} The layout data resource path.
- @returns DlexInput
func (*Pdf) AddDlexWithDlexResourceNLayoutDataPath ¶
func (p *Pdf) AddDlexWithDlexResourceNLayoutDataPath(resource resource.DlexResource, layoutDataPath string) *input.Dlex
Returns a `DlexInput` object containing the input pdf.
- @param {DlexResource} value The dlex resource of type `DlexResource`.
- @param {string} value1 The layout data resource path.
- @returns DlexInput
func (*Pdf) AddImage ¶
func (p *Pdf) AddImage(resource resource.ImageResource) *input.Image
Returns a `ImageInput` object containing the input pdf.
- @param {PdfResource} value The resource of type `ImageResource`.
- @returns ImageInput
func (*Pdf) AddImageCloudPath ¶
Returns a `ImageInput` object containing the input pdf.
- @param {string}The resource path in cloud resource manager.
- @returns ImageInput
func (*Pdf) AddNewDlexWithDlexNLayoutResources ¶
func (p *Pdf) AddNewDlexWithDlexNLayoutResources(resource resource.DlexResource, layoutData resource.LayoutDataResource) *input.Dlex
Returns a `DlexInput` object containing the input pdf.
- @param {DlexResource} value The dlex resource of type `DlexResource`.
- @param {LayoutDataResource} value1 The layout data resource of type `LayoutDataResource`
- @returns DlexInput
func (*Pdf) AddPageWithDimension ¶
Returns a `PageInput` object containing the input pdf.
- @param {float} pageWidth The width of the page.
- @param {float} pageHeight The height of the page.
- @returns PageInput
func (*Pdf) AddPdf ¶
func (p *Pdf) AddPdf(resource resource.PdfResource, option input.MergeOptions) *input.Pdf
Returns a `PdfInput` object containing the input pdf.
- @param {resource} value The resource of type `PdfResource`
- @param {MergeOptions} options The merge options for the pdf.
- @returns PdfInput
func (*Pdf) AddPdfCloudPath ¶
Returns a `PdfInput` object containing the input pdf.
- @param {cloudResourcePath} The resource path in cloud resource manager.
- @param {MergeOptions} options The merge options for the pdf.
- @returns PdfInput
func (*Pdf) EndpointName ¶
func (*Pdf) Process ¶
func (p *Pdf) Process() <-chan PdfResponse
Process to create pdf.
- @returns A Promise of PdfResponse callback.
type PdfContent ¶
type PdfInfo ¶
Represents the pdf info endpoint.
func NewPdfInfoResource ¶
func NewPdfInfoResource(resource resource.PdfResource) *PdfInfo
Initializes a new instance of the `PdfInfo` class.
- @param {Resource} resource The resource of type `PdfResource`
func (*PdfInfo) EndpointName ¶
func (PdfInfo) MarshalJSON ¶
func (*PdfInfo) Process ¶
func (p *PdfInfo) Process() <-chan PdfInfoResponse
Process the pdf resource to get pdf's information.
- @returns A Promise of PdfInfo response
type PdfInfoResponse ¶
type PdfInfoResponse struct {
JsonResponse
}
Represents the pdf information response.
func NewPdfInfoResponse ¶
func NewPdfInfoResponse() *PdfInfoResponse
Initializes a new instance of the `PdfInfoResponse` class.
func (*PdfInfoResponse) Content ¶
func (pr *PdfInfoResponse) Content() *bytes.Buffer
Gets the pdf information content.
type PdfInformation ¶
type PdfInformation struct { // Gets the author. Author string `json:"author,omitempty"` // Gets the subject. Subject string `json:"subject,omitempty"` // Gets the keywords. Keywords string `json:"keyword,omitempty"` // Gets the creator. Creator string `json:"creator,omitempty"` // Gets the producer. Producer string `json:"producer,omitempty"` // Gets the title. Title string `json:"title,omitempty"` // Gets the collection of PageInformation. Pages []PageInformation `json:"pages,omitempty"` // Gets the form fields. FormFields FormFieldInformation `json:"formFields,omitempty"` // Gets the custom properties. CustomProperties string `json:"customProperties,omitempty"` // Gets the boolean representing xmp meta data. XmpMetaData bool `json:"xmpMetaData,omitempty"` // Gets the boolean, indicating whether the pdf is signed. Signed bool `json:"signed,omitempty"` // Gets the boolean, indicating whether the pdf is tagged. Tagged bool `json:"tagged,omitempty"` }
Represents the pdf information.
type PdfInstruction ¶
type PdfInstruction struct {
// contains filtered or unexported fields
}
Represents the pdf information.
func NewPdfInstruction ¶
func NewPdfInstruction() *PdfInstruction
func (*PdfInstruction) GetOutlines ¶
func (p *PdfInstruction) GetOutlines() []Outline
func (*PdfInstruction) MarshalJSON ¶
func (p *PdfInstruction) MarshalJSON() ([]byte, error)
type PdfResponse ¶
type PdfResponse struct {
// contains filtered or unexported fields
}
Initializes a new instance of the `PdfResponse` class.
- @param {Buffer[]} pdfContent The byte array of pdf content.
func (*PdfResponse) Content ¶
func (pr *PdfResponse) Content() *bytes.Buffer
Gets the content of pdf.
func (*PdfResponse) ErrorMessage ¶
func (r *PdfResponse) ErrorMessage() string
Gets the error message.
func (*PdfResponse) IsSuccessful ¶
func (r *PdfResponse) IsSuccessful() bool
Gets the boolean, indicating the response's status.
type PdfText ¶
type PdfText struct { Endpoint // contains filtered or unexported fields }
Represents the pdf text endpoint.
func NewPdfText ¶
func NewPdfText(resource resource.PdfResource, startpage int, pagecount int) *PdfText
Initializes a new instance of the `PdfText` class.
- @param { PdfResource } resource The image resource of type `PdfResource`.`
- @param { int } startPage The start page.
- @param { int } pageCount The page count.
func (*PdfText) EndpointName ¶
func (PdfText) MarshalJSON ¶
func (*PdfText) Process ¶
func (p *PdfText) Process() <-chan PdfTextResponse
Process the pdf resource to get pdf's text.
- @returns A Promise of PdfTextResponse callback.
type PdfTextResponse ¶
type PdfTextResponse struct {
JsonResponse
}
Represnts the pdf resource.
func NewPdfTextResponse ¶
func NewPdfTextResponse() *PdfTextResponse
Initializes a new instance of the `PdfResponse` class.
func (*PdfTextResponse) ClientError ¶
func (r *PdfTextResponse) ClientError() error
func (*PdfTextResponse) Content ¶
func (pr *PdfTextResponse) Content() *bytes.Buffer
Gets the collection of PdfContent.
func (*PdfTextResponse) ErrorJson ¶
func (r *PdfTextResponse) ErrorJson() string
Gets the error json.
func (*PdfTextResponse) ErrorMessage ¶
func (r *PdfTextResponse) ErrorMessage() string
Gets the error message.
func (*PdfTextResponse) IsSuccessful ¶
func (r *PdfTextResponse) IsSuccessful() bool
Gets the boolean, indicating the response's status.
func (*PdfTextResponse) StatusCode ¶
func (r *PdfTextResponse) StatusCode() int
Gets the status code.
type PdfXmp ¶
type PdfXmp struct { Endpoint // contains filtered or unexported fields }
Represents the pdfresource.
func NewPdfXmp ¶
func NewPdfXmp(resource resource.PdfResource) *PdfXmp
Initializes a new instance of the `PdfXmp` class.
- @param {PdfResource} resource The image resource of type `PdfResource`.
func (*PdfXmp) EndpointName ¶
func (PdfXmp) MarshalJSON ¶
func (*PdfXmp) Process ¶
func (p *PdfXmp) Process() <-chan PdfXmpResponse
Process the pdf resource to get pdf's xmp data.
- @returns A Promise of PdfTextResponse callback.
type PdfXmpResponse ¶
type PdfXmpResponse struct {
JsonResponse
}
Represnts the pdf resource.
func NewPdfXmpResponse ¶
func NewPdfXmpResponse() *PdfXmpResponse
Initializes a new instance of the `XmlResponse` class.
- @param {string} xmlContent The xml content of the response.
func (*PdfXmpResponse) ClientError ¶
func (r *PdfXmpResponse) ClientError() error
func (*PdfXmpResponse) Content ¶
func (pr *PdfXmpResponse) Content() *bytes.Buffer
Gets the xml content.
func (*PdfXmpResponse) ErrorMessage ¶
func (r *PdfXmpResponse) ErrorMessage() string
Gets the error message.
func (*PdfXmpResponse) IsSuccessful ¶
func (r *PdfXmpResponse) IsSuccessful() bool
Gets the boolean, indicating the response's status.
type PushButtonInformation ¶
type PushButtonInformation struct { // Gets or Sets the name of a PushButton field. Name string `json:"name,omitempty"` // Gets or Sets the label of a PushButton field. Label string `json:"label,omitempty"` }
Represents information of a PushButton field.
type RC4128Security ¶
type RC4128Security struct {
Security
}
Represents RC4 128 bit PDF document security.
RC4 128 bit PDF security, with UseCryptFilter property set to false is compatible with PDF version 1.4 or higher and can be read with Adobe Acrobat Reader version 5 or higher. By default UseCryptFilter property is false. RC4 128 bit PDF security with crypt filter is compatible with PDF version 1.5 or higher and can be read with Adobe Acrobat Reader version 6 and higher. Older readers will not be able to read document encrypted with this security.
func NewRC4128Security ¶
func NewRC4128Security() *RC4128Security
Initializes a new instance of the `RC4128Security` class.
func (*RC4128Security) EncryptMetadata ¶
func (p *RC4128Security) EncryptMetadata() bool
Gets the documents components to be encrypted.
func (*RC4128Security) SetEncryptMetadata ¶
func (p *RC4128Security) SetEncryptMetadata(value bool)
Sets the documents components to be encrypted.
type Security ¶
type Security struct { Securiter `json:"-"` //Gets or sets the user password. UserPassword string `json:"userPassword,omitempty"` //Gets or sets the owner password. OwnerPassword string `json:"ownerPassword,omitempty"` // Gets or sets if text and images can be copied to the clipboard by the user. AllowCopy string `json:"allowCopy,omitempty"` // Gets or sets if the document can be edited by the user. AllowEdit string `json:"allowEdit,omitempty"` // Gets or sets if the document can be printed by the user. AllowPrint string `json:"allowPrint,omitempty"` // Gets or sets if annotations and form fields can be added, edited and modified by the user. AllowUpdateAnnotationsAndFields string `json:"allowUpdateAnnotationsAndFields,omitempty"` // Gets or sets if accessibility programs should be able to read the documents text and images for the user. AllowAccessibility string `json:"allowAccessibility,omitempty"` // Gets or sets if form filling should be allowed by the user. AllowFormFilling string `json:"allowFormFilling,omitempty"` // Gets or sets if the document can be printed at a high resolution by the user. AllowHighResolutionPrinting string `json:"allowHighResolutionPrinting,omitempty"` // Gets or sets if the document can be assembled and manipulated by the user. AllowDocumentAssembly string `json:"allowDocumentAssembly,omitempty"` // contains filtered or unexported fields }
Represents AES 128 bit PDF document security.
AES 128 bit PDF security is compatible with PDF version 1.5 and higher and, Adobe Acrobat Reader version 7 or higher is needed to open these documents. Older readers will not be able to read documents encrypted with this security.
func (Security) MarshalJSON ¶
type SecurityType ¶
type SecurityType int
const ( // AES 128 bit security. Aes128 SecurityType = 0 // AES 256 bit security. Aes256 SecurityType = 1 // RC4 128 bit security. RC4128 SecurityType = 2 )
Represents information of a PushButton field.
type SignatureFieldInformation ¶
type SignatureFieldInformation struct { // Gets or Sets the name of a signature field. Name string `json:"name,omitempty"` // Gets or Sets the boolean, indicating the field signed or not. Signed bool `json:"signed,omitempty"` }
Represents information of a signature field.
type TextFieldInformation ¶
type TextFieldInformation struct { // Gets or Sets the name of the Text field. Name string `json:"name,omitempty"` // Gets or Sets the value of the Text field. Value string `json:"value,omitempty"` // Gets or Sets the default value of the Text field. DefaultValue string `json:"defaultValue,omitempty"` }
Represents information of a text field.
type UrlAction ¶
type UrlAction struct { // Gets or Sets the name of a signature field. Url string `json:"url,omitempty"` }
Represents information of a signature field.
func NewUrlAction ¶ added in v1.1.1
type XmlResponse ¶
type XmlResponse struct { JsonResponse // Gets the xml content. Content []string `json:"content,omitempty"` }
Represents the xml response.
Source Files ¶
- Aes128Security.go
- Aes256Security.go
- ButtonFieldInformation.go
- ButtonFieldType.go
- ChoiceFieldInformation.go
- ChoiceFieldType.go
- DlexLayout.go
- EncryptDocumentComponents.go
- FormField.go
- FormFieldInformation.go
- GoToAction.go
- ImageInfo.go
- ImageInformation.go
- ImageResponse.go
- JsonResponse.go
- MultiSelectListBoxInformation.go
- Outline.go
- OutlineList.go
- OutlineStyle.go
- PageInformation.go
- PageZoom.go
- PdfContent.go
- PdfInfo.go
- PdfInfoResponse.go
- PdfInformation.go
- PdfInstructions.go
- PdfResponse.go
- PdfText.go
- PdfTextResponse.go
- PdfXmp.go
- PushButtonInformation.go
- RC4128Security.go
- Security.go
- SecurityType.go
- SignatureFieldInformation.go
- TextFieldInformation.go
- UrlAction.go
- XmlResponse.go
- action.go
- endpoint.go
- pdf.go
- pdfxmpresponse.go
- response.go