registerExtension abstract method

Future<void> registerExtension({
  1. required String provider,
  2. required String extension,
  3. MediaSourceType type = MediaSourceType.unknownMediaSource,
})

Registers an extension.

For external SDK extensions (such as marketplace or SDK extension plugins), after loading the extension, you need to call this method to register it. Internal SDK extensions (those included in the SDK package) are automatically loaded and registered after initializing RtcEngine, so you do not need to call this method. To register multiple extensions, call this method multiple times. The order in which different extensions process data in the SDK is determined by the registration order. That is, extensions registered earlier process data first.

  • provider The name of the extension provider.
  • extension The name of the extension.
  • type The media source type of the extension. See MediaSourceType.

Returns When the method call succeeds, there is no return value; when fails, the AgoraRtcException exception is thrown. You need to catch the exception and handle it accordingly. See Error Codes for details and resolution suggestions.

Implementation

Future<void> registerExtension(
    {required String provider,
    required String extension,
    MediaSourceType type = MediaSourceType.unknownMediaSource});