copyWith method

Consumer copyWith({
  1. String? id,
  2. String? localId,
  3. String? producerId,
  4. bool? closed,
  5. RTCRtpReceiver? rtpReceiver,
  6. MediaStreamTrack? track,
  7. RtpParameters? rtpParameters,
  8. bool? paused,
  9. Map<String, dynamic>? appData,
  10. MediaStream? stream,
  11. EnhancedEventEmitter? observer,
  12. String? peerId,
})

Implementation

Consumer copyWith({
  String? id,
  String? localId,
  String? producerId,
  bool? closed,
  RTCRtpReceiver? rtpReceiver,
  MediaStreamTrack? track,
  RtpParameters? rtpParameters,
  bool? paused,
  Map<String, dynamic>? appData,
  MediaStream? stream,
  EnhancedEventEmitter? observer,
  String? peerId,
}) {
  return Consumer._copy(
    id: id ?? this.id,
    localId: localId ?? this.localId,
    producerId: producerId ?? this.producerId,
    closed: closed ?? this.closed,
    rtpReceiver: rtpReceiver ?? this.rtpReceiver,
    track: track ?? this.track,
    rtpParameters: rtpParameters ?? this.rtpParameters,
    paused: paused ?? this.paused,
    appData: appData ?? this.appData,
    stream: stream ?? this.stream,
    observer: observer ?? this.observer,
    peerId: peerId ?? this.peerId,
  );
}