// Generated by the protocol buffer compiler.  DO NOT EDIT!
// clang-format off
// source: keyapis/subscription/v1/keyapis_subscription_offer_template_v1.proto

// This CPP symbol can be defined to use imports that match up to the framework
// imports needed when using CocoaPods.
#if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS)
 #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0
#endif

#if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS
 #import <Protobuf/GPBProtocolBuffers_RuntimeSupport.h>
#else
 #import "GPBProtocolBuffers_RuntimeSupport.h"
#endif

#if GOOGLE_PROTOBUF_OBJC_VERSION < 30007
#error This file was generated by a newer version of protoc which is incompatible with your Protocol Buffer library sources.
#endif
#if 30007 < GOOGLE_PROTOBUF_OBJC_MIN_SUPPORTED_VERSION
#error This file was generated by an older version of protoc which is incompatible with your Protocol Buffer library sources.
#endif

#import <stdatomic.h>

#import "keyapis/subscription/v1/KeyapisSubscriptionOfferTemplateV1.pbobjc.h"
#import "google/api/Annotations.pbobjc.h"
#import "google/api/FieldBehavior.pbobjc.h"
#import "google/protobuf/Descriptor.pbobjc.h"
#import "keyapis/subscription/v1/KeyapisSubscriptionOfferV1.pbobjc.h"
// @@protoc_insertion_point(imports)

#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
#pragma clang diagnostic ignored "-Wdirect-ivar-access"
#pragma clang diagnostic ignored "-Wdollar-in-identifier-extension"

#pragma mark - Objective-C Class declarations
// Forward declarations of Objective-C classes that we can use as
// static values in struct initializers.
// We don't use [Foo class] because it is not a static value.
GPBObjCClassDeclaration(GPBBoolValue);
GPBObjCClassDeclaration(GPBStringValue);
GPBObjCClassDeclaration(GPBTimestamp);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateRequest);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateResponse);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountRequest);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListRequest);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountRequest);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateRequest);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1GetOfferTemplateResponse);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1OfferTemplate);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1OfferTemplate_Item);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_Conflict);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_DuplicateTemplate);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRequest);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreRequest);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreResponse);
GPBObjCClassDeclaration(KEYAPISSUBSCRIPTIONV1ValidationError);

#pragma mark - KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root

@implementation KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root

+ (GPBExtensionRegistry*)extensionRegistry {
  // This is called by +initialize so there is no need to worry
  // about thread safety and initialization of registry.
  static GPBExtensionRegistry* registry = nil;
  if (!registry) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    registry = [[GPBExtensionRegistry alloc] init];
    // Merge in the imports (direct or indirect) that defined extensions.
    [registry addExtensions:[GAPIAnnotationsRoot extensionRegistry]];
    [registry addExtensions:[GAPIFieldBehaviorRoot extensionRegistry]];
  }
  return registry;
}

@end

static GPBFileDescription KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription = {
  .package = "keyapis.subscription.v1",
  .prefix = "KEYAPISSUBSCRIPTIONV1",
  .syntax = GPBFileSyntaxProto3
};

#pragma mark - Enum KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType

GPBEnumDescriptor *KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_EnumDescriptor(void) {
  static _Atomic(GPBEnumDescriptor*) descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static const char *valueNames =
        "ServiceTypeUnknown\000Intercom\000Cameras\000Tele"
        "metry\000AccessControlPanel\000Barrier\000";
    static const int32_t values[] = {
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_ServiceTypeUnknown,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_Intercom,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_Cameras,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_Telemetry,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_AccessControlPanel,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_Barrier,
    };
    GPBEnumDescriptor *worker =
        [GPBEnumDescriptor allocDescriptorForName:GPBNSStringifySymbol(KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType)
                                       valueNames:valueNames
                                           values:values
                                            count:(uint32_t)(sizeof(values) / sizeof(int32_t))
                                     enumVerifier:KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_IsValidValue
                                            flags:GPBEnumDescriptorInitializationFlag_None];
    GPBEnumDescriptor *expected = nil;
    if (!atomic_compare_exchange_strong(&descriptor, &expected, worker)) {
      [worker release];
    }
  }
  return descriptor;
}

BOOL KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_IsValidValue(int32_t value__) {
  switch (value__) {
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_ServiceTypeUnknown:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_Intercom:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_Cameras:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_Telemetry:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_AccessControlPanel:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_Barrier:
      return YES;
    default:
      return NO;
  }
}

#pragma mark - Enum KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType

GPBEnumDescriptor *KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_EnumDescriptor(void) {
  static _Atomic(GPBEnumDescriptor*) descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static const char *valueNames =
        "StatusTypeUnknown\000Active\000Archived\000";
    static const int32_t values[] = {
        KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_StatusTypeUnknown,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_Active,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_Archived,
    };
    GPBEnumDescriptor *worker =
        [GPBEnumDescriptor allocDescriptorForName:GPBNSStringifySymbol(KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType)
                                       valueNames:valueNames
                                           values:values
                                            count:(uint32_t)(sizeof(values) / sizeof(int32_t))
                                     enumVerifier:KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_IsValidValue
                                            flags:GPBEnumDescriptorInitializationFlag_None];
    GPBEnumDescriptor *expected = nil;
    if (!atomic_compare_exchange_strong(&descriptor, &expected, worker)) {
      [worker release];
    }
  }
  return descriptor;
}

BOOL KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_IsValidValue(int32_t value__) {
  switch (value__) {
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_StatusTypeUnknown:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_Active:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_Archived:
      return YES;
    default:
      return NO;
  }
}

#pragma mark - Enum KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType

GPBEnumDescriptor *KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_EnumDescriptor(void) {
  static _Atomic(GPBEnumDescriptor*) descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static const char *valueNames =
        "ContractTypeUnknown\000B2B\000B2C\000B2B2C\000";
    static const int32_t values[] = {
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_ContractTypeUnknown,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_B2B,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_B2C,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_B2B2C,
    };
    static const char *extraTextFormatInfo = "\003\001\003\000\002\003\000\003\005\000";
    GPBEnumDescriptor *worker =
        [GPBEnumDescriptor allocDescriptorForName:GPBNSStringifySymbol(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType)
                                       valueNames:valueNames
                                           values:values
                                            count:(uint32_t)(sizeof(values) / sizeof(int32_t))
                                     enumVerifier:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_IsValidValue
                                            flags:GPBEnumDescriptorInitializationFlag_None
                              extraTextFormatInfo:extraTextFormatInfo];
    GPBEnumDescriptor *expected = nil;
    if (!atomic_compare_exchange_strong(&descriptor, &expected, worker)) {
      [worker release];
    }
  }
  return descriptor;
}

