Example usage for com.amazonaws.services.elastictranscoder.model CreateJobRequest withInput

List of usage examples for com.amazonaws.services.elastictranscoder.model CreateJobRequest withInput

Introduction

In this page you can find the example usage for com.amazonaws.services.elastictranscoder.model CreateJobRequest withInput.

Prototype


public CreateJobRequest withInput(JobInput input) 

Source Link

Document

A section of the request body that provides information about the file that is being transcoded.

Usage

From source file:org.nuxeo.aws.elastictranscoder.AWSElasticTranscoder.java

License:Open Source License

protected void createElasticTranscoderJob() {
    // (using code from the AWS code sample in
    // JobStatusNotificationsSample.java)

    // Setup the job input
    JobInput jobInput = new JobInput().withKey(inputKey);

    // We create just one job here. Look at the code sample in
    // JobStatusNotificationsSample.java to see how to create several jobs
    // in one call.
    CreateJobOutput output = new CreateJobOutput().withKey(outputKey);
    output.withPresetId(presetId);/*from  w w  w  .ja v  a2  s  . com*/
    // Create a job on the specified pipeline and get the job ID
    CreateJobRequest createJobRequest = new CreateJobRequest();
    createJobRequest.withPipelineId(pipelineId);
    createJobRequest.withInput(jobInput);
    createJobRequest.withOutput(output);

    CreateJobResult cjr = genericAwsClient.getElasticTranscoder().createJob(createJobRequest);
    awsJobId = cjr.getJob().getId();

}