streamPublished property

  1. @Deprecated('Please use rtmpStreamingStateChanged instead.')
UrlWithErrorCallback? streamPublished
getter/setter pair

Occurs when an RTMP or RTMPS stream is published. Deprecated: Please use rtmpStreamingStateChanged instead. Reports the result of publishing an RTMP or RTMPS stream.

Param url The CDN streaming URL.

Param error Error codes of the RTMP or RTMPS streaming. ERR_OK (0): The publishing succeeds. ERR_FAILED (1): The publishing fails. ERR_INVALID_ARGUMENT (-2): Invalid argument used. If you do not call setLiveTranscoding to configure LiveTranscoding before calling addPublishStreamUrl , the SDK reports ERR_INVALID_ARGUMENT. ERR_TIMEDOUT (10): The publishing timed out. ERR_ALREADY_IN_USE (19): The chosen URL address is already in use for CDN live streaming. ERR_ENCRYPTED_STREAM_NOT_ALLOWED_PUBLISH (130): You cannot publish an encrypted stream. ERR_PUBLISH_STREAM_CDN_ERROR (151): CDN related error. Remove the original URL address and add a new one by calling the removePublishStreamUrl and addPublishStreamUrl methods. ERR_PUBLISH_STREAM_NUM_REACH_LIMIT (152): The host manipulates more than 10 URLs. Delete the unnecessary URLs before adding new ones. ERR_PUBLISH_STREAM_NOT_AUTHORIZED (153): The host manipulates other hosts' URLs. Please check your app logic. ERR_PUBLISH_STREAM_INTERNAL_SERVER_ERROR (154): An error occurs in Agora's streaming server. Call the removePublishStreamUrl method to publish the streaming again. ERR_PUBLISH_STREAM_FORMAT_NOT_SUPPORTED (156): The format of the CDN streaming URL is not supported. Check whether the URL format is correct.

Implementation

@Deprecated('Please use rtmpStreamingStateChanged instead.')
UrlWithErrorCallback? streamPublished;