BOOL KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_IsValidValue(int32_t value__) {
  switch (value__) {
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_ContractTypeUnknown:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_B2B:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_B2C:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_B2B2C:
      return YES;
    default:
      return NO;
  }
}

#pragma mark - Enum KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType

GPBEnumDescriptor *KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_EnumDescriptor(void) {
  static _Atomic(GPBEnumDescriptor*) descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static const char *valueNames =
        "ClientTypeUnknown\000ManagementCompany\000Inte"
        "rcomCompany\000";
    static const int32_t values[] = {
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_ClientTypeUnknown,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_ManagementCompany,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_IntercomCompany,
    };
    GPBEnumDescriptor *worker =
        [GPBEnumDescriptor allocDescriptorForName:GPBNSStringifySymbol(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType)
                                       valueNames:valueNames
                                           values:values
                                            count:(uint32_t)(sizeof(values) / sizeof(int32_t))
                                     enumVerifier:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_IsValidValue
                                            flags:GPBEnumDescriptorInitializationFlag_None];
    GPBEnumDescriptor *expected = nil;
    if (!atomic_compare_exchange_strong(&descriptor, &expected, worker)) {
      [worker release];
    }
  }
  return descriptor;
}

BOOL KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_IsValidValue(int32_t value__) {
  switch (value__) {
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_ClientTypeUnknown:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_ManagementCompany:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_IntercomCompany:
      return YES;
    default:
      return NO;
  }
}

#pragma mark - Enum KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType

GPBEnumDescriptor *KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_EnumDescriptor(void) {
  static _Atomic(GPBEnumDescriptor*) descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static const char *valueNames =
        "BillingSystemTypeUnknown\000AsrMrf\000KeyPlatf"
        "orm\000";
    static const int32_t values[] = {
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_BillingSystemTypeUnknown,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_AsrMrf,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_KeyPlatform,
    };
    GPBEnumDescriptor *worker =
        [GPBEnumDescriptor allocDescriptorForName:GPBNSStringifySymbol(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType)
                                       valueNames:valueNames
                                           values:values
                                            count:(uint32_t)(sizeof(values) / sizeof(int32_t))
                                     enumVerifier:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_IsValidValue
                                            flags:GPBEnumDescriptorInitializationFlag_None];
    GPBEnumDescriptor *expected = nil;
    if (!atomic_compare_exchange_strong(&descriptor, &expected, worker)) {
      [worker release];
    }
  }
  return descriptor;
}

BOOL KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_IsValidValue(int32_t value__) {
  switch (value__) {
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_BillingSystemTypeUnknown:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_AsrMrf:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_KeyPlatform:
      return YES;
    default:
      return NO;
  }
}

#pragma mark - Enum KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType

GPBEnumDescriptor *KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_EnumDescriptor(void) {
  static _Atomic(GPBEnumDescriptor*) descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static const char *valueNames =
        "RoomDeviceContractTypeUnknown\000RoomDevice"
        "B2B\000RoomDeviceB2C\000";
    static const int32_t values[] = {
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_RoomDeviceContractTypeUnknown,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_RoomDeviceB2B,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_RoomDeviceB2C,
    };
    static const char *extraTextFormatInfo = "\002\001d\346\203\000\002d\346\203\000";
    GPBEnumDescriptor *worker =
        [GPBEnumDescriptor allocDescriptorForName:GPBNSStringifySymbol(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType)
                                       valueNames:valueNames
                                           values:values
                                            count:(uint32_t)(sizeof(values) / sizeof(int32_t))
                                     enumVerifier:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_IsValidValue
                                            flags:GPBEnumDescriptorInitializationFlag_None
                              extraTextFormatInfo:extraTextFormatInfo];
    GPBEnumDescriptor *expected = nil;
    if (!atomic_compare_exchange_strong(&descriptor, &expected, worker)) {
      [worker release];
    }
  }
  return descriptor;
}

BOOL KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_IsValidValue(int32_t value__) {
  switch (value__) {
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_RoomDeviceContractTypeUnknown:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_RoomDeviceB2B:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_RoomDeviceB2C:
      return YES;
    default:
      return NO;
  }
}

#pragma mark - Enum KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType

GPBEnumDescriptor *KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_EnumDescriptor(void) {
  static _Atomic(GPBEnumDescriptor*) descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static const char *valueNames =
        "MobileAppPackageTypeUnknown\000OpenDoorAndK"
        "eys\000OpenDoorAndKeysAudioCalls\000OpenDoorAn"
        "dKeysVideoCalls\000";
    static const int32_t values[] = {
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_MobileAppPackageTypeUnknown,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_OpenDoorAndKeys,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_OpenDoorAndKeysAudioCalls,
        KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_OpenDoorAndKeysVideoCalls,
    };
    GPBEnumDescriptor *worker =
        [GPBEnumDescriptor allocDescriptorForName:GPBNSStringifySymbol(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType)
                                       valueNames:valueNames
                                           values:values
                                            count:(uint32_t)(sizeof(values) / sizeof(int32_t))
                                     enumVerifier:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_IsValidValue
                                            flags:GPBEnumDescriptorInitializationFlag_None];
    GPBEnumDescriptor *expected = nil;
    if (!atomic_compare_exchange_strong(&descriptor, &expected, worker)) {
      [worker release];
    }
  }
  return descriptor;
}

BOOL KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_IsValidValue(int32_t value__) {
  switch (value__) {
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_MobileAppPackageTypeUnknown:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_OpenDoorAndKeys:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_OpenDoorAndKeysAudioCalls:
    case KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_OpenDoorAndKeysVideoCalls:
      return YES;
    default:
      return NO;
  }
}

