// ignore_for_file: non_constant_identifier_names, camel_case_types, missing_return, unused_import, unused_local_variable, dead_code, unnecessary_cast
//////////////////////////////////////////////////////////
// GENERATED BY FLUTTIFY. DO NOT EDIT IT.
//////////////////////////////////////////////////////////

enum TXEAVRoomAuthBits {
  AVROOM_AUTH_BITS_DEFAULT /* -1 */,
  AVROOM_AUTH_BITS_CREATE_ROOM /* 0x00000001 */,
  AVROOM_AUTH_BITS_JOIN_ROOM /* 0x00000002 */,
  AVROOM_AUTH_BITS_SEND_AUDIO /* 0x00000004 */,
  AVROOM_AUTH_BITS_RECV_AUDIO /* 0x00000008 */,
  AVROOM_AUTH_BITS_SEND_CAMERA_VIDEO /* 0x00000010 */,
  AVROOM_AUTH_BITS_RECV_CAMERA_VIDEO /* 0x00000020 */,
  AVROOM_AUTH_BITS_SEND_SCREEN_VIDEO /* 0x00000040 */,
  AVROOM_AUTH_BITS_RECV_SCREEN_VIDEO /* 0x00000080 */
}

extension TXEAVRoomAuthBitsToX on TXEAVRoomAuthBits {
  int toValue() {
    switch (this) {
      case TXEAVRoomAuthBits.AVROOM_AUTH_BITS_DEFAULT: return -1;
      case TXEAVRoomAuthBits.AVROOM_AUTH_BITS_CREATE_ROOM: return 0x00000001;
      case TXEAVRoomAuthBits.AVROOM_AUTH_BITS_JOIN_ROOM: return 0x00000002;
      case TXEAVRoomAuthBits.AVROOM_AUTH_BITS_SEND_AUDIO: return 0x00000004;
      case TXEAVRoomAuthBits.AVROOM_AUTH_BITS_RECV_AUDIO: return 0x00000008;
      case TXEAVRoomAuthBits.AVROOM_AUTH_BITS_SEND_CAMERA_VIDEO: return 0x00000010;
      case TXEAVRoomAuthBits.AVROOM_AUTH_BITS_RECV_CAMERA_VIDEO: return 0x00000020;
      case TXEAVRoomAuthBits.AVROOM_AUTH_BITS_SEND_SCREEN_VIDEO: return 0x00000040;
      case TXEAVRoomAuthBits.AVROOM_AUTH_BITS_RECV_SCREEN_VIDEO: return 0x00000080;
      default: return 0;
    }
  }
}

extension TXEAVRoomAuthBitsFromX on int {
  TXEAVRoomAuthBits toTXEAVRoomAuthBits() {
    switch (this) {
      case -1: return TXEAVRoomAuthBits.AVROOM_AUTH_BITS_DEFAULT;
      case 0x00000001: return TXEAVRoomAuthBits.AVROOM_AUTH_BITS_CREATE_ROOM;
      case 0x00000002: return TXEAVRoomAuthBits.AVROOM_AUTH_BITS_JOIN_ROOM;
      case 0x00000004: return TXEAVRoomAuthBits.AVROOM_AUTH_BITS_SEND_AUDIO;
      case 0x00000008: return TXEAVRoomAuthBits.AVROOM_AUTH_BITS_RECV_AUDIO;
      case 0x00000010: return TXEAVRoomAuthBits.AVROOM_AUTH_BITS_SEND_CAMERA_VIDEO;
      case 0x00000020: return TXEAVRoomAuthBits.AVROOM_AUTH_BITS_RECV_CAMERA_VIDEO;
      case 0x00000040: return TXEAVRoomAuthBits.AVROOM_AUTH_BITS_SEND_SCREEN_VIDEO;
      case 0x00000080: return TXEAVRoomAuthBits.AVROOM_AUTH_BITS_RECV_SCREEN_VIDEO;
      default: return TXEAVRoomAuthBits.values[this + -1];
    }
  }
}