convertToProposedName static method
Implementation
static String convertToProposedName(String currentEventName) {
switch (currentEventName) {
case 'message':
return ProposedEventNames.Message;
case 'request':
return ProposedEventNames.Request;
case 'accept':
return ProposedEventNames.Accept;
case 'reject':
return ProposedEventNames.Reject;
case 'leaveGroup':
return ProposedEventNames.LeaveGroup;
case 'joinGroup':
return ProposedEventNames.JoinGroup;
case 'createGroup':
return ProposedEventNames.CreateGroup;
case 'updateGroup':
return ProposedEventNames.UpdateGroup;
case 'remove':
return ProposedEventNames.Remove;
default:
throw Exception('Unknown current event name: $currentEventName');
}
}