#pragma mark - Enum KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType

GPBEnumDescriptor *KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType_EnumDescriptor(void) {
  static _Atomic(GPBEnumDescriptor*) descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static const char *valueNames =
        "OrderByTypeUnknown\000CreatedAt\000Title\000";
    static const int32_t values[] = {
        KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType_OrderByTypeUnknown,
        KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType_CreatedAt,
        KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType_Title,
    };
    GPBEnumDescriptor *worker =
        [GPBEnumDescriptor allocDescriptorForName:GPBNSStringifySymbol(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType)
                                       valueNames:valueNames
                                           values:values
                                            count:(uint32_t)(sizeof(values) / sizeof(int32_t))
                                     enumVerifier:KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType_IsValidValue
                                            flags:GPBEnumDescriptorInitializationFlag_None];
    GPBEnumDescriptor *expected = nil;
    if (!atomic_compare_exchange_strong(&descriptor, &expected, worker)) {
      [worker release];
    }
  }
  return descriptor;
}

BOOL KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType_IsValidValue(int32_t value__) {
  switch (value__) {
    case KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType_OrderByTypeUnknown:
    case KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType_CreatedAt:
    case KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType_Title:
      return YES;
    default:
      return NO;
  }
}

#pragma mark - Enum KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType

GPBEnumDescriptor *KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType_EnumDescriptor(void) {
  static _Atomic(GPBEnumDescriptor*) descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static const char *valueNames =
        "DirectionTypeUnknown\000Desc\000Asc\000";
    static const int32_t values[] = {
        KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType_DirectionTypeUnknown,
        KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType_Desc,
        KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType_Asc,
    };
    GPBEnumDescriptor *worker =
        [GPBEnumDescriptor allocDescriptorForName:GPBNSStringifySymbol(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType)
                                       valueNames:valueNames
                                           values:values
                                            count:(uint32_t)(sizeof(values) / sizeof(int32_t))
                                     enumVerifier:KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType_IsValidValue
                                            flags:GPBEnumDescriptorInitializationFlag_None];
    GPBEnumDescriptor *expected = nil;
    if (!atomic_compare_exchange_strong(&descriptor, &expected, worker)) {
      [worker release];
    }
  }
  return descriptor;
}

BOOL KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType_IsValidValue(int32_t value__) {
  switch (value__) {
    case KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType_DirectionTypeUnknown:
    case KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType_Desc:
    case KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType_Asc:
      return YES;
    default:
      return NO;
  }
}

#pragma mark - KEYAPISSUBSCRIPTIONV1OfferTemplate

@implementation KEYAPISSUBSCRIPTIONV1OfferTemplate

@dynamic id_p;
@dynamic serviceType;
@dynamic title;
@dynamic hasDescription_p, description_p;
@dynamic statusType;
@dynamic hasApplicabilityRules, applicabilityRules;
@dynamic itemsArray, itemsArray_Count;
@dynamic hasCreatedAt, createdAt;
@dynamic hasUpdatedAt, updatedAt;

typedef struct KEYAPISSUBSCRIPTIONV1OfferTemplate__storage_ {
  uint32_t _has_storage_[1];
  KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType serviceType;
  KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType statusType;
  NSString *id_p;
  NSString *title;
  GPBStringValue *description_p;
  KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules *applicabilityRules;
  NSMutableArray *itemsArray;
  GPBTimestamp *createdAt;
  GPBTimestamp *updatedAt;
} KEYAPISSUBSCRIPTIONV1OfferTemplate__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "id_p",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_Id_p,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate__storage_, id_p),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeString,
      },
      {
        .name = "serviceType",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_ServiceType,
        .hasIndex = 1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate__storage_, serviceType),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldHasEnumDescriptor | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "title",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_Title,
        .hasIndex = 2,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate__storage_, title),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeString,
      },
      {
        .name = "description_p",
        .dataTypeSpecific.clazz = GPBObjCClass(GPBStringValue),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_Description_p,
        .hasIndex = 3,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate__storage_, description_p),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "statusType",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_StatusType,
        .hasIndex = 4,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate__storage_, statusType),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldHasEnumDescriptor | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "applicabilityRules",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_ApplicabilityRules,
        .hasIndex = 5,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate__storage_, applicabilityRules),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "itemsArray",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate_Item),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_ItemsArray,
        .hasIndex = GPBNoHasBit,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate__storage_, itemsArray),
        .flags = GPBFieldRepeated,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "createdAt",
        .dataTypeSpecific.clazz = GPBObjCClass(GPBTimestamp),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_CreatedAt,
        .hasIndex = 6,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate__storage_, createdAt),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "updatedAt",
        .dataTypeSpecific.clazz = GPBObjCClass(GPBTimestamp),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_UpdatedAt,
        .hasIndex = 7,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate__storage_, updatedAt),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate)
                                   messageName:@"OfferTemplate"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1OfferTemplate__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

int32_t KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_ServiceType];
  return GPBGetMessageRawEnumField(message, field);
}

void SetKEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate *message, int32_t value) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_ServiceType];
  GPBSetMessageRawEnumField(message, field, value);
}

int32_t KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_StatusType];
  return GPBGetMessageRawEnumField(message, field);
}

void SetKEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate *message, int32_t value) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_FieldNumber_StatusType];
  GPBSetMessageRawEnumField(message, field, value);
}

#pragma mark - KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules

@implementation KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules

@dynamic rfIdsArray, rfIdsArray_Count;
@dynamic contractType;
@dynamic clientType;
@dynamic billingSystemType;
@dynamic isExternalPaymentForSmartIntercom;
@dynamic isCmsPhone;
@dynamic isSipPhone;
@dynamic isVideoMonitor;
@dynamic roomDeviceContractType;
@dynamic mobileAppPackageType;
@dynamic isCallForwardingEnabled;
@dynamic isDigitalWay;

