toOperationType method

OperationType toOperationType()

Implementation

OperationType toOperationType() {
  switch (this) {
    case 'REGISTER_DOMAIN':
      return OperationType.registerDomain;
    case 'DELETE_DOMAIN':
      return OperationType.deleteDomain;
    case 'TRANSFER_IN_DOMAIN':
      return OperationType.transferInDomain;
    case 'UPDATE_DOMAIN_CONTACT':
      return OperationType.updateDomainContact;
    case 'UPDATE_NAMESERVER':
      return OperationType.updateNameserver;
    case 'CHANGE_PRIVACY_PROTECTION':
      return OperationType.changePrivacyProtection;
    case 'DOMAIN_LOCK':
      return OperationType.domainLock;
    case 'ENABLE_AUTORENEW':
      return OperationType.enableAutorenew;
    case 'DISABLE_AUTORENEW':
      return OperationType.disableAutorenew;
    case 'ADD_DNSSEC':
      return OperationType.addDnssec;
    case 'REMOVE_DNSSEC':
      return OperationType.removeDnssec;
    case 'EXPIRE_DOMAIN':
      return OperationType.expireDomain;
    case 'TRANSFER_OUT_DOMAIN':
      return OperationType.transferOutDomain;
    case 'CHANGE_DOMAIN_OWNER':
      return OperationType.changeDomainOwner;
    case 'RENEW_DOMAIN':
      return OperationType.renewDomain;
    case 'PUSH_DOMAIN':
      return OperationType.pushDomain;
    case 'INTERNAL_TRANSFER_OUT_DOMAIN':
      return OperationType.internalTransferOutDomain;
    case 'INTERNAL_TRANSFER_IN_DOMAIN':
      return OperationType.internalTransferInDomain;
  }
  throw Exception('$this is not known in enum OperationType');
}