Sample constructor

Sample({
  1. required String keyExpr,
  2. required String payload,
  3. required Uint8List payloadBytes,
  4. required SampleKind kind,
  5. String? attachment,
  6. Uint8List? attachmentBytes,
  7. String? encoding,
  8. Uint8List? encodingBytes,
  9. Timestamp? timestamp,
  10. Priority priority = Priority.data,
  11. CongestionControl congestionControl = CongestionControl.drop,
  12. bool express = false,
  13. ZBytes? payloadZBytes,
})

Creates a Sample with the given fields.

Implementation

Sample({
  required this.keyExpr,
  required this.payload,
  required this.payloadBytes,
  required this.kind,
  this.attachment,
  this.attachmentBytes,
  this.encoding,
  this.encodingBytes,
  this.timestamp,
  this.priority = Priority.data,
  this.congestionControl = CongestionControl.drop,
  this.express = false,
  this.payloadZBytes,
});