blob: 11ba5e5f7b3363fde54155d55fa2f9730af80957 [file] [log] [blame]
Thomas Van Lenten30650d82015-05-01 08:57:16 -04001// Generated by the protocol buffer compiler. DO NOT EDIT!
2// source: google/protobuf/duration.proto
3
Thomas Van Lenten020e4e32022-03-01 14:16:50 -05004#import "GPBProtocolBuffers_RuntimeSupport.h"
5#import "GPBDuration.pbobjc.h"
Thomas Van Lenten7da023b2016-05-09 13:53:20 -04006
Thomas Van Lenten1dcc3292015-05-21 17:14:52 -04007// @@protoc_insertion_point(imports)
Thomas Van Lenten30650d82015-05-01 08:57:16 -04008
Thomas Van Lentene664aa62016-04-19 13:13:04 -04009#pragma clang diagnostic push
10#pragma clang diagnostic ignored "-Wdeprecated-declarations"
11
Thomas Van Lenten30650d82015-05-01 08:57:16 -040012#pragma mark - GPBDurationRoot
13
14@implementation GPBDurationRoot
15
Thomas Van Lenten13a41242016-09-01 11:45:50 -040016// No extensions in the file and no imports, so no need to generate
17// +extensionRegistry.
18
Thomas Van Lenten30650d82015-05-01 08:57:16 -040019@end
20
Thomas Van Lentend846b0b2015-06-08 16:24:57 -040021#pragma mark - GPBDurationRoot_FileDescriptor
22
Thomas Van Lenten30650d82015-05-01 08:57:16 -040023static GPBFileDescriptor *GPBDurationRoot_FileDescriptor(void) {
24 // This is called by +initialize so there is no need to worry
25 // about thread safety of the singleton.
26 static GPBFileDescriptor *descriptor = NULL;
27 if (!descriptor) {
Thomas Van Lenten1aa65002016-09-15 13:27:17 -040028 GPB_DEBUG_CHECK_RUNTIME_VERSIONS();
Thomas Van Lenten30650d82015-05-01 08:57:16 -040029 descriptor = [[GPBFileDescriptor alloc] initWithPackage:@"google.protobuf"
Thomas Van Lenten337ec302016-08-16 11:26:49 -040030 objcPrefix:@"GPB"
Thomas Van Lenten30650d82015-05-01 08:57:16 -040031 syntax:GPBFileSyntaxProto3];
32 }
33 return descriptor;
34}
35
36#pragma mark - GPBDuration
37
38@implementation GPBDuration
39
40@dynamic seconds;
41@dynamic nanos;
42
Thomas Van Lentend846b0b2015-06-08 16:24:57 -040043typedef struct GPBDuration__storage_ {
Thomas Van Lenten30650d82015-05-01 08:57:16 -040044 uint32_t _has_storage_[1];
45 int32_t nanos;
46 int64_t seconds;
Thomas Van Lentend846b0b2015-06-08 16:24:57 -040047} GPBDuration__storage_;
Thomas Van Lenten30650d82015-05-01 08:57:16 -040048
49// This method is threadsafe because it is initially called
50// in +initialize for each subclass.
51+ (GPBDescriptor *)descriptor {
Thomas Van Lentend846b0b2015-06-08 16:24:57 -040052 static GPBDescriptor *descriptor = nil;
Thomas Van Lenten30650d82015-05-01 08:57:16 -040053 if (!descriptor) {
54 static GPBMessageFieldDescription fields[] = {
55 {
56 .name = "seconds",
Dave MacLachlan74956e12019-12-17 17:32:09 -080057 .dataTypeSpecific.clazz = Nil,
Thomas Van Lenten30650d82015-05-01 08:57:16 -040058 .number = GPBDuration_FieldNumber_Seconds,
59 .hasIndex = 0,
Thomas Van Lenten79a23c42016-03-17 10:04:21 -040060 .offset = (uint32_t)offsetof(GPBDuration__storage_, seconds),
Thomas Van Lentenb0e27922020-04-13 13:36:56 -040061 .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
Thomas Van Lentend846b0b2015-06-08 16:24:57 -040062 .dataType = GPBDataTypeInt64,
Thomas Van Lenten30650d82015-05-01 08:57:16 -040063 },
64 {
65 .name = "nanos",
Dave MacLachlan74956e12019-12-17 17:32:09 -080066 .dataTypeSpecific.clazz = Nil,
Thomas Van Lenten30650d82015-05-01 08:57:16 -040067 .number = GPBDuration_FieldNumber_Nanos,
68 .hasIndex = 1,
Thomas Van Lenten79a23c42016-03-17 10:04:21 -040069 .offset = (uint32_t)offsetof(GPBDuration__storage_, nanos),
Thomas Van Lentenb0e27922020-04-13 13:36:56 -040070 .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldClearHasIvarOnZero),
Thomas Van Lentend846b0b2015-06-08 16:24:57 -040071 .dataType = GPBDataTypeInt32,
Thomas Van Lenten30650d82015-05-01 08:57:16 -040072 },
73 };
Thomas Van Lentend846b0b2015-06-08 16:24:57 -040074 GPBDescriptor *localDescriptor =
75 [GPBDescriptor allocDescriptorForClass:[GPBDuration class]
76 rootClass:[GPBDurationRoot class]
77 file:GPBDurationRoot_FileDescriptor()
78 fields:fields
Thomas Van Lenten79a23c42016-03-17 10:04:21 -040079 fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription))
Thomas Van Lentend846b0b2015-06-08 16:24:57 -040080 storageSize:sizeof(GPBDuration__storage_)
Thomas Van Lentenb0e27922020-04-13 13:36:56 -040081 flags:(GPBDescriptorInitializationFlags)(GPBDescriptorInitializationFlag_UsesClassRefs | GPBDescriptorInitializationFlag_Proto3OptionalKnown)];
Dave MacLachlanb6311762018-12-11 16:32:48 -080082 #if defined(DEBUG) && DEBUG
83 NSAssert(descriptor == nil, @"Startup recursed!");
84 #endif // DEBUG
Thomas Van Lentend846b0b2015-06-08 16:24:57 -040085 descriptor = localDescriptor;
Thomas Van Lenten30650d82015-05-01 08:57:16 -040086 }
87 return descriptor;
88}
89
90@end
91
Thomas Van Lenten1dcc3292015-05-21 17:14:52 -040092
Thomas Van Lentene664aa62016-04-19 13:13:04 -040093#pragma clang diagnostic pop
94
Thomas Van Lenten1dcc3292015-05-21 17:14:52 -040095// @@protoc_insertion_point(global_scope)