Class MediaInspectionServiceRemoteImpl

java.lang.Object
org.opencastproject.serviceregistry.api.RemoteBase
org.opencastproject.inspection.remote.MediaInspectionServiceRemoteImpl
All Implemented Interfaces:
MediaInspectionService

public class MediaInspectionServiceRemoteImpl extends RemoteBase implements MediaInspectionService
Proxies a remote media inspection service for use as a JVM-local service.
  • Constructor Details

    • MediaInspectionServiceRemoteImpl

      public MediaInspectionServiceRemoteImpl()
      Constructs a new remote media inspection service proxy
  • Method Details

    • setTrustedHttpClient

      public void setTrustedHttpClient(TrustedHttpClient client)
      Sets the trusted http client
      Overrides:
      setTrustedHttpClient in class RemoteBase
      Parameters:
      client -
    • setRemoteServiceManager

      public void setRemoteServiceManager(ServiceRegistry remoteServiceManager)
      Sets the remote service manager.
      Overrides:
      setRemoteServiceManager in class RemoteBase
      Parameters:
      remoteServiceManager -
    • inspect

      public Job inspect(URI uri) throws MediaInspectionException
      Inspect a track based on a given uri to the track and put the gathered data into the track
      Specified by:
      inspect in interface MediaInspectionService
      Parameters:
      uri - the uri to a track in a media package
      Returns:
      the receipt of this job, that can be used to check the current status of inspect method and retrieve track with added metadata when done
      Throws:
      MediaInspectionException - if there is a failure during media package update
      See Also:
    • inspect

      public Job inspect(URI uri, Map<String,String> options) throws MediaInspectionException
      Inspect a track based on a given uri to the track and put the gathered data into the track
      Specified by:
      inspect in interface MediaInspectionService
      Parameters:
      uri - the uri to a track in a media package
      options - Options in form of key/value pairs that are passed to the Media Inspection Service implementation. Those options may be implementation specific. The implementation is supposed to raise an exception in case unsupported options are encountered. Value may not be null.
      Returns:
      the receipt of this job, that can be used to check the current status of inspect method and retrieve track with added metadata when done
      Throws:
      MediaInspectionException - if there is a failure during media package update
      See Also:
    • enrich

      public Job enrich(MediaPackageElement original, boolean override) throws MediaInspectionException
      Equip an existing media package element with automatically generated metadata
      Specified by:
      enrich in interface MediaInspectionService
      Parameters:
      original - The original media package element that will be inspected
      override - In case of conflict between existing and automatically obtained metadata this switch selects preference. False..The original metadata will be kept, True..The new metadata will be used.
      Returns:
      the receipt of this job, that can be used to check the current status of enrich method and retrieve enriched element when done
      Throws:
      MediaInspectionException - if there is a failure during media package update
    • enrich

      public Job enrich(MediaPackageElement original, boolean override, Map<String,String> options) throws MediaInspectionException
      Equip an existing media package element with automatically generated metadata
      Specified by:
      enrich in interface MediaInspectionService
      Parameters:
      original - The original media package element that will be inspected
      override - In case of conflict between existing and automatically obtained metadata this switch selects preference. False..The original metadata will be kept, True..The new metadata will be used.
      options - Options in form of key/value pairs that are passed to the MediaInspectionService implementation. Those options may be implementation specific. The implementation is supposed to raise an exception in case unsupported options are encountered. Value may not be null.
      Returns:
      the receipt of this job, that can be used to check the current status of enrich method and retrieve enriched element when done
      Throws:
      MediaInspectionException - if there is a failure during media package update