Show / Hide Table of Contents

Class PDFPropertiesJob

A job that is used to fetch properties from an input PDF file. The properties are returned in a POJO.

Inheritance
System.Object
PDFServicesJob
PDFPropertiesJob
Namespace: Adobe.PDFServicesSDK.pdfjobs.jobs
Assembly: Adobe.PDFServicesSDK.Doc.dll
Syntax
public class PDFPropertiesJob : PDFServicesJob
Examples

Sample Usage:

    using Stream inputStream = File.OpenRead("<SOURCE_PATH>");

    ICredentials credentials = new ServicePrincipalCredentials(
        Environment.GetEnvironmentVariable("PDF_SERVICES_CLIENT_ID"),
        Environment.GetEnvironmentVariable("PDF_SERVICES_CLIENT_SECRET"));

    PDFServices pdfServices = new PDFServices(credentials);

    IAsset asset = pdfServices.Upload(inputStream, PDFServicesMediaType.PDF.GetMIMETypeValue());

    PDFPropertiesParams pdfPropertiesParams = PDFPropertiesParams.PDFPropertiesParamsBuilder()
        .IncludePageLevelProperties()
        .Build();
    PDFPropertiesJob pdfPropertiesJob = new PDFPropertiesJob(asset)
        .SetParams(pdfPropertiesParams);
    String location = pdfServices.Submit(pdfPropertiesJob);
    PDFServicesResponse<PDFPropertiesResult> pdfServicesResponse =
        pdfServices.GetJobResult<PDFPropertiesResult>(location, typeof(PDFPropertiesResult));

    PDFProperties pdfProperties = pdfServicesResponse.getResult().getPdfProperties();

Constructors

PDFPropertiesJob(IAsset)

Constructs a new PDFPropertiesJob instance.

Declaration
public PDFPropertiesJob(IAsset asset)
Parameters
Type Name Description
IAsset asset

The input IAsset for the job; can not be null.

Methods

SetParams(PDFPropertiesParams)

Sets the parameters for the job.

Declaration
public PDFPropertiesJob SetParams(PDFPropertiesParams pdfPropertiesParams)
Parameters
Type Name Description
PDFPropertiesParams pdfPropertiesParams

PDFPropertiesJob for the job.

Returns
Type Description
PDFPropertiesJob

PDFPropertiesJob instance

In This Article
  • Constructors
    • PDFPropertiesJob(IAsset)
  • Methods
    • SetParams(PDFPropertiesParams)
Back to top Copyright © 2020 Adobe. All rights reserved.