createDataStream abstract method

Future<int> createDataStream(
  1. DataStreamConfig config
)

Creates a data stream.

If you need a more comprehensive, low-latency, high-concurrency, and scalable real-time messaging and state synchronization solution, we recommend using Real-time Messaging. During the lifecycle of RtcEngine, each user can create up to 5 data streams. The data streams are destroyed when leaving the channel. If needed again, you must recreate them.

  • config Data stream configuration. See DataStreamConfig.

Returns ID of the created data stream: method call succeeded. < 0: method call failed. See Error Codes for details and resolution suggestions.

Implementation

Future<int> createDataStream(DataStreamConfig config);