ExportResult.Builder


public final class ExportResult.Builder


A builder for ExportResult instances.

Summary

Public constructors

Creates a builder.

Public methods

ExportResult.Builder

Adds processed inputs to the ProcessedInput list.

ExportResult

Builds an ExportResult instance.

void

Resets all the fields to their default values.

ExportResult.Builder

Sets the name of the audio encoder used.

ExportResult.Builder

Sets the average audio bitrate.

ExportResult.Builder

Sets the average video bitrate.

ExportResult.Builder

Sets the channel count.

ExportResult.Builder

Sets the ColorInfo.

ExportResult.Builder

Sets the duration of the output in milliseconds.

ExportResult.Builder

Sets the ExportException that caused the export to fail.

ExportResult.Builder

Sets the file size in bytes.

ExportResult.Builder

Sets the height.

ExportResult.Builder

Sets OptimizationResult to indicate an optimization as been successful, or has failed and normal export proceeded instead.

ExportResult.Builder

Sets the sample rate.

ExportResult.Builder

Sets the name of the video encoder used.

ExportResult.Builder

Sets the number of video frames.

ExportResult.Builder

Sets the width.

Public constructors

Builder

public Builder()

Creates a builder.

Public methods

build

public ExportResult build()

Builds an ExportResult instance.

reset

public void reset()

Resets all the fields to their default values.

setAudioEncoderName

@CanIgnoreReturnValue
public ExportResult.Builder setAudioEncoderName(@Nullable String audioEncoderName)

Sets the name of the audio encoder used.

setAverageAudioBitrate

@CanIgnoreReturnValue
public ExportResult.Builder setAverageAudioBitrate(int averageAudioBitrate)

Sets the average audio bitrate.

Must be positive or RATE_UNSET_INT.

setAverageVideoBitrate

@CanIgnoreReturnValue
public ExportResult.Builder setAverageVideoBitrate(int averageVideoBitrate)

Sets the average video bitrate.

Must be positive or RATE_UNSET_INT.

setChannelCount

@CanIgnoreReturnValue
public ExportResult.Builder setChannelCount(int channelCount)

Sets the channel count.

Must be positive or LENGTH_UNSET.

setColorInfo

@CanIgnoreReturnValue
public ExportResult.Builder setColorInfo(@Nullable ColorInfo colorInfo)

Sets the ColorInfo.

setDurationMs

@CanIgnoreReturnValue
public ExportResult.Builder setDurationMs(long durationMs)

Sets the duration of the output in milliseconds.

Must be positive or TIME_UNSET.

setExportException

@CanIgnoreReturnValue
public ExportResult.Builder setExportException(@Nullable ExportException exportException)

Sets the ExportException that caused the export to fail.

setFileSizeBytes

@CanIgnoreReturnValue
public ExportResult.Builder setFileSizeBytes(long fileSizeBytes)

Sets the file size in bytes.

Must be positive or LENGTH_UNSET.

setHeight

@CanIgnoreReturnValue
public ExportResult.Builder setHeight(int height)

Sets the height.

Must be positive or LENGTH_UNSET.

setOptimizationResult

@CanIgnoreReturnValue
public ExportResult.Builder setOptimizationResult(int optimizationResult)

Sets OptimizationResult to indicate an optimization as been successful, or has failed and normal export proceeded instead.

The default value is OPTIMIZATION_NONE.

Parameters
int optimizationResult

The OptimizationResult.

setSampleRate

@CanIgnoreReturnValue
public ExportResult.Builder setSampleRate(int sampleRate)

Sets the sample rate.

Must be positive or RATE_UNSET_INT.

setVideoEncoderName

@CanIgnoreReturnValue
public ExportResult.Builder setVideoEncoderName(@Nullable String videoEncoderName)

Sets the name of the video encoder used.

setVideoFrameCount

@CanIgnoreReturnValue
public ExportResult.Builder setVideoFrameCount(int videoFrameCount)

Sets the number of video frames.

Must be positive or 0.

setWidth

@CanIgnoreReturnValue
public ExportResult.Builder setWidth(int width)

Sets the width.

Must be positive or LENGTH_UNSET.