typedef struct KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules__storage_ {
  uint32_t _has_storage_[1];
  KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType contractType;
  KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType clientType;
  KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType billingSystemType;
  KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType roomDeviceContractType;
  KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType mobileAppPackageType;
  GPBInt32Array *rfIdsArray;
} KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "rfIdsArray",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_RfIdsArray,
        .hasIndex = GPBNoHasBit,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules__storage_, rfIdsArray),
        .flags = (GPBFieldFlags)(GPBFieldRepeated | GPBFieldPacked),
        .dataType = GPBDataTypeInt32,
      },
      {
        .name = "contractType",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_ContractType,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules__storage_, contractType),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldHasEnumDescriptor | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "clientType",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_ClientType,
        .hasIndex = 1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules__storage_, clientType),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldHasEnumDescriptor | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "billingSystemType",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_BillingSystemType,
        .hasIndex = 2,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules__storage_, billingSystemType),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldHasEnumDescriptor | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "isExternalPaymentForSmartIntercom",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_IsExternalPaymentForSmartIntercom,
        .hasIndex = 3,
        .offset = 4,  // Stored in _has_storage_ to save space.
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeBool,
      },
      {
        .name = "isCmsPhone",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_IsCmsPhone,
        .hasIndex = 5,
        .offset = 6,  // Stored in _has_storage_ to save space.
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeBool,
      },
      {
        .name = "isSipPhone",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_IsSipPhone,
        .hasIndex = 7,
        .offset = 8,  // Stored in _has_storage_ to save space.
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeBool,
      },
      {
        .name = "isVideoMonitor",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_IsVideoMonitor,
        .hasIndex = 9,
        .offset = 10,  // Stored in _has_storage_ to save space.
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeBool,
      },
      {
        .name = "roomDeviceContractType",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_RoomDeviceContractType,
        .hasIndex = 11,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules__storage_, roomDeviceContractType),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldHasEnumDescriptor | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "mobileAppPackageType",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_MobileAppPackageType,
        .hasIndex = 12,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules__storage_, mobileAppPackageType),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldHasEnumDescriptor | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "isCallForwardingEnabled",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_IsCallForwardingEnabled,
        .hasIndex = 13,
        .offset = 14,  // Stored in _has_storage_ to save space.
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeBool,
      },
      {
        .name = "isDigitalWay",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_IsDigitalWay,
        .hasIndex = 15,
        .offset = 16,  // Stored in _has_storage_ to save space.
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeBool,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules)
                                   messageName:@"ApplicabilityRules"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    [localDescriptor setupContainingMessageClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

int32_t KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_ContractType];
  return GPBGetMessageRawEnumField(message, field);
}

void SetKEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules *message, int32_t value) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_ContractType];
  GPBSetMessageRawEnumField(message, field, value);
}

int32_t KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_ClientType];
  return GPBGetMessageRawEnumField(message, field);
}

void SetKEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules *message, int32_t value) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_ClientType];
  GPBSetMessageRawEnumField(message, field, value);
}

int32_t KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_BillingSystemType];
  return GPBGetMessageRawEnumField(message, field);
}

void SetKEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules *message, int32_t value) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_BillingSystemType];
  GPBSetMessageRawEnumField(message, field, value);
}

int32_t KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_RoomDeviceContractType];
  return GPBGetMessageRawEnumField(message, field);
}

void SetKEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules *message, int32_t value) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_RoomDeviceContractType];
  GPBSetMessageRawEnumField(message, field, value);
}

int32_t KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_MobileAppPackageType];
  return GPBGetMessageRawEnumField(message, field);
}

void SetKEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules *message, int32_t value) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_FieldNumber_MobileAppPackageType];
  GPBSetMessageRawEnumField(message, field, value);
}

#pragma mark - KEYAPISSUBSCRIPTIONV1OfferTemplate_Item

@implementation KEYAPISSUBSCRIPTIONV1OfferTemplate_Item

@dynamic planId;
@dynamic type;
@dynamic isEnableAutoSubscribe;
@dynamic isDigitalWay;
@dynamic hasOfferURL, offerURL;

typedef struct KEYAPISSUBSCRIPTIONV1OfferTemplate_Item__storage_ {
  uint32_t _has_storage_[1];
  int32_t planId;
  KEYAPISSUBSCRIPTIONV1Offer_Type type;
  GPBStringValue *offerURL;
} KEYAPISSUBSCRIPTIONV1OfferTemplate_Item__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "planId",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_Item_FieldNumber_PlanId,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate_Item__storage_, planId),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeInt32,
      },
      {
        .name = "type",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1Offer_Type_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_Item_FieldNumber_Type,
        .hasIndex = 1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate_Item__storage_, type),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldHasEnumDescriptor | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "isEnableAutoSubscribe",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_Item_FieldNumber_IsEnableAutoSubscribe,
        .hasIndex = 2,
        .offset = 3,  // Stored in _has_storage_ to save space.
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeBool,
      },
      {
        .name = "isDigitalWay",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_Item_FieldNumber_IsDigitalWay,
        .hasIndex = 4,
        .offset = 5,  // Stored in _has_storage_ to save space.
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeBool,
      },
      {
        .name = "offerURL",
        .dataTypeSpecific.clazz = GPBObjCClass(GPBStringValue),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_Item_FieldNumber_OfferURL,
        .hasIndex = 6,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate_Item__storage_, offerURL),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldTextFormatNameCustom),
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate_Item)
                                   messageName:@"Item"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1OfferTemplate_Item__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
#if !GPBOBJC_SKIP_MESSAGE_TEXTFORMAT_EXTRAS
    static const char *extraTextFormatInfo =
        "\001\005\005\241!!\000";
    [localDescriptor setupExtraTextInfo:extraTextFormatInfo];
#endif  // !GPBOBJC_SKIP_MESSAGE_TEXTFORMAT_EXTRAS
    [localDescriptor setupContainingMessageClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

int32_t KEYAPISSUBSCRIPTIONV1OfferTemplate_Item_Type_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate_Item *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_Item descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_Item_FieldNumber_Type];
  return GPBGetMessageRawEnumField(message, field);
}

void SetKEYAPISSUBSCRIPTIONV1OfferTemplate_Item_Type_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplate_Item *message, int32_t value) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_Item descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplate_Item_FieldNumber_Type];
  GPBSetMessageRawEnumField(message, field, value);
}

#pragma mark - KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError

