Class MediaInspector

java.lang.Object
org.opencastproject.inspection.ffmpeg.MediaInspector

public class MediaInspector extends Object
Contains the business logic for media inspection. Its primary purpose is to decouple the inspection logic from all OSGi/MH job management boilerplate.
  • Constructor Summary

    Constructors
    Constructor
    Description
    MediaInspector(org.opencastproject.workspace.api.Workspace workspace, String ffprobePath)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    org.opencastproject.mediapackage.MediaPackageElement
    enrich(org.opencastproject.mediapackage.MediaPackageElement element, boolean override, Map<String,String> options)
    Enriches the given element's mediapackage.
    org.opencastproject.mediapackage.Track
    inspectTrack(URI trackURI, Map<String,String> options)
    Inspects the element that is passed in as uri.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • MediaInspector

      public MediaInspector(org.opencastproject.workspace.api.Workspace workspace, String ffprobePath)
  • Method Details

    • inspectTrack

      public org.opencastproject.mediapackage.Track inspectTrack(URI trackURI, Map<String,String> options) throws org.opencastproject.inspection.api.MediaInspectionException
      Inspects the element that is passed in as uri.
      Parameters:
      trackURI - the element uri
      Returns:
      the inspected track
      Throws:
      org.opencastproject.inspection.api.MediaInspectionException - if inspection fails
    • enrich

      public org.opencastproject.mediapackage.MediaPackageElement enrich(org.opencastproject.mediapackage.MediaPackageElement element, boolean override, Map<String,String> options) throws org.opencastproject.inspection.api.MediaInspectionException
      Enriches the given element's mediapackage.
      Parameters:
      element - the element to enrich
      override - true to override existing metadata
      Returns:
      the enriched element
      Throws:
      org.opencastproject.inspection.api.MediaInspectionException - if enriching fails