OutboundOperation class
An outbound operation to be sent to the server.
Constructors
- OutboundOperation({required String id, required OutboundOperationType type, required String data, int retryCount = 0, OutboundOperationStatus status = OutboundOperationStatus.pending, DateTime? createdAt, DateTime? processedAt, String? errorMessage})
- Creates an outbound operation.
Properties
- createdAt → DateTime
-
When operation was created.
final
- data → String
-
Operation data (JSON string).
final
- errorMessage → String?
-
Error message if failed.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → String
-
Unique ID for this operation.
final
- processedAt → DateTime?
-
When operation was processed.
final
- retryCount → int
-
Number of retry attempts.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- status → OutboundOperationStatus
-
Current status.
final
- type → OutboundOperationType
-
Type of operation.
final
Methods
-
copyWith(
{String? id, OutboundOperationType? type, String? data, int? retryCount, OutboundOperationStatus? status, DateTime? createdAt, DateTime? processedAt, String? errorMessage}) → OutboundOperation - Creates a copy with updated fields.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
addReaction(
String messageId, String emoji) → OutboundOperation - Helper to create an add reaction operation.
-
archiveConversation(
String conversationId) → OutboundOperation - Helper to create an archive conversation operation.
-
deleteConversation(
String conversationId) → OutboundOperation - Helper to create a delete conversation operation.
-
markRead(
String conversationId, String messageId) → OutboundOperation - Helper to create a mark read operation.
-
pinMessage(
String conversationId, String messageId, Duration? duration) → OutboundOperation - Helper to create a pin message operation.
-
removeReaction(
String messageId, String reactionId) → OutboundOperation - Helper to create a remove reaction operation.
-
sendMessage(
{required String messageId, required String conversationId, required String content, MessageType? type, String? replyToId, List< PendingAttachment> ? attachments, String? nonce, Map<String, dynamic> ? extra}) → OutboundOperation - Helper to create a send message operation.
-
starMessage(
String roomId, String messageId) → OutboundOperation - Helper to create a star message operation.
-
unarchiveConversation(
String conversationId) → OutboundOperation - Helper to create an unarchive conversation operation.
-
unpinMessage(
String conversationId, String messageId) → OutboundOperation - Helper to create an unpin message operation.
-
unstarMessage(
String messageId) → OutboundOperation - Helper to create an unstar message operation.