@implementation KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError

@dynamic reasonOneOfCase;
@dynamic conflict;
@dynamic duplicateTemplate;

typedef struct KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError__storage_ {
  uint32_t _has_storage_[2];
  KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_Conflict *conflict;
  KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_DuplicateTemplate *duplicateTemplate;
} KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "conflict",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_Conflict),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_FieldNumber_Conflict,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError__storage_, conflict),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "duplicateTemplate",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_DuplicateTemplate),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_FieldNumber_DuplicateTemplate,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError__storage_, duplicateTemplate),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError)
                                   messageName:@"SavingError"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "reason",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    [localDescriptor setupContainingMessageClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_ClearReasonOneOfCase(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_Conflict

@implementation KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_Conflict


typedef struct KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_Conflict__storage_ {
  uint32_t _has_storage_[1];
} KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_Conflict__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_Conflict)
                                   messageName:@"Conflict"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:NULL
                                    fieldCount:0
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_Conflict__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    [localDescriptor setupContainingMessageClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

#pragma mark - KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_DuplicateTemplate

@implementation KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_DuplicateTemplate


typedef struct KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_DuplicateTemplate__storage_ {
  uint32_t _has_storage_[1];
} KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_DuplicateTemplate__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_DuplicateTemplate)
                                   messageName:@"DuplicateTemplate"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:NULL
                                    fieldCount:0
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError_DuplicateTemplate__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    [localDescriptor setupContainingMessageClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

#pragma mark - KEYAPISSUBSCRIPTIONV1OfferTemplateFilter

@implementation KEYAPISSUBSCRIPTIONV1OfferTemplateFilter

@dynamic statusTypesArray, statusTypesArray_Count;
@dynamic serviceTypesArray, serviceTypesArray_Count;
@dynamic rfIdsArray, rfIdsArray_Count;
@dynamic hasText, text;
@dynamic applicabilityRulesContractTypesArray, applicabilityRulesContractTypesArray_Count;
@dynamic applicabilityRulesClientTypesArray, applicabilityRulesClientTypesArray_Count;
@dynamic applicabilityRulesBillingSystemTypesArray, applicabilityRulesBillingSystemTypesArray_Count;
@dynamic hasIsExternalPaymentForSmartIntercom, isExternalPaymentForSmartIntercom;
@dynamic hasApplicabilityRulesIsCmsPhone, applicabilityRulesIsCmsPhone;
@dynamic hasApplicabilityRulesIsSipPhone, applicabilityRulesIsSipPhone;
@dynamic hasApplicabilityRulesIsVideoMonitor, applicabilityRulesIsVideoMonitor;
@dynamic applicabilityRulesRoomDeviceContractTypesArray, applicabilityRulesRoomDeviceContractTypesArray_Count;
@dynamic applicabilityRulesMobileAppPackageTypesArray, applicabilityRulesMobileAppPackageTypesArray_Count;
@dynamic hasIsCallForwardingEnabled, isCallForwardingEnabled;
@dynamic hasIsDigitalWay, isDigitalWay;
@dynamic planIdsArray, planIdsArray_Count;

typedef struct KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_ {
  uint32_t _has_storage_[1];
  GPBEnumArray *statusTypesArray;
  GPBEnumArray *serviceTypesArray;
  GPBInt32Array *rfIdsArray;
  GPBStringValue *text;
  GPBEnumArray *applicabilityRulesContractTypesArray;
  GPBEnumArray *applicabilityRulesClientTypesArray;
  GPBEnumArray *applicabilityRulesBillingSystemTypesArray;
  GPBBoolValue *isExternalPaymentForSmartIntercom;
  GPBBoolValue *applicabilityRulesIsCmsPhone;
  GPBBoolValue *applicabilityRulesIsSipPhone;
  GPBBoolValue *applicabilityRulesIsVideoMonitor;
  GPBEnumArray *applicabilityRulesRoomDeviceContractTypesArray;
  GPBEnumArray *applicabilityRulesMobileAppPackageTypesArray;
  GPBBoolValue *isCallForwardingEnabled;
  GPBBoolValue *isDigitalWay;
  GPBInt32Array *planIdsArray;
} KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "statusTypesArray",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_StatusType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_StatusTypesArray,
        .hasIndex = GPBNoHasBit,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, statusTypesArray),
        .flags = (GPBFieldFlags)(GPBFieldRepeated | GPBFieldPacked | GPBFieldHasEnumDescriptor),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "serviceTypesArray",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_ServiceType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_ServiceTypesArray,
        .hasIndex = GPBNoHasBit,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, serviceTypesArray),
        .flags = (GPBFieldFlags)(GPBFieldRepeated | GPBFieldPacked | GPBFieldHasEnumDescriptor),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "rfIdsArray",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_RfIdsArray,
        .hasIndex = GPBNoHasBit,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, rfIdsArray),
        .flags = (GPBFieldFlags)(GPBFieldRepeated | GPBFieldPacked),
        .dataType = GPBDataTypeInt32,
      },
      {
        .name = "text",
        .dataTypeSpecific.clazz = GPBObjCClass(GPBStringValue),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_Text,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, text),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "applicabilityRulesContractTypesArray",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ContractType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_ApplicabilityRulesContractTypesArray,
        .hasIndex = GPBNoHasBit,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, applicabilityRulesContractTypesArray),
        .flags = (GPBFieldFlags)(GPBFieldRepeated | GPBFieldPacked | GPBFieldHasEnumDescriptor),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "applicabilityRulesClientTypesArray",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_ClientType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_ApplicabilityRulesClientTypesArray,
        .hasIndex = GPBNoHasBit,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, applicabilityRulesClientTypesArray),
        .flags = (GPBFieldFlags)(GPBFieldRepeated | GPBFieldPacked | GPBFieldHasEnumDescriptor),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "applicabilityRulesBillingSystemTypesArray",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_BillingSystemType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_ApplicabilityRulesBillingSystemTypesArray,
        .hasIndex = GPBNoHasBit,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, applicabilityRulesBillingSystemTypesArray),
        .flags = (GPBFieldFlags)(GPBFieldRepeated | GPBFieldPacked | GPBFieldHasEnumDescriptor),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "isExternalPaymentForSmartIntercom",
        .dataTypeSpecific.clazz = GPBObjCClass(GPBBoolValue),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_IsExternalPaymentForSmartIntercom,
        .hasIndex = 1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, isExternalPaymentForSmartIntercom),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "applicabilityRulesIsCmsPhone",
        .dataTypeSpecific.clazz = GPBObjCClass(GPBBoolValue),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_ApplicabilityRulesIsCmsPhone,
        .hasIndex = 2,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, applicabilityRulesIsCmsPhone),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "applicabilityRulesIsSipPhone",
        .dataTypeSpecific.clazz = GPBObjCClass(GPBBoolValue),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_ApplicabilityRulesIsSipPhone,
        .hasIndex = 3,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, applicabilityRulesIsSipPhone),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "applicabilityRulesIsVideoMonitor",
        .dataTypeSpecific.clazz = GPBObjCClass(GPBBoolValue),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_ApplicabilityRulesIsVideoMonitor,
        .hasIndex = 4,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, applicabilityRulesIsVideoMonitor),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "applicabilityRulesRoomDeviceContractTypesArray",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_RoomDeviceContractType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_ApplicabilityRulesRoomDeviceContractTypesArray,
        .hasIndex = GPBNoHasBit,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, applicabilityRulesRoomDeviceContractTypesArray),
        .flags = (GPBFieldFlags)(GPBFieldRepeated | GPBFieldPacked | GPBFieldHasEnumDescriptor),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "applicabilityRulesMobileAppPackageTypesArray",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplate_ApplicabilityRules_MobileAppPackageType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_ApplicabilityRulesMobileAppPackageTypesArray,
        .hasIndex = GPBNoHasBit,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, applicabilityRulesMobileAppPackageTypesArray),
        .flags = (GPBFieldFlags)(GPBFieldRepeated | GPBFieldPacked | GPBFieldHasEnumDescriptor),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "isCallForwardingEnabled",
        .dataTypeSpecific.clazz = GPBObjCClass(GPBBoolValue),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_IsCallForwardingEnabled,
        .hasIndex = 5,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, isCallForwardingEnabled),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "isDigitalWay",
        .dataTypeSpecific.clazz = GPBObjCClass(GPBBoolValue),
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_IsDigitalWay,
        .hasIndex = 6,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, isDigitalWay),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "planIdsArray",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplateFilter_FieldNumber_PlanIdsArray,
        .hasIndex = GPBNoHasBit,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_, planIdsArray),
        .flags = (GPBFieldFlags)(GPBFieldRepeated | GPBFieldPacked),
        .dataType = GPBDataTypeInt32,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter)
                                   messageName:@"OfferTemplateFilter"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

