toChannelType method
Implementation
ChannelType toChannelType() {
switch (this) {
case 'PUSH':
return ChannelType.push;
case 'GCM':
return ChannelType.gcm;
case 'APNS':
return ChannelType.apns;
case 'APNS_SANDBOX':
return ChannelType.apnsSandbox;
case 'APNS_VOIP':
return ChannelType.apnsVoip;
case 'APNS_VOIP_SANDBOX':
return ChannelType.apnsVoipSandbox;
case 'ADM':
return ChannelType.adm;
case 'SMS':
return ChannelType.sms;
case 'VOICE':
return ChannelType.voice;
case 'EMAIL':
return ChannelType.email;
case 'BAIDU':
return ChannelType.baidu;
case 'CUSTOM':
return ChannelType.custom;
}
throw Exception('$this is not known in enum ChannelType');
}