*
* @throws ConverterException in case conversion fails.
*/
private TranscodingJobSource getTranscodingJobSource()
throws ConverterException {
TranscodingJobSource transcodingJobSource = new TranscodingJobSource();
// Retrieve location of the resource to transcode.
String location = getParameterValue(ParameterNames.SOURCE_URL);
if (location == null) {
throw new ConverterException("missing-source-url", new Object[] {},
null);
}
transcodingJobSource.setLocation(location);
// Retrieve MIME type of the resource to transcode.
transcodingJobSource.setContentType(contentType);
return transcodingJobSource;
}