#pragma mark - KEYAPISSUBSCRIPTIONV1OfferTemplatePaging

@implementation KEYAPISSUBSCRIPTIONV1OfferTemplatePaging

@dynamic orderByType;
@dynamic directionType;
@dynamic limit;
@dynamic offset;

typedef struct KEYAPISSUBSCRIPTIONV1OfferTemplatePaging__storage_ {
  uint32_t _has_storage_[1];
  KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType orderByType;
  KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType directionType;
  int32_t limit;
  int32_t offset;
} KEYAPISSUBSCRIPTIONV1OfferTemplatePaging__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "orderByType",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_FieldNumber_OrderByType,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging__storage_, orderByType),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldHasEnumDescriptor | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "directionType",
        .dataTypeSpecific.enumDescFunc = KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType_EnumDescriptor,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_FieldNumber_DirectionType,
        .hasIndex = 1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging__storage_, directionType),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldHasEnumDescriptor | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeEnum,
      },
      {
        .name = "limit",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_FieldNumber_Limit,
        .hasIndex = 2,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging__storage_, limit),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeInt32,
      },
      {
        .name = "offset",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_FieldNumber_Offset,
        .hasIndex = 3,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging__storage_, offset),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeInt32,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging)
                                   messageName:@"OfferTemplatePaging"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

int32_t KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplatePaging descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_FieldNumber_OrderByType];
  return GPBGetMessageRawEnumField(message, field);
}

void SetKEYAPISSUBSCRIPTIONV1OfferTemplatePaging_OrderByType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging *message, int32_t value) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplatePaging descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_FieldNumber_OrderByType];
  GPBSetMessageRawEnumField(message, field, value);
}

int32_t KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplatePaging descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_FieldNumber_DirectionType];
  return GPBGetMessageRawEnumField(message, field);
}

void SetKEYAPISSUBSCRIPTIONV1OfferTemplatePaging_DirectionType_RawValue(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging *message, int32_t value) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1OfferTemplatePaging descriptor];
  GPBFieldDescriptor *field = [descriptor fieldWithNumber:KEYAPISSUBSCRIPTIONV1OfferTemplatePaging_FieldNumber_DirectionType];
  GPBSetMessageRawEnumField(message, field, value);
}

#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateRequest

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateRequest

@dynamic id_p;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateRequest__storage_ {
  uint32_t _has_storage_[1];
  NSString *id_p;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateRequest__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "id_p",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateRequest_FieldNumber_Id_p,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateRequest__storage_, id_p),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeString,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateRequest)
                                   messageName:@"GetOfferTemplateRequest"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateRequest__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateResponse

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateResponse

