yield static method
Gets the message queue assigned to a channel id. Will create a new empty message queue if non existing is present and assign it to the channel id.
Implementation
static MessageQueue yield(String channelId) {
MessageQueue? existingMessageQueue = messageQueueByChannelId[channelId];
if ( existingMessageQueue != null ) {
return existingMessageQueue;
} else {
MessageQueue messageQueue = MessageQueue();
messageQueueByChannelId[channelId] = messageQueue;
return messageQueue;
}
}