Interface Codec


public interface Codec
Represents a codec used in media processing, encapsulating its name and parameters.

Implementations of this interface provide access to the codec's name and its associated parameters. The codec's name typically identifies the type of codec (e.g., H.264, Opus), while its parameters contain specific configuration details required for the codec's operation.

Example usage:


 Codec codec = new CodecImpl.Builder()
     .name(codecName)
     .parameters(codecParams)
     .build();
 

Replace codecName and codecParams with your desired values or objects implementing CodecParameters.

Author:
Copyright (c) 2025 by Oracle, Inc. All Rights Reserved.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static interface 
    Builder interface for creating immutable Codec instances.
  • Method Summary

    Modifier and Type
    Method
    Description
    Gets the name of the codec.
    Gets the parameters associated with the codec.
    void
    Sets the name of the codec.
    void
    Sets the parameters associated with the codec.
  • Method Details

    • getName

      String getName()
      Gets the name of the codec.
      Returns:
      the name of the codec.
    • setName

      void setName(String name)
      Sets the name of the codec.
      Parameters:
      name - the name of the codec.
    • getParameters

      CodecParameters getParameters()
      Gets the parameters associated with the codec.
      Returns:
      the codec parameters.
    • setParameters

      void setParameters(CodecParameters parameters)
      Sets the parameters associated with the codec.
      Parameters:
      parameters - the codec parameters.