@dynamic typeOneOfCase;
@dynamic data_p;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateResponse__storage_ {
  uint32_t _has_storage_[2];
  KEYAPISSUBSCRIPTIONV1OfferTemplate *data_p;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateResponse__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "data_p",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateResponse_FieldNumber_Data_p,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateResponse__storage_, data_p),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateResponse)
                                   messageName:@"GetOfferTemplateResponse"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateResponse__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "type",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1GetOfferTemplateResponse_ClearTypeOneOfCase(KEYAPISSUBSCRIPTIONV1GetOfferTemplateResponse *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1GetOfferTemplateResponse descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest

@dynamic paginationOneOfCase;
@dynamic hasFilter, filter;
@dynamic paging;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest__storage_ {
  uint32_t _has_storage_[2];
  KEYAPISSUBSCRIPTIONV1OfferTemplateFilter *filter;
  KEYAPISSUBSCRIPTIONV1OfferTemplatePaging *paging;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "filter",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest_FieldNumber_Filter,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest__storage_, filter),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "paging",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplatePaging),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest_FieldNumber_Paging,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest__storage_, paging),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest)
                                   messageName:@"GetOfferTemplateListRequest"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "pagination",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest_ClearPaginationOneOfCase(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1GetOfferTemplateListRequest descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse

@dynamic typeOneOfCase;
@dynamic data_p;
@dynamic error;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse__storage_ {
  uint32_t _has_storage_[2];
  KEYAPISSUBSCRIPTIONV1OfferTemplate *data_p;
  KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error *error;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "data_p",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_FieldNumber_Data_p,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse__storage_, data_p),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "error",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_FieldNumber_Error,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse__storage_, error),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse)
                                   messageName:@"GetOfferTemplateListResponse"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "type",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_ClearTypeOneOfCase(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error

@dynamic reasonOneOfCase;
@dynamic validation;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error__storage_ {
  uint32_t _has_storage_[2];
  KEYAPISSUBSCRIPTIONV1ValidationError *validation;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "validation",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1ValidationError),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error_FieldNumber_Validation,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error__storage_, validation),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error)
                                   messageName:@"Error"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "reason",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    [localDescriptor setupContainingMessageClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error_ClearReasonOneOfCase(KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1GetOfferTemplateListResponse_Error descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListRequest

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListRequest

@dynamic orpon;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListRequest__storage_ {
  uint32_t _has_storage_[1];
  int64_t orpon;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListRequest__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "orpon",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListRequest_FieldNumber_Orpon,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListRequest__storage_, orpon),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeInt64,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListRequest)
                                   messageName:@"GetOfferTemplateByOrponListRequest"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListRequest__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse

@dynamic typeOneOfCase;
@dynamic data_p;
@dynamic error;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse__storage_ {
  uint32_t _has_storage_[2];
  KEYAPISSUBSCRIPTIONV1OfferTemplate *data_p;
  KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error *error;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "data_p",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_FieldNumber_Data_p,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse__storage_, data_p),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "error",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_FieldNumber_Error,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse__storage_, error),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse)
                                   messageName:@"GetOfferTemplateByOrponListResponse"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "type",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_ClearTypeOneOfCase(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error

@dynamic reasonOneOfCase;
@dynamic validation;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error__storage_ {
  uint32_t _has_storage_[2];
  KEYAPISSUBSCRIPTIONV1ValidationError *validation;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "validation",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1ValidationError),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error_FieldNumber_Validation,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error__storage_, validation),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error)
                                   messageName:@"Error"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "reason",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    [localDescriptor setupContainingMessageClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error_ClearReasonOneOfCase(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponListResponse_Error descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountRequest

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountRequest

@dynamic hasFilter, filter;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountRequest__storage_ {
  uint32_t _has_storage_[1];
  KEYAPISSUBSCRIPTIONV1OfferTemplateFilter *filter;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountRequest__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "filter",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplateFilter),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountRequest_FieldNumber_Filter,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountRequest__storage_, filter),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountRequest)
                                   messageName:@"GetOfferTemplateCountRequest"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountRequest__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse

@dynamic typeOneOfCase;
@dynamic data_p;
@dynamic error;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse__storage_ {
  uint32_t _has_storage_[2];
  int32_t data_p;
  KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error *error;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "data_p",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_FieldNumber_Data_p,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse__storage_, data_p),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeInt32,
      },
      {
        .name = "error",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_FieldNumber_Error,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse__storage_, error),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse)
                                   messageName:@"GetOfferTemplateCountResponse"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "type",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_ClearTypeOneOfCase(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error

@dynamic reasonOneOfCase;
@dynamic validation;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error__storage_ {
  uint32_t _has_storage_[2];
  KEYAPISSUBSCRIPTIONV1ValidationError *validation;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "validation",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1ValidationError),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error_FieldNumber_Validation,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error__storage_, validation),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error)
                                   messageName:@"Error"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "reason",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    [localDescriptor setupContainingMessageClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error_ClearReasonOneOfCase(KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1GetOfferTemplateCountResponse_Error descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountRequest

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountRequest

@dynamic orpon;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountRequest__storage_ {
  uint32_t _has_storage_[1];
  int64_t orpon;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountRequest__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "orpon",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountRequest_FieldNumber_Orpon,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountRequest__storage_, orpon),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeInt64,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountRequest)
                                   messageName:@"GetOfferTemplateByOrponCountRequest"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountRequest__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse

@dynamic typeOneOfCase;
@dynamic data_p;
@dynamic error;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse__storage_ {
  uint32_t _has_storage_[2];
  int32_t data_p;
  KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error *error;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "data_p",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_FieldNumber_Data_p,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse__storage_, data_p),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeInt32,
      },
      {
        .name = "error",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_FieldNumber_Error,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse__storage_, error),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse)
                                   messageName:@"GetOfferTemplateByOrponCountResponse"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "type",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_ClearTypeOneOfCase(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error

@implementation KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error

@dynamic reasonOneOfCase;
@dynamic validation;

typedef struct KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error__storage_ {
  uint32_t _has_storage_[2];
  KEYAPISSUBSCRIPTIONV1ValidationError *validation;
} KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "validation",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1ValidationError),
        .number = KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error_FieldNumber_Validation,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error__storage_, validation),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error)
                                   messageName:@"Error"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "reason",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    [localDescriptor setupContainingMessageClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error_ClearReasonOneOfCase(KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1GetOfferTemplateByOrponCountResponse_Error descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1PostOfferTemplateRequest

@implementation KEYAPISSUBSCRIPTIONV1PostOfferTemplateRequest

@dynamic hasData_p, data_p;

typedef struct KEYAPISSUBSCRIPTIONV1PostOfferTemplateRequest__storage_ {
  uint32_t _has_storage_[1];
  KEYAPISSUBSCRIPTIONV1OfferTemplate *data_p;
} KEYAPISSUBSCRIPTIONV1PostOfferTemplateRequest__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "data_p",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate),
        .number = KEYAPISSUBSCRIPTIONV1PostOfferTemplateRequest_FieldNumber_Data_p,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRequest__storage_, data_p),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRequest)
                                   messageName:@"PostOfferTemplateRequest"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRequest__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

#pragma mark - KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse

@implementation KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse

@dynamic typeOneOfCase;
@dynamic data_p;
@dynamic error;

typedef struct KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse__storage_ {
  uint32_t _has_storage_[2];
  KEYAPISSUBSCRIPTIONV1OfferTemplate *data_p;
  KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error *error;
} KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "data_p",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate),
        .number = KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_FieldNumber_Data_p,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse__storage_, data_p),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "error",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error),
        .number = KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_FieldNumber_Error,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse__storage_, error),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse)
                                   messageName:@"PostOfferTemplateResponse"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "type",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_ClearTypeOneOfCase(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error

@implementation KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error

@dynamic reasonOneOfCase;
@dynamic validation;
@dynamic saving;

typedef struct KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error__storage_ {
  uint32_t _has_storage_[2];
  KEYAPISSUBSCRIPTIONV1ValidationError *validation;
  KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError *saving;
} KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "validation",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1ValidationError),
        .number = KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error_FieldNumber_Validation,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error__storage_, validation),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
      {
        .name = "saving",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate_SavingError),
        .number = KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error_FieldNumber_Saving,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error__storage_, saving),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error)
                                   messageName:@"Error"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "reason",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    [localDescriptor setupContainingMessageClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error_ClearReasonOneOfCase(KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1PostOfferTemplateResponse_Error descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateRequest

@implementation KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateRequest

@dynamic id_p;

typedef struct KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateRequest__storage_ {
  uint32_t _has_storage_[1];
  NSString *id_p;
} KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateRequest__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "id_p",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateRequest_FieldNumber_Id_p,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateRequest__storage_, id_p),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeString,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateRequest)
                                   messageName:@"DeleteOfferTemplateRequest"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateRequest__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

#pragma mark - KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateResponse

@implementation KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateResponse


typedef struct KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateResponse__storage_ {
  uint32_t _has_storage_[1];
} KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateResponse__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateResponse)
                                   messageName:@"DeleteOfferTemplateResponse"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:NULL
                                    fieldCount:0
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1DeleteOfferTemplateResponse__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

#pragma mark - KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreRequest

@implementation KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreRequest

@dynamic id_p;

typedef struct KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreRequest__storage_ {
  uint32_t _has_storage_[1];
  NSString *id_p;
} KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreRequest__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "id_p",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreRequest_FieldNumber_Id_p,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreRequest__storage_, id_p),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeString,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreRequest)
                                   messageName:@"PostOfferTemplateRestoreRequest"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreRequest__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

#pragma mark - KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreResponse

@implementation KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreResponse

@dynamic typeOneOfCase;
@dynamic data_p;

typedef struct KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreResponse__storage_ {
  uint32_t _has_storage_[2];
  KEYAPISSUBSCRIPTIONV1OfferTemplate *data_p;
} KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreResponse__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "data_p",
        .dataTypeSpecific.clazz = GPBObjCClass(KEYAPISSUBSCRIPTIONV1OfferTemplate),
        .number = KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreResponse_FieldNumber_Data_p,
        .hasIndex = -1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreResponse__storage_, data_p),
        .flags = GPBFieldOptional,
        .dataType = GPBDataTypeMessage,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreResponse)
                                   messageName:@"PostOfferTemplateRestoreResponse"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreResponse__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    static const char *oneofs[] = {
      "type",
    };
    [localDescriptor setupOneofs:oneofs
                           count:(uint32_t)(sizeof(oneofs) / sizeof(char*))
                   firstHasIndex:-1];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end

void KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreResponse_ClearTypeOneOfCase(KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreResponse *message) {
  GPBDescriptor *descriptor = [KEYAPISSUBSCRIPTIONV1PostOfferTemplateRestoreResponse descriptor];
  GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:0];
  GPBClearOneof(message, oneof);
}
#pragma mark - KEYAPISSUBSCRIPTIONV1ValidationError

@implementation KEYAPISSUBSCRIPTIONV1ValidationError

@dynamic path;
@dynamic message;

typedef struct KEYAPISSUBSCRIPTIONV1ValidationError__storage_ {
  uint32_t _has_storage_[1];
  NSString *path;
  NSString *message;
} KEYAPISSUBSCRIPTIONV1ValidationError__storage_;

// This method is threadsafe because it is initially called
// in +initialize for each subclass.
+ (GPBDescriptor *)descriptor {
  static GPBDescriptor *descriptor = nil;
  if (!descriptor) {
    GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
    static GPBMessageFieldDescription fields[] = {
      {
        .name = "path",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1ValidationError_FieldNumber_Path,
        .hasIndex = 0,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1ValidationError__storage_, path),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeString,
      },
      {
        .name = "message",
        .dataTypeSpecific.clazz = Nil,
        .number = KEYAPISSUBSCRIPTIONV1ValidationError_FieldNumber_Message,
        .hasIndex = 1,
        .offset = (uint32_t)offsetof(KEYAPISSUBSCRIPTIONV1ValidationError__storage_, message),
        .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
        .dataType = GPBDataTypeString,
      },
    };
    GPBDescriptor *localDescriptor =
        [GPBDescriptor allocDescriptorForClass:GPBObjCClass(KEYAPISSUBSCRIPTIONV1ValidationError)
                                   messageName:@"ValidationError"
                               fileDescription:&KEYAPISSUBSCRIPTIONV1KeyapisSubscriptionOfferTemplateV1Root_FileDescription
                                        fields:fields
                                    fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
                                   storageSize:sizeof(KEYAPISSUBSCRIPTIONV1ValidationError__storage_)
                                         flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown | GPBDescriptorInitializationFlag_ClosedEnumSupportKnown)];
    #if defined(DEBUG) && DEBUG
      NSAssert(descriptor == nil, @"Startup recursed!");
    #endif  // DEBUG
    descriptor = localDescriptor;
  }
  return descriptor;
}

@end


#pragma clang diagnostic pop

// @@protoc_insertion_point(global_scope)

// clang-format on
