// Generated by the protocol buffer compiler. DO NOT EDIT! #include "ProtocolBuffers.h" #import "Descriptor.pb.h" @implementation PBDescriptorRoot static PBExtensionRegistry* extensionRegistry = nil; + (PBExtensionRegistry*) extensionRegistry { return extensionRegistry; } + (void) initialize { if (self == [PBDescriptorRoot class]) { PBMutableExtensionRegistry* registry = [PBMutableExtensionRegistry registry]; [self registerAllExtensions:registry]; extensionRegistry = [registry retain]; } } + (void) registerAllExtensions:(PBMutableExtensionRegistry*) registry { } @end @interface PBFileDescriptorSet () @property (retain) PBAppendableArray * fileArray; @end @implementation PBFileDescriptorSet @synthesize fileArray; @dynamic file; - (void) dealloc { self.fileArray = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { } return self; } static PBFileDescriptorSet* defaultPBFileDescriptorSetInstance = nil; + (void) initialize { if (self == [PBFileDescriptorSet class]) { defaultPBFileDescriptorSetInstance = [[PBFileDescriptorSet alloc] init]; } } + (PBFileDescriptorSet*) defaultInstance { return defaultPBFileDescriptorSetInstance; } - (PBFileDescriptorSet*) defaultInstance { return defaultPBFileDescriptorSetInstance; } - (PBArray *)file { return fileArray; } - (PBFileDescriptorProto*)fileAtIndex:(NSUInteger)index { return [fileArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBFileDescriptorProto* element in self.file) { if (!element.isInitialized) { return NO; } } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { for (PBFileDescriptorProto *element in self.fileArray) { [output writeMessage:1 value:element]; } [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; for (PBFileDescriptorProto *element in self.fileArray) { size += computeMessageSize(1, element); } size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBFileDescriptorSet*) parseFromData:(NSData*) data { return (PBFileDescriptorSet*)[[[PBFileDescriptorSet builder] mergeFromData:data] build]; } + (PBFileDescriptorSet*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFileDescriptorSet*)[[[PBFileDescriptorSet builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBFileDescriptorSet*) parseFromInputStream:(NSInputStream*) input { return (PBFileDescriptorSet*)[[[PBFileDescriptorSet builder] mergeFromInputStream:input] build]; } + (PBFileDescriptorSet*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFileDescriptorSet*)[[[PBFileDescriptorSet builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBFileDescriptorSet*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBFileDescriptorSet*)[[[PBFileDescriptorSet builder] mergeFromCodedInputStream:input] build]; } + (PBFileDescriptorSet*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFileDescriptorSet*)[[[PBFileDescriptorSet builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBFileDescriptorSet_Builder*) builder { return [[[PBFileDescriptorSet_Builder alloc] init] autorelease]; } + (PBFileDescriptorSet_Builder*) builderWithPrototype:(PBFileDescriptorSet*) prototype { return [[PBFileDescriptorSet builder] mergeFrom:prototype]; } - (PBFileDescriptorSet_Builder*) builder { return [PBFileDescriptorSet builder]; } @end @interface PBFileDescriptorSet_Builder() @property (retain) PBFileDescriptorSet* result; @end @implementation PBFileDescriptorSet_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBFileDescriptorSet alloc] init] autorelease]; } return self; } - (PBGeneratedMessage*) internalGetResult { return result; } - (PBFileDescriptorSet_Builder*) clear { self.result = [[[PBFileDescriptorSet alloc] init] autorelease]; return self; } - (PBFileDescriptorSet_Builder*) clone { return [PBFileDescriptorSet builderWithPrototype:result]; } - (PBFileDescriptorSet*) defaultInstance { return [PBFileDescriptorSet defaultInstance]; } - (PBFileDescriptorSet*) build { [self checkInitialized]; return [self buildPartial]; } - (PBFileDescriptorSet*) buildPartial { PBFileDescriptorSet* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBFileDescriptorSet_Builder*) mergeFrom:(PBFileDescriptorSet*) other { if (other == [PBFileDescriptorSet defaultInstance]) { return self; } if (other.fileArray.count > 0) { if (result.fileArray == nil) { result.fileArray = [other.fileArray copyWithZone:[other.fileArray zone]]; } else { [result.fileArray appendArray:other.fileArray]; } } [self mergeUnknownFields:other.unknownFields]; return self; } - (PBFileDescriptorSet_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBFileDescriptorSet_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 10: { PBFileDescriptorProto_Builder* subBuilder = [PBFileDescriptorProto builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addFile:[subBuilder buildPartial]]; break; } } } } - (PBAppendableArray *)file { return result.fileArray; } - (PBFileDescriptorProto*)fileAtIndex:(NSUInteger)index { return [result fileAtIndex:index]; } - (PBFileDescriptorSet_Builder *)addFile:(PBFileDescriptorProto*)value { if (result.fileArray == nil) { result.fileArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.fileArray addObject:value]; return self; } - (PBFileDescriptorSet_Builder *)setFileArray:(NSArray *)array { result.fileArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBFileDescriptorSet_Builder *)setFileValues:(const PBFileDescriptorProto* *)values count:(NSUInteger)count { result.fileArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBFileDescriptorSet_Builder *)clearFile { result.fileArray = nil; return self; } @end @interface PBFileDescriptorProto () @property (retain) NSString* name; @property (retain) NSString* package; @property (retain) PBAppendableArray * dependencyArray; @property (retain) PBAppendableArray * messageTypeArray; @property (retain) PBAppendableArray * enumTypeArray; @property (retain) PBAppendableArray * serviceArray; @property (retain) PBAppendableArray * extensionArray; @property (retain) PBFileOptions* options; @end @implementation PBFileDescriptorProto - (BOOL) hasName { return !!hasName_; } - (void) setHasName:(BOOL) value { hasName_ = !!value; } @synthesize name; - (BOOL) hasPackage { return !!hasPackage_; } - (void) setHasPackage:(BOOL) value { hasPackage_ = !!value; } @synthesize package; @synthesize dependencyArray; @dynamic dependency; @synthesize messageTypeArray; @dynamic messageType; @synthesize enumTypeArray; @dynamic enumType; @synthesize serviceArray; @dynamic service; @synthesize extensionArray; @dynamic extension; - (BOOL) hasOptions { return !!hasOptions_; } - (void) setHasOptions:(BOOL) value { hasOptions_ = !!value; } @synthesize options; - (void) dealloc { self.name = nil; self.package = nil; self.dependencyArray = nil; self.messageTypeArray = nil; self.enumTypeArray = nil; self.serviceArray = nil; self.extensionArray = nil; self.options = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.name = @""; self.package = @""; self.options = [PBFileOptions defaultInstance]; } return self; } static PBFileDescriptorProto* defaultPBFileDescriptorProtoInstance = nil; + (void) initialize { if (self == [PBFileDescriptorProto class]) { defaultPBFileDescriptorProtoInstance = [[PBFileDescriptorProto alloc] init]; } } + (PBFileDescriptorProto*) defaultInstance { return defaultPBFileDescriptorProtoInstance; } - (PBFileDescriptorProto*) defaultInstance { return defaultPBFileDescriptorProtoInstance; } - (PBArray *)dependency { return dependencyArray; } - (NSString*)dependencyAtIndex:(NSUInteger)index { return [dependencyArray objectAtIndex:index]; } - (PBArray *)messageType { return messageTypeArray; } - (PBDescriptorProto*)messageTypeAtIndex:(NSUInteger)index { return [messageTypeArray objectAtIndex:index]; } - (PBArray *)enumType { return enumTypeArray; } - (PBEnumDescriptorProto*)enumTypeAtIndex:(NSUInteger)index { return [enumTypeArray objectAtIndex:index]; } - (PBArray *)service { return serviceArray; } - (PBServiceDescriptorProto*)serviceAtIndex:(NSUInteger)index { return [serviceArray objectAtIndex:index]; } - (PBArray *)extension { return extensionArray; } - (PBFieldDescriptorProto*)extensionAtIndex:(NSUInteger)index { return [extensionArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBDescriptorProto* element in self.messageType) { if (!element.isInitialized) { return NO; } } for (PBEnumDescriptorProto* element in self.enumType) { if (!element.isInitialized) { return NO; } } for (PBServiceDescriptorProto* element in self.service) { if (!element.isInitialized) { return NO; } } for (PBFieldDescriptorProto* element in self.extension) { if (!element.isInitialized) { return NO; } } if (self.hasOptions) { if (!self.options.isInitialized) { return NO; } } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { if (self.hasName) { [output writeString:1 value:self.name]; } if (self.hasPackage) { [output writeString:2 value:self.package]; } const NSUInteger dependencyArrayCount = self.dependencyArray.count; if (dependencyArrayCount > 0) { const NSString* *values = (const NSString* *)self.dependencyArray.data; for (NSUInteger i = 0; i < dependencyArrayCount; ++i) { [output writeString:3 value:values[i]]; } } for (PBDescriptorProto *element in self.messageTypeArray) { [output writeMessage:4 value:element]; } for (PBEnumDescriptorProto *element in self.enumTypeArray) { [output writeMessage:5 value:element]; } for (PBServiceDescriptorProto *element in self.serviceArray) { [output writeMessage:6 value:element]; } for (PBFieldDescriptorProto *element in self.extensionArray) { [output writeMessage:7 value:element]; } if (self.hasOptions) { [output writeMessage:8 value:self.options]; } [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; if (self.hasName) { size += computeStringSize(1, self.name); } if (self.hasPackage) { size += computeStringSize(2, self.package); } { int32_t dataSize = 0; const NSUInteger count = self.dependencyArray.count; const NSString* *values = (const NSString* *)self.dependencyArray.data; for (NSUInteger i = 0; i < count; ++i) { dataSize += computeStringSizeNoTag(values[i]); } size += dataSize; size += 1 * count; } for (PBDescriptorProto *element in self.messageTypeArray) { size += computeMessageSize(4, element); } for (PBEnumDescriptorProto *element in self.enumTypeArray) { size += computeMessageSize(5, element); } for (PBServiceDescriptorProto *element in self.serviceArray) { size += computeMessageSize(6, element); } for (PBFieldDescriptorProto *element in self.extensionArray) { size += computeMessageSize(7, element); } if (self.hasOptions) { size += computeMessageSize(8, self.options); } size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBFileDescriptorProto*) parseFromData:(NSData*) data { return (PBFileDescriptorProto*)[[[PBFileDescriptorProto builder] mergeFromData:data] build]; } + (PBFileDescriptorProto*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFileDescriptorProto*)[[[PBFileDescriptorProto builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBFileDescriptorProto*) parseFromInputStream:(NSInputStream*) input { return (PBFileDescriptorProto*)[[[PBFileDescriptorProto builder] mergeFromInputStream:input] build]; } + (PBFileDescriptorProto*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFileDescriptorProto*)[[[PBFileDescriptorProto builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBFileDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBFileDescriptorProto*)[[[PBFileDescriptorProto builder] mergeFromCodedInputStream:input] build]; } + (PBFileDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFileDescriptorProto*)[[[PBFileDescriptorProto builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBFileDescriptorProto_Builder*) builder { return [[[PBFileDescriptorProto_Builder alloc] init] autorelease]; } + (PBFileDescriptorProto_Builder*) builderWithPrototype:(PBFileDescriptorProto*) prototype { return [[PBFileDescriptorProto builder] mergeFrom:prototype]; } - (PBFileDescriptorProto_Builder*) builder { return [PBFileDescriptorProto builder]; } @end @interface PBFileDescriptorProto_Builder() @property (retain) PBFileDescriptorProto* result; @end @implementation PBFileDescriptorProto_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBFileDescriptorProto alloc] init] autorelease]; } return self; } - (PBGeneratedMessage*) internalGetResult { return result; } - (PBFileDescriptorProto_Builder*) clear { self.result = [[[PBFileDescriptorProto alloc] init] autorelease]; return self; } - (PBFileDescriptorProto_Builder*) clone { return [PBFileDescriptorProto builderWithPrototype:result]; } - (PBFileDescriptorProto*) defaultInstance { return [PBFileDescriptorProto defaultInstance]; } - (PBFileDescriptorProto*) build { [self checkInitialized]; return [self buildPartial]; } - (PBFileDescriptorProto*) buildPartial { PBFileDescriptorProto* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBFileDescriptorProto_Builder*) mergeFrom:(PBFileDescriptorProto*) other { if (other == [PBFileDescriptorProto defaultInstance]) { return self; } if (other.hasName) { [self setName:other.name]; } if (other.hasPackage) { [self setPackage:other.package]; } if (other.dependencyArray.count > 0) { if (result.dependencyArray == nil) { result.dependencyArray = [other.dependencyArray copyWithZone:[other.dependencyArray zone]]; } else { [result.dependencyArray appendArray:other.dependencyArray]; } } if (other.messageTypeArray.count > 0) { if (result.messageTypeArray == nil) { result.messageTypeArray = [other.messageTypeArray copyWithZone:[other.messageTypeArray zone]]; } else { [result.messageTypeArray appendArray:other.messageTypeArray]; } } if (other.enumTypeArray.count > 0) { if (result.enumTypeArray == nil) { result.enumTypeArray = [other.enumTypeArray copyWithZone:[other.enumTypeArray zone]]; } else { [result.enumTypeArray appendArray:other.enumTypeArray]; } } if (other.serviceArray.count > 0) { if (result.serviceArray == nil) { result.serviceArray = [other.serviceArray copyWithZone:[other.serviceArray zone]]; } else { [result.serviceArray appendArray:other.serviceArray]; } } if (other.extensionArray.count > 0) { if (result.extensionArray == nil) { result.extensionArray = [other.extensionArray copyWithZone:[other.extensionArray zone]]; } else { [result.extensionArray appendArray:other.extensionArray]; } } if (other.hasOptions) { [self mergeOptions:other.options]; } [self mergeUnknownFields:other.unknownFields]; return self; } - (PBFileDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBFileDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 10: { [self setName:[input readString]]; break; } case 18: { [self setPackage:[input readString]]; break; } case 26: { [self addDependency:[input readString]]; break; } case 34: { PBDescriptorProto_Builder* subBuilder = [PBDescriptorProto builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addMessageType:[subBuilder buildPartial]]; break; } case 42: { PBEnumDescriptorProto_Builder* subBuilder = [PBEnumDescriptorProto builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addEnumType:[subBuilder buildPartial]]; break; } case 50: { PBServiceDescriptorProto_Builder* subBuilder = [PBServiceDescriptorProto builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addService:[subBuilder buildPartial]]; break; } case 58: { PBFieldDescriptorProto_Builder* subBuilder = [PBFieldDescriptorProto builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addExtension:[subBuilder buildPartial]]; break; } case 66: { PBFileOptions_Builder* subBuilder = [PBFileOptions builder]; if (self.hasOptions) { [subBuilder mergeFrom:self.options]; } [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self setOptions:[subBuilder buildPartial]]; break; } } } } - (BOOL) hasName { return result.hasName; } - (NSString*) name { return result.name; } - (PBFileDescriptorProto_Builder*) setName:(NSString*) value { result.hasName = YES; result.name = value; return self; } - (PBFileDescriptorProto_Builder*) clearName { result.hasName = NO; result.name = @""; return self; } - (BOOL) hasPackage { return result.hasPackage; } - (NSString*) package { return result.package; } - (PBFileDescriptorProto_Builder*) setPackage:(NSString*) value { result.hasPackage = YES; result.package = value; return self; } - (PBFileDescriptorProto_Builder*) clearPackage { result.hasPackage = NO; result.package = @""; return self; } - (PBAppendableArray *)dependency { return result.dependencyArray; } - (NSString*)dependencyAtIndex:(NSUInteger)index { return [result dependencyAtIndex:index]; } - (PBFileDescriptorProto_Builder *)addDependency:(NSString*)value { if (result.dependencyArray == nil) { result.dependencyArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.dependencyArray addObject:value]; return self; } - (PBFileDescriptorProto_Builder *)setDependencyArray:(NSArray *)array { result.dependencyArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBFileDescriptorProto_Builder *)setDependencyValues:(const NSString* *)values count:(NSUInteger)count { result.dependencyArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBFileDescriptorProto_Builder *)clearDependency { result.dependencyArray = nil; return self; } - (PBAppendableArray *)messageType { return result.messageTypeArray; } - (PBDescriptorProto*)messageTypeAtIndex:(NSUInteger)index { return [result messageTypeAtIndex:index]; } - (PBFileDescriptorProto_Builder *)addMessageType:(PBDescriptorProto*)value { if (result.messageTypeArray == nil) { result.messageTypeArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.messageTypeArray addObject:value]; return self; } - (PBFileDescriptorProto_Builder *)setMessageTypeArray:(NSArray *)array { result.messageTypeArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBFileDescriptorProto_Builder *)setMessageTypeValues:(const PBDescriptorProto* *)values count:(NSUInteger)count { result.messageTypeArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBFileDescriptorProto_Builder *)clearMessageType { result.messageTypeArray = nil; return self; } - (PBAppendableArray *)enumType { return result.enumTypeArray; } - (PBEnumDescriptorProto*)enumTypeAtIndex:(NSUInteger)index { return [result enumTypeAtIndex:index]; } - (PBFileDescriptorProto_Builder *)addEnumType:(PBEnumDescriptorProto*)value { if (result.enumTypeArray == nil) { result.enumTypeArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.enumTypeArray addObject:value]; return self; } - (PBFileDescriptorProto_Builder *)setEnumTypeArray:(NSArray *)array { result.enumTypeArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBFileDescriptorProto_Builder *)setEnumTypeValues:(const PBEnumDescriptorProto* *)values count:(NSUInteger)count { result.enumTypeArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBFileDescriptorProto_Builder *)clearEnumType { result.enumTypeArray = nil; return self; } - (PBAppendableArray *)service { return result.serviceArray; } - (PBServiceDescriptorProto*)serviceAtIndex:(NSUInteger)index { return [result serviceAtIndex:index]; } - (PBFileDescriptorProto_Builder *)addService:(PBServiceDescriptorProto*)value { if (result.serviceArray == nil) { result.serviceArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.serviceArray addObject:value]; return self; } - (PBFileDescriptorProto_Builder *)setServiceArray:(NSArray *)array { result.serviceArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBFileDescriptorProto_Builder *)setServiceValues:(const PBServiceDescriptorProto* *)values count:(NSUInteger)count { result.serviceArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBFileDescriptorProto_Builder *)clearService { result.serviceArray = nil; return self; } - (PBAppendableArray *)extension { return result.extensionArray; } - (PBFieldDescriptorProto*)extensionAtIndex:(NSUInteger)index { return [result extensionAtIndex:index]; } - (PBFileDescriptorProto_Builder *)addExtension:(PBFieldDescriptorProto*)value { if (result.extensionArray == nil) { result.extensionArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.extensionArray addObject:value]; return self; } - (PBFileDescriptorProto_Builder *)setExtensionArray:(NSArray *)array { result.extensionArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBFileDescriptorProto_Builder *)setExtensionValues:(const PBFieldDescriptorProto* *)values count:(NSUInteger)count { result.extensionArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBFileDescriptorProto_Builder *)clearExtension { result.extensionArray = nil; return self; } - (BOOL) hasOptions { return result.hasOptions; } - (PBFileOptions*) options { return result.options; } - (PBFileDescriptorProto_Builder*) setOptions:(PBFileOptions*) value { result.hasOptions = YES; result.options = value; return self; } - (PBFileDescriptorProto_Builder*) setOptionsBuilder:(PBFileOptions_Builder*) builderForValue { return [self setOptions:[builderForValue build]]; } - (PBFileDescriptorProto_Builder*) mergeOptions:(PBFileOptions*) value { if (result.hasOptions && result.options != [PBFileOptions defaultInstance]) { result.options = [[[PBFileOptions builderWithPrototype:result.options] mergeFrom:value] buildPartial]; } else { result.options = value; } result.hasOptions = YES; return self; } - (PBFileDescriptorProto_Builder*) clearOptions { result.hasOptions = NO; result.options = [PBFileOptions defaultInstance]; return self; } @end @interface PBDescriptorProto () @property (retain) NSString* name; @property (retain) PBAppendableArray * fieldArray; @property (retain) PBAppendableArray * extensionArray; @property (retain) PBAppendableArray * nestedTypeArray; @property (retain) PBAppendableArray * enumTypeArray; @property (retain) PBAppendableArray * extensionRangeArray; @property (retain) PBMessageOptions* options; @end @implementation PBDescriptorProto - (BOOL) hasName { return !!hasName_; } - (void) setHasName:(BOOL) value { hasName_ = !!value; } @synthesize name; @synthesize fieldArray; @dynamic field; @synthesize extensionArray; @dynamic extension; @synthesize nestedTypeArray; @dynamic nestedType; @synthesize enumTypeArray; @dynamic enumType; @synthesize extensionRangeArray; @dynamic extensionRange; - (BOOL) hasOptions { return !!hasOptions_; } - (void) setHasOptions:(BOOL) value { hasOptions_ = !!value; } @synthesize options; - (void) dealloc { self.name = nil; self.fieldArray = nil; self.extensionArray = nil; self.nestedTypeArray = nil; self.enumTypeArray = nil; self.extensionRangeArray = nil; self.options = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.name = @""; self.options = [PBMessageOptions defaultInstance]; } return self; } static PBDescriptorProto* defaultPBDescriptorProtoInstance = nil; + (void) initialize { if (self == [PBDescriptorProto class]) { defaultPBDescriptorProtoInstance = [[PBDescriptorProto alloc] init]; } } + (PBDescriptorProto*) defaultInstance { return defaultPBDescriptorProtoInstance; } - (PBDescriptorProto*) defaultInstance { return defaultPBDescriptorProtoInstance; } - (PBArray *)field { return fieldArray; } - (PBFieldDescriptorProto*)fieldAtIndex:(NSUInteger)index { return [fieldArray objectAtIndex:index]; } - (PBArray *)extension { return extensionArray; } - (PBFieldDescriptorProto*)extensionAtIndex:(NSUInteger)index { return [extensionArray objectAtIndex:index]; } - (PBArray *)nestedType { return nestedTypeArray; } - (PBDescriptorProto*)nestedTypeAtIndex:(NSUInteger)index { return [nestedTypeArray objectAtIndex:index]; } - (PBArray *)enumType { return enumTypeArray; } - (PBEnumDescriptorProto*)enumTypeAtIndex:(NSUInteger)index { return [enumTypeArray objectAtIndex:index]; } - (PBArray *)extensionRange { return extensionRangeArray; } - (PBDescriptorProto_ExtensionRange*)extensionRangeAtIndex:(NSUInteger)index { return [extensionRangeArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBFieldDescriptorProto* element in self.field) { if (!element.isInitialized) { return NO; } } for (PBFieldDescriptorProto* element in self.extension) { if (!element.isInitialized) { return NO; } } for (PBDescriptorProto* element in self.nestedType) { if (!element.isInitialized) { return NO; } } for (PBEnumDescriptorProto* element in self.enumType) { if (!element.isInitialized) { return NO; } } if (self.hasOptions) { if (!self.options.isInitialized) { return NO; } } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { if (self.hasName) { [output writeString:1 value:self.name]; } for (PBFieldDescriptorProto *element in self.fieldArray) { [output writeMessage:2 value:element]; } for (PBDescriptorProto *element in self.nestedTypeArray) { [output writeMessage:3 value:element]; } for (PBEnumDescriptorProto *element in self.enumTypeArray) { [output writeMessage:4 value:element]; } for (PBDescriptorProto_ExtensionRange *element in self.extensionRangeArray) { [output writeMessage:5 value:element]; } for (PBFieldDescriptorProto *element in self.extensionArray) { [output writeMessage:6 value:element]; } if (self.hasOptions) { [output writeMessage:7 value:self.options]; } [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; if (self.hasName) { size += computeStringSize(1, self.name); } for (PBFieldDescriptorProto *element in self.fieldArray) { size += computeMessageSize(2, element); } for (PBDescriptorProto *element in self.nestedTypeArray) { size += computeMessageSize(3, element); } for (PBEnumDescriptorProto *element in self.enumTypeArray) { size += computeMessageSize(4, element); } for (PBDescriptorProto_ExtensionRange *element in self.extensionRangeArray) { size += computeMessageSize(5, element); } for (PBFieldDescriptorProto *element in self.extensionArray) { size += computeMessageSize(6, element); } if (self.hasOptions) { size += computeMessageSize(7, self.options); } size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBDescriptorProto*) parseFromData:(NSData*) data { return (PBDescriptorProto*)[[[PBDescriptorProto builder] mergeFromData:data] build]; } + (PBDescriptorProto*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBDescriptorProto*)[[[PBDescriptorProto builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBDescriptorProto*) parseFromInputStream:(NSInputStream*) input { return (PBDescriptorProto*)[[[PBDescriptorProto builder] mergeFromInputStream:input] build]; } + (PBDescriptorProto*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBDescriptorProto*)[[[PBDescriptorProto builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBDescriptorProto*)[[[PBDescriptorProto builder] mergeFromCodedInputStream:input] build]; } + (PBDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBDescriptorProto*)[[[PBDescriptorProto builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBDescriptorProto_Builder*) builder { return [[[PBDescriptorProto_Builder alloc] init] autorelease]; } + (PBDescriptorProto_Builder*) builderWithPrototype:(PBDescriptorProto*) prototype { return [[PBDescriptorProto builder] mergeFrom:prototype]; } - (PBDescriptorProto_Builder*) builder { return [PBDescriptorProto builder]; } @end @interface PBDescriptorProto_ExtensionRange () @property int32_t start; @property int32_t end; @end @implementation PBDescriptorProto_ExtensionRange - (BOOL) hasStart { return !!hasStart_; } - (void) setHasStart:(BOOL) value { hasStart_ = !!value; } @synthesize start; - (BOOL) hasEnd { return !!hasEnd_; } - (void) setHasEnd:(BOOL) value { hasEnd_ = !!value; } @synthesize end; - (void) dealloc { [super dealloc]; } - (id) init { if ((self = [super init])) { self.start = 0; self.end = 0; } return self; } static PBDescriptorProto_ExtensionRange* defaultPBDescriptorProto_ExtensionRangeInstance = nil; + (void) initialize { if (self == [PBDescriptorProto_ExtensionRange class]) { defaultPBDescriptorProto_ExtensionRangeInstance = [[PBDescriptorProto_ExtensionRange alloc] init]; } } + (PBDescriptorProto_ExtensionRange*) defaultInstance { return defaultPBDescriptorProto_ExtensionRangeInstance; } - (PBDescriptorProto_ExtensionRange*) defaultInstance { return defaultPBDescriptorProto_ExtensionRangeInstance; } - (BOOL) isInitialized { return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { if (self.hasStart) { [output writeInt32:1 value:self.start]; } if (self.hasEnd) { [output writeInt32:2 value:self.end]; } [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; if (self.hasStart) { size += computeInt32Size(1, self.start); } if (self.hasEnd) { size += computeInt32Size(2, self.end); } size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBDescriptorProto_ExtensionRange*) parseFromData:(NSData*) data { return (PBDescriptorProto_ExtensionRange*)[[[PBDescriptorProto_ExtensionRange builder] mergeFromData:data] build]; } + (PBDescriptorProto_ExtensionRange*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBDescriptorProto_ExtensionRange*)[[[PBDescriptorProto_ExtensionRange builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBDescriptorProto_ExtensionRange*) parseFromInputStream:(NSInputStream*) input { return (PBDescriptorProto_ExtensionRange*)[[[PBDescriptorProto_ExtensionRange builder] mergeFromInputStream:input] build]; } + (PBDescriptorProto_ExtensionRange*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBDescriptorProto_ExtensionRange*)[[[PBDescriptorProto_ExtensionRange builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBDescriptorProto_ExtensionRange*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBDescriptorProto_ExtensionRange*)[[[PBDescriptorProto_ExtensionRange builder] mergeFromCodedInputStream:input] build]; } + (PBDescriptorProto_ExtensionRange*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBDescriptorProto_ExtensionRange*)[[[PBDescriptorProto_ExtensionRange builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBDescriptorProto_ExtensionRange_Builder*) builder { return [[[PBDescriptorProto_ExtensionRange_Builder alloc] init] autorelease]; } + (PBDescriptorProto_ExtensionRange_Builder*) builderWithPrototype:(PBDescriptorProto_ExtensionRange*) prototype { return [[PBDescriptorProto_ExtensionRange builder] mergeFrom:prototype]; } - (PBDescriptorProto_ExtensionRange_Builder*) builder { return [PBDescriptorProto_ExtensionRange builder]; } @end @interface PBDescriptorProto_ExtensionRange_Builder() @property (retain) PBDescriptorProto_ExtensionRange* result; @end @implementation PBDescriptorProto_ExtensionRange_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBDescriptorProto_ExtensionRange alloc] init] autorelease]; } return self; } - (PBGeneratedMessage*) internalGetResult { return result; } - (PBDescriptorProto_ExtensionRange_Builder*) clear { self.result = [[[PBDescriptorProto_ExtensionRange alloc] init] autorelease]; return self; } - (PBDescriptorProto_ExtensionRange_Builder*) clone { return [PBDescriptorProto_ExtensionRange builderWithPrototype:result]; } - (PBDescriptorProto_ExtensionRange*) defaultInstance { return [PBDescriptorProto_ExtensionRange defaultInstance]; } - (PBDescriptorProto_ExtensionRange*) build { [self checkInitialized]; return [self buildPartial]; } - (PBDescriptorProto_ExtensionRange*) buildPartial { PBDescriptorProto_ExtensionRange* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBDescriptorProto_ExtensionRange_Builder*) mergeFrom:(PBDescriptorProto_ExtensionRange*) other { if (other == [PBDescriptorProto_ExtensionRange defaultInstance]) { return self; } if (other.hasStart) { [self setStart:other.start]; } if (other.hasEnd) { [self setEnd:other.end]; } [self mergeUnknownFields:other.unknownFields]; return self; } - (PBDescriptorProto_ExtensionRange_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBDescriptorProto_ExtensionRange_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 8: { [self setStart:[input readInt32]]; break; } case 16: { [self setEnd:[input readInt32]]; break; } } } } - (BOOL) hasStart { return result.hasStart; } - (int32_t) start { return result.start; } - (PBDescriptorProto_ExtensionRange_Builder*) setStart:(int32_t) value { result.hasStart = YES; result.start = value; return self; } - (PBDescriptorProto_ExtensionRange_Builder*) clearStart { result.hasStart = NO; result.start = 0; return self; } - (BOOL) hasEnd { return result.hasEnd; } - (int32_t) end { return result.end; } - (PBDescriptorProto_ExtensionRange_Builder*) setEnd:(int32_t) value { result.hasEnd = YES; result.end = value; return self; } - (PBDescriptorProto_ExtensionRange_Builder*) clearEnd { result.hasEnd = NO; result.end = 0; return self; } @end @interface PBDescriptorProto_Builder() @property (retain) PBDescriptorProto* result; @end @implementation PBDescriptorProto_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBDescriptorProto alloc] init] autorelease]; } return self; } - (PBGeneratedMessage*) internalGetResult { return result; } - (PBDescriptorProto_Builder*) clear { self.result = [[[PBDescriptorProto alloc] init] autorelease]; return self; } - (PBDescriptorProto_Builder*) clone { return [PBDescriptorProto builderWithPrototype:result]; } - (PBDescriptorProto*) defaultInstance { return [PBDescriptorProto defaultInstance]; } - (PBDescriptorProto*) build { [self checkInitialized]; return [self buildPartial]; } - (PBDescriptorProto*) buildPartial { PBDescriptorProto* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBDescriptorProto_Builder*) mergeFrom:(PBDescriptorProto*) other { if (other == [PBDescriptorProto defaultInstance]) { return self; } if (other.hasName) { [self setName:other.name]; } if (other.fieldArray.count > 0) { if (result.fieldArray == nil) { result.fieldArray = [other.fieldArray copyWithZone:[other.fieldArray zone]]; } else { [result.fieldArray appendArray:other.fieldArray]; } } if (other.extensionArray.count > 0) { if (result.extensionArray == nil) { result.extensionArray = [other.extensionArray copyWithZone:[other.extensionArray zone]]; } else { [result.extensionArray appendArray:other.extensionArray]; } } if (other.nestedTypeArray.count > 0) { if (result.nestedTypeArray == nil) { result.nestedTypeArray = [other.nestedTypeArray copyWithZone:[other.nestedTypeArray zone]]; } else { [result.nestedTypeArray appendArray:other.nestedTypeArray]; } } if (other.enumTypeArray.count > 0) { if (result.enumTypeArray == nil) { result.enumTypeArray = [other.enumTypeArray copyWithZone:[other.enumTypeArray zone]]; } else { [result.enumTypeArray appendArray:other.enumTypeArray]; } } if (other.extensionRangeArray.count > 0) { if (result.extensionRangeArray == nil) { result.extensionRangeArray = [other.extensionRangeArray copyWithZone:[other.extensionRangeArray zone]]; } else { [result.extensionRangeArray appendArray:other.extensionRangeArray]; } } if (other.hasOptions) { [self mergeOptions:other.options]; } [self mergeUnknownFields:other.unknownFields]; return self; } - (PBDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 10: { [self setName:[input readString]]; break; } case 18: { PBFieldDescriptorProto_Builder* subBuilder = [PBFieldDescriptorProto builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addField:[subBuilder buildPartial]]; break; } case 26: { PBDescriptorProto_Builder* subBuilder = [PBDescriptorProto builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addNestedType:[subBuilder buildPartial]]; break; } case 34: { PBEnumDescriptorProto_Builder* subBuilder = [PBEnumDescriptorProto builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addEnumType:[subBuilder buildPartial]]; break; } case 42: { PBDescriptorProto_ExtensionRange_Builder* subBuilder = [PBDescriptorProto_ExtensionRange builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addExtensionRange:[subBuilder buildPartial]]; break; } case 50: { PBFieldDescriptorProto_Builder* subBuilder = [PBFieldDescriptorProto builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addExtension:[subBuilder buildPartial]]; break; } case 58: { PBMessageOptions_Builder* subBuilder = [PBMessageOptions builder]; if (self.hasOptions) { [subBuilder mergeFrom:self.options]; } [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self setOptions:[subBuilder buildPartial]]; break; } } } } - (BOOL) hasName { return result.hasName; } - (NSString*) name { return result.name; } - (PBDescriptorProto_Builder*) setName:(NSString*) value { result.hasName = YES; result.name = value; return self; } - (PBDescriptorProto_Builder*) clearName { result.hasName = NO; result.name = @""; return self; } - (PBAppendableArray *)field { return result.fieldArray; } - (PBFieldDescriptorProto*)fieldAtIndex:(NSUInteger)index { return [result fieldAtIndex:index]; } - (PBDescriptorProto_Builder *)addField:(PBFieldDescriptorProto*)value { if (result.fieldArray == nil) { result.fieldArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.fieldArray addObject:value]; return self; } - (PBDescriptorProto_Builder *)setFieldArray:(NSArray *)array { result.fieldArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBDescriptorProto_Builder *)setFieldValues:(const PBFieldDescriptorProto* *)values count:(NSUInteger)count { result.fieldArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBDescriptorProto_Builder *)clearField { result.fieldArray = nil; return self; } - (PBAppendableArray *)extension { return result.extensionArray; } - (PBFieldDescriptorProto*)extensionAtIndex:(NSUInteger)index { return [result extensionAtIndex:index]; } - (PBDescriptorProto_Builder *)addExtension:(PBFieldDescriptorProto*)value { if (result.extensionArray == nil) { result.extensionArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.extensionArray addObject:value]; return self; } - (PBDescriptorProto_Builder *)setExtensionArray:(NSArray *)array { result.extensionArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBDescriptorProto_Builder *)setExtensionValues:(const PBFieldDescriptorProto* *)values count:(NSUInteger)count { result.extensionArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBDescriptorProto_Builder *)clearExtension { result.extensionArray = nil; return self; } - (PBAppendableArray *)nestedType { return result.nestedTypeArray; } - (PBDescriptorProto*)nestedTypeAtIndex:(NSUInteger)index { return [result nestedTypeAtIndex:index]; } - (PBDescriptorProto_Builder *)addNestedType:(PBDescriptorProto*)value { if (result.nestedTypeArray == nil) { result.nestedTypeArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.nestedTypeArray addObject:value]; return self; } - (PBDescriptorProto_Builder *)setNestedTypeArray:(NSArray *)array { result.nestedTypeArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBDescriptorProto_Builder *)setNestedTypeValues:(const PBDescriptorProto* *)values count:(NSUInteger)count { result.nestedTypeArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBDescriptorProto_Builder *)clearNestedType { result.nestedTypeArray = nil; return self; } - (PBAppendableArray *)enumType { return result.enumTypeArray; } - (PBEnumDescriptorProto*)enumTypeAtIndex:(NSUInteger)index { return [result enumTypeAtIndex:index]; } - (PBDescriptorProto_Builder *)addEnumType:(PBEnumDescriptorProto*)value { if (result.enumTypeArray == nil) { result.enumTypeArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.enumTypeArray addObject:value]; return self; } - (PBDescriptorProto_Builder *)setEnumTypeArray:(NSArray *)array { result.enumTypeArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBDescriptorProto_Builder *)setEnumTypeValues:(const PBEnumDescriptorProto* *)values count:(NSUInteger)count { result.enumTypeArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBDescriptorProto_Builder *)clearEnumType { result.enumTypeArray = nil; return self; } - (PBAppendableArray *)extensionRange { return result.extensionRangeArray; } - (PBDescriptorProto_ExtensionRange*)extensionRangeAtIndex:(NSUInteger)index { return [result extensionRangeAtIndex:index]; } - (PBDescriptorProto_Builder *)addExtensionRange:(PBDescriptorProto_ExtensionRange*)value { if (result.extensionRangeArray == nil) { result.extensionRangeArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.extensionRangeArray addObject:value]; return self; } - (PBDescriptorProto_Builder *)setExtensionRangeArray:(NSArray *)array { result.extensionRangeArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBDescriptorProto_Builder *)setExtensionRangeValues:(const PBDescriptorProto_ExtensionRange* *)values count:(NSUInteger)count { result.extensionRangeArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBDescriptorProto_Builder *)clearExtensionRange { result.extensionRangeArray = nil; return self; } - (BOOL) hasOptions { return result.hasOptions; } - (PBMessageOptions*) options { return result.options; } - (PBDescriptorProto_Builder*) setOptions:(PBMessageOptions*) value { result.hasOptions = YES; result.options = value; return self; } - (PBDescriptorProto_Builder*) setOptionsBuilder:(PBMessageOptions_Builder*) builderForValue { return [self setOptions:[builderForValue build]]; } - (PBDescriptorProto_Builder*) mergeOptions:(PBMessageOptions*) value { if (result.hasOptions && result.options != [PBMessageOptions defaultInstance]) { result.options = [[[PBMessageOptions builderWithPrototype:result.options] mergeFrom:value] buildPartial]; } else { result.options = value; } result.hasOptions = YES; return self; } - (PBDescriptorProto_Builder*) clearOptions { result.hasOptions = NO; result.options = [PBMessageOptions defaultInstance]; return self; } @end @interface PBFieldDescriptorProto () @property (retain) NSString* name; @property int32_t number; @property PBFieldDescriptorProto_Label label; @property PBFieldDescriptorProto_Type type; @property (retain) NSString* typeName; @property (retain) NSString* extendee; @property (retain) NSString* defaultValue; @property (retain) PBFieldOptions* options; @end @implementation PBFieldDescriptorProto - (BOOL) hasName { return !!hasName_; } - (void) setHasName:(BOOL) value { hasName_ = !!value; } @synthesize name; - (BOOL) hasNumber { return !!hasNumber_; } - (void) setHasNumber:(BOOL) value { hasNumber_ = !!value; } @synthesize number; - (BOOL) hasLabel { return !!hasLabel_; } - (void) setHasLabel:(BOOL) value { hasLabel_ = !!value; } @synthesize label; - (BOOL) hasType { return !!hasType_; } - (void) setHasType:(BOOL) value { hasType_ = !!value; } @synthesize type; - (BOOL) hasTypeName { return !!hasTypeName_; } - (void) setHasTypeName:(BOOL) value { hasTypeName_ = !!value; } @synthesize typeName; - (BOOL) hasExtendee { return !!hasExtendee_; } - (void) setHasExtendee:(BOOL) value { hasExtendee_ = !!value; } @synthesize extendee; - (BOOL) hasDefaultValue { return !!hasDefaultValue_; } - (void) setHasDefaultValue:(BOOL) value { hasDefaultValue_ = !!value; } @synthesize defaultValue; - (BOOL) hasOptions { return !!hasOptions_; } - (void) setHasOptions:(BOOL) value { hasOptions_ = !!value; } @synthesize options; - (void) dealloc { self.name = nil; self.typeName = nil; self.extendee = nil; self.defaultValue = nil; self.options = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.name = @""; self.number = 0; self.label = PBFieldDescriptorProto_LabelLabelOptional; self.type = PBFieldDescriptorProto_TypeTypeDouble; self.typeName = @""; self.extendee = @""; self.defaultValue = @""; self.options = [PBFieldOptions defaultInstance]; } return self; } static PBFieldDescriptorProto* defaultPBFieldDescriptorProtoInstance = nil; + (void) initialize { if (self == [PBFieldDescriptorProto class]) { defaultPBFieldDescriptorProtoInstance = [[PBFieldDescriptorProto alloc] init]; } } + (PBFieldDescriptorProto*) defaultInstance { return defaultPBFieldDescriptorProtoInstance; } - (PBFieldDescriptorProto*) defaultInstance { return defaultPBFieldDescriptorProtoInstance; } - (BOOL) isInitialized { if (self.hasOptions) { if (!self.options.isInitialized) { return NO; } } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { if (self.hasName) { [output writeString:1 value:self.name]; } if (self.hasExtendee) { [output writeString:2 value:self.extendee]; } if (self.hasNumber) { [output writeInt32:3 value:self.number]; } if (self.hasLabel) { [output writeEnum:4 value:self.label]; } if (self.hasType) { [output writeEnum:5 value:self.type]; } if (self.hasTypeName) { [output writeString:6 value:self.typeName]; } if (self.hasDefaultValue) { [output writeString:7 value:self.defaultValue]; } if (self.hasOptions) { [output writeMessage:8 value:self.options]; } [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; if (self.hasName) { size += computeStringSize(1, self.name); } if (self.hasExtendee) { size += computeStringSize(2, self.extendee); } if (self.hasNumber) { size += computeInt32Size(3, self.number); } if (self.hasLabel) { size += computeEnumSize(4, self.label); } if (self.hasType) { size += computeEnumSize(5, self.type); } if (self.hasTypeName) { size += computeStringSize(6, self.typeName); } if (self.hasDefaultValue) { size += computeStringSize(7, self.defaultValue); } if (self.hasOptions) { size += computeMessageSize(8, self.options); } size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBFieldDescriptorProto*) parseFromData:(NSData*) data { return (PBFieldDescriptorProto*)[[[PBFieldDescriptorProto builder] mergeFromData:data] build]; } + (PBFieldDescriptorProto*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFieldDescriptorProto*)[[[PBFieldDescriptorProto builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBFieldDescriptorProto*) parseFromInputStream:(NSInputStream*) input { return (PBFieldDescriptorProto*)[[[PBFieldDescriptorProto builder] mergeFromInputStream:input] build]; } + (PBFieldDescriptorProto*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFieldDescriptorProto*)[[[PBFieldDescriptorProto builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBFieldDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBFieldDescriptorProto*)[[[PBFieldDescriptorProto builder] mergeFromCodedInputStream:input] build]; } + (PBFieldDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFieldDescriptorProto*)[[[PBFieldDescriptorProto builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBFieldDescriptorProto_Builder*) builder { return [[[PBFieldDescriptorProto_Builder alloc] init] autorelease]; } + (PBFieldDescriptorProto_Builder*) builderWithPrototype:(PBFieldDescriptorProto*) prototype { return [[PBFieldDescriptorProto builder] mergeFrom:prototype]; } - (PBFieldDescriptorProto_Builder*) builder { return [PBFieldDescriptorProto builder]; } @end BOOL PBFieldDescriptorProto_TypeIsValidValue(PBFieldDescriptorProto_Type value) { switch (value) { case PBFieldDescriptorProto_TypeTypeDouble: case PBFieldDescriptorProto_TypeTypeFloat: case PBFieldDescriptorProto_TypeTypeInt64: case PBFieldDescriptorProto_TypeTypeUint64: case PBFieldDescriptorProto_TypeTypeInt32: case PBFieldDescriptorProto_TypeTypeFixed64: case PBFieldDescriptorProto_TypeTypeFixed32: case PBFieldDescriptorProto_TypeTypeBool: case PBFieldDescriptorProto_TypeTypeString: case PBFieldDescriptorProto_TypeTypeGroup: case PBFieldDescriptorProto_TypeTypeMessage: case PBFieldDescriptorProto_TypeTypeBytes: case PBFieldDescriptorProto_TypeTypeUint32: case PBFieldDescriptorProto_TypeTypeEnum: case PBFieldDescriptorProto_TypeTypeSfixed32: case PBFieldDescriptorProto_TypeTypeSfixed64: case PBFieldDescriptorProto_TypeTypeSint32: case PBFieldDescriptorProto_TypeTypeSint64: return YES; default: return NO; } } BOOL PBFieldDescriptorProto_LabelIsValidValue(PBFieldDescriptorProto_Label value) { switch (value) { case PBFieldDescriptorProto_LabelLabelOptional: case PBFieldDescriptorProto_LabelLabelRequired: case PBFieldDescriptorProto_LabelLabelRepeated: return YES; default: return NO; } } @interface PBFieldDescriptorProto_Builder() @property (retain) PBFieldDescriptorProto* result; @end @implementation PBFieldDescriptorProto_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBFieldDescriptorProto alloc] init] autorelease]; } return self; } - (PBGeneratedMessage*) internalGetResult { return result; } - (PBFieldDescriptorProto_Builder*) clear { self.result = [[[PBFieldDescriptorProto alloc] init] autorelease]; return self; } - (PBFieldDescriptorProto_Builder*) clone { return [PBFieldDescriptorProto builderWithPrototype:result]; } - (PBFieldDescriptorProto*) defaultInstance { return [PBFieldDescriptorProto defaultInstance]; } - (PBFieldDescriptorProto*) build { [self checkInitialized]; return [self buildPartial]; } - (PBFieldDescriptorProto*) buildPartial { PBFieldDescriptorProto* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBFieldDescriptorProto_Builder*) mergeFrom:(PBFieldDescriptorProto*) other { if (other == [PBFieldDescriptorProto defaultInstance]) { return self; } if (other.hasName) { [self setName:other.name]; } if (other.hasNumber) { [self setNumber:other.number]; } if (other.hasLabel) { [self setLabel:other.label]; } if (other.hasType) { [self setType:other.type]; } if (other.hasTypeName) { [self setTypeName:other.typeName]; } if (other.hasExtendee) { [self setExtendee:other.extendee]; } if (other.hasDefaultValue) { [self setDefaultValue:other.defaultValue]; } if (other.hasOptions) { [self mergeOptions:other.options]; } [self mergeUnknownFields:other.unknownFields]; return self; } - (PBFieldDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBFieldDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 10: { [self setName:[input readString]]; break; } case 18: { [self setExtendee:[input readString]]; break; } case 24: { [self setNumber:[input readInt32]]; break; } case 32: { int32_t value = [input readEnum]; if (PBFieldDescriptorProto_LabelIsValidValue(value)) { [self setLabel:value]; } else { [unknownFields mergeVarintField:4 value:value]; } break; } case 40: { int32_t value = [input readEnum]; if (PBFieldDescriptorProto_TypeIsValidValue(value)) { [self setType:value]; } else { [unknownFields mergeVarintField:5 value:value]; } break; } case 50: { [self setTypeName:[input readString]]; break; } case 58: { [self setDefaultValue:[input readString]]; break; } case 66: { PBFieldOptions_Builder* subBuilder = [PBFieldOptions builder]; if (self.hasOptions) { [subBuilder mergeFrom:self.options]; } [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self setOptions:[subBuilder buildPartial]]; break; } } } } - (BOOL) hasName { return result.hasName; } - (NSString*) name { return result.name; } - (PBFieldDescriptorProto_Builder*) setName:(NSString*) value { result.hasName = YES; result.name = value; return self; } - (PBFieldDescriptorProto_Builder*) clearName { result.hasName = NO; result.name = @""; return self; } - (BOOL) hasNumber { return result.hasNumber; } - (int32_t) number { return result.number; } - (PBFieldDescriptorProto_Builder*) setNumber:(int32_t) value { result.hasNumber = YES; result.number = value; return self; } - (PBFieldDescriptorProto_Builder*) clearNumber { result.hasNumber = NO; result.number = 0; return self; } - (BOOL) hasLabel { return result.hasLabel; } - (PBFieldDescriptorProto_Label) label { return result.label; } - (PBFieldDescriptorProto_Builder*) setLabel:(PBFieldDescriptorProto_Label) value { result.hasLabel = YES; result.label = value; return self; } - (PBFieldDescriptorProto_Builder*) clearLabel { result.hasLabel = NO; result.label = PBFieldDescriptorProto_LabelLabelOptional; return self; } - (BOOL) hasType { return result.hasType; } - (PBFieldDescriptorProto_Type) type { return result.type; } - (PBFieldDescriptorProto_Builder*) setType:(PBFieldDescriptorProto_Type) value { result.hasType = YES; result.type = value; return self; } - (PBFieldDescriptorProto_Builder*) clearType { result.hasType = NO; result.type = PBFieldDescriptorProto_TypeTypeDouble; return self; } - (BOOL) hasTypeName { return result.hasTypeName; } - (NSString*) typeName { return result.typeName; } - (PBFieldDescriptorProto_Builder*) setTypeName:(NSString*) value { result.hasTypeName = YES; result.typeName = value; return self; } - (PBFieldDescriptorProto_Builder*) clearTypeName { result.hasTypeName = NO; result.typeName = @""; return self; } - (BOOL) hasExtendee { return result.hasExtendee; } - (NSString*) extendee { return result.extendee; } - (PBFieldDescriptorProto_Builder*) setExtendee:(NSString*) value { result.hasExtendee = YES; result.extendee = value; return self; } - (PBFieldDescriptorProto_Builder*) clearExtendee { result.hasExtendee = NO; result.extendee = @""; return self; } - (BOOL) hasDefaultValue { return result.hasDefaultValue; } - (NSString*) defaultValue { return result.defaultValue; } - (PBFieldDescriptorProto_Builder*) setDefaultValue:(NSString*) value { result.hasDefaultValue = YES; result.defaultValue = value; return self; } - (PBFieldDescriptorProto_Builder*) clearDefaultValue { result.hasDefaultValue = NO; result.defaultValue = @""; return self; } - (BOOL) hasOptions { return result.hasOptions; } - (PBFieldOptions*) options { return result.options; } - (PBFieldDescriptorProto_Builder*) setOptions:(PBFieldOptions*) value { result.hasOptions = YES; result.options = value; return self; } - (PBFieldDescriptorProto_Builder*) setOptionsBuilder:(PBFieldOptions_Builder*) builderForValue { return [self setOptions:[builderForValue build]]; } - (PBFieldDescriptorProto_Builder*) mergeOptions:(PBFieldOptions*) value { if (result.hasOptions && result.options != [PBFieldOptions defaultInstance]) { result.options = [[[PBFieldOptions builderWithPrototype:result.options] mergeFrom:value] buildPartial]; } else { result.options = value; } result.hasOptions = YES; return self; } - (PBFieldDescriptorProto_Builder*) clearOptions { result.hasOptions = NO; result.options = [PBFieldOptions defaultInstance]; return self; } @end @interface PBEnumDescriptorProto () @property (retain) NSString* name; @property (retain) PBAppendableArray * valueArray; @property (retain) PBEnumOptions* options; @end @implementation PBEnumDescriptorProto - (BOOL) hasName { return !!hasName_; } - (void) setHasName:(BOOL) value { hasName_ = !!value; } @synthesize name; @synthesize valueArray; @dynamic value; - (BOOL) hasOptions { return !!hasOptions_; } - (void) setHasOptions:(BOOL) value { hasOptions_ = !!value; } @synthesize options; - (void) dealloc { self.name = nil; self.valueArray = nil; self.options = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.name = @""; self.options = [PBEnumOptions defaultInstance]; } return self; } static PBEnumDescriptorProto* defaultPBEnumDescriptorProtoInstance = nil; + (void) initialize { if (self == [PBEnumDescriptorProto class]) { defaultPBEnumDescriptorProtoInstance = [[PBEnumDescriptorProto alloc] init]; } } + (PBEnumDescriptorProto*) defaultInstance { return defaultPBEnumDescriptorProtoInstance; } - (PBEnumDescriptorProto*) defaultInstance { return defaultPBEnumDescriptorProtoInstance; } - (PBArray *)value { return valueArray; } - (PBEnumValueDescriptorProto*)valueAtIndex:(NSUInteger)index { return [valueArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBEnumValueDescriptorProto* element in self.value) { if (!element.isInitialized) { return NO; } } if (self.hasOptions) { if (!self.options.isInitialized) { return NO; } } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { if (self.hasName) { [output writeString:1 value:self.name]; } for (PBEnumValueDescriptorProto *element in self.valueArray) { [output writeMessage:2 value:element]; } if (self.hasOptions) { [output writeMessage:3 value:self.options]; } [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; if (self.hasName) { size += computeStringSize(1, self.name); } for (PBEnumValueDescriptorProto *element in self.valueArray) { size += computeMessageSize(2, element); } if (self.hasOptions) { size += computeMessageSize(3, self.options); } size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBEnumDescriptorProto*) parseFromData:(NSData*) data { return (PBEnumDescriptorProto*)[[[PBEnumDescriptorProto builder] mergeFromData:data] build]; } + (PBEnumDescriptorProto*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBEnumDescriptorProto*)[[[PBEnumDescriptorProto builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBEnumDescriptorProto*) parseFromInputStream:(NSInputStream*) input { return (PBEnumDescriptorProto*)[[[PBEnumDescriptorProto builder] mergeFromInputStream:input] build]; } + (PBEnumDescriptorProto*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBEnumDescriptorProto*)[[[PBEnumDescriptorProto builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBEnumDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBEnumDescriptorProto*)[[[PBEnumDescriptorProto builder] mergeFromCodedInputStream:input] build]; } + (PBEnumDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBEnumDescriptorProto*)[[[PBEnumDescriptorProto builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBEnumDescriptorProto_Builder*) builder { return [[[PBEnumDescriptorProto_Builder alloc] init] autorelease]; } + (PBEnumDescriptorProto_Builder*) builderWithPrototype:(PBEnumDescriptorProto*) prototype { return [[PBEnumDescriptorProto builder] mergeFrom:prototype]; } - (PBEnumDescriptorProto_Builder*) builder { return [PBEnumDescriptorProto builder]; } @end @interface PBEnumDescriptorProto_Builder() @property (retain) PBEnumDescriptorProto* result; @end @implementation PBEnumDescriptorProto_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBEnumDescriptorProto alloc] init] autorelease]; } return self; } - (PBGeneratedMessage*) internalGetResult { return result; } - (PBEnumDescriptorProto_Builder*) clear { self.result = [[[PBEnumDescriptorProto alloc] init] autorelease]; return self; } - (PBEnumDescriptorProto_Builder*) clone { return [PBEnumDescriptorProto builderWithPrototype:result]; } - (PBEnumDescriptorProto*) defaultInstance { return [PBEnumDescriptorProto defaultInstance]; } - (PBEnumDescriptorProto*) build { [self checkInitialized]; return [self buildPartial]; } - (PBEnumDescriptorProto*) buildPartial { PBEnumDescriptorProto* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBEnumDescriptorProto_Builder*) mergeFrom:(PBEnumDescriptorProto*) other { if (other == [PBEnumDescriptorProto defaultInstance]) { return self; } if (other.hasName) { [self setName:other.name]; } if (other.valueArray.count > 0) { if (result.valueArray == nil) { result.valueArray = [other.valueArray copyWithZone:[other.valueArray zone]]; } else { [result.valueArray appendArray:other.valueArray]; } } if (other.hasOptions) { [self mergeOptions:other.options]; } [self mergeUnknownFields:other.unknownFields]; return self; } - (PBEnumDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBEnumDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 10: { [self setName:[input readString]]; break; } case 18: { PBEnumValueDescriptorProto_Builder* subBuilder = [PBEnumValueDescriptorProto builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addValue:[subBuilder buildPartial]]; break; } case 26: { PBEnumOptions_Builder* subBuilder = [PBEnumOptions builder]; if (self.hasOptions) { [subBuilder mergeFrom:self.options]; } [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self setOptions:[subBuilder buildPartial]]; break; } } } } - (BOOL) hasName { return result.hasName; } - (NSString*) name { return result.name; } - (PBEnumDescriptorProto_Builder*) setName:(NSString*) value { result.hasName = YES; result.name = value; return self; } - (PBEnumDescriptorProto_Builder*) clearName { result.hasName = NO; result.name = @""; return self; } - (PBAppendableArray *)value { return result.valueArray; } - (PBEnumValueDescriptorProto*)valueAtIndex:(NSUInteger)index { return [result valueAtIndex:index]; } - (PBEnumDescriptorProto_Builder *)addValue:(PBEnumValueDescriptorProto*)value { if (result.valueArray == nil) { result.valueArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.valueArray addObject:value]; return self; } - (PBEnumDescriptorProto_Builder *)setValueArray:(NSArray *)array { result.valueArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBEnumDescriptorProto_Builder *)setValueValues:(const PBEnumValueDescriptorProto* *)values count:(NSUInteger)count { result.valueArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBEnumDescriptorProto_Builder *)clearValue { result.valueArray = nil; return self; } - (BOOL) hasOptions { return result.hasOptions; } - (PBEnumOptions*) options { return result.options; } - (PBEnumDescriptorProto_Builder*) setOptions:(PBEnumOptions*) value { result.hasOptions = YES; result.options = value; return self; } - (PBEnumDescriptorProto_Builder*) setOptionsBuilder:(PBEnumOptions_Builder*) builderForValue { return [self setOptions:[builderForValue build]]; } - (PBEnumDescriptorProto_Builder*) mergeOptions:(PBEnumOptions*) value { if (result.hasOptions && result.options != [PBEnumOptions defaultInstance]) { result.options = [[[PBEnumOptions builderWithPrototype:result.options] mergeFrom:value] buildPartial]; } else { result.options = value; } result.hasOptions = YES; return self; } - (PBEnumDescriptorProto_Builder*) clearOptions { result.hasOptions = NO; result.options = [PBEnumOptions defaultInstance]; return self; } @end @interface PBEnumValueDescriptorProto () @property (retain) NSString* name; @property int32_t number; @property (retain) PBEnumValueOptions* options; @end @implementation PBEnumValueDescriptorProto - (BOOL) hasName { return !!hasName_; } - (void) setHasName:(BOOL) value { hasName_ = !!value; } @synthesize name; - (BOOL) hasNumber { return !!hasNumber_; } - (void) setHasNumber:(BOOL) value { hasNumber_ = !!value; } @synthesize number; - (BOOL) hasOptions { return !!hasOptions_; } - (void) setHasOptions:(BOOL) value { hasOptions_ = !!value; } @synthesize options; - (void) dealloc { self.name = nil; self.options = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.name = @""; self.number = 0; self.options = [PBEnumValueOptions defaultInstance]; } return self; } static PBEnumValueDescriptorProto* defaultPBEnumValueDescriptorProtoInstance = nil; + (void) initialize { if (self == [PBEnumValueDescriptorProto class]) { defaultPBEnumValueDescriptorProtoInstance = [[PBEnumValueDescriptorProto alloc] init]; } } + (PBEnumValueDescriptorProto*) defaultInstance { return defaultPBEnumValueDescriptorProtoInstance; } - (PBEnumValueDescriptorProto*) defaultInstance { return defaultPBEnumValueDescriptorProtoInstance; } - (BOOL) isInitialized { if (self.hasOptions) { if (!self.options.isInitialized) { return NO; } } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { if (self.hasName) { [output writeString:1 value:self.name]; } if (self.hasNumber) { [output writeInt32:2 value:self.number]; } if (self.hasOptions) { [output writeMessage:3 value:self.options]; } [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; if (self.hasName) { size += computeStringSize(1, self.name); } if (self.hasNumber) { size += computeInt32Size(2, self.number); } if (self.hasOptions) { size += computeMessageSize(3, self.options); } size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBEnumValueDescriptorProto*) parseFromData:(NSData*) data { return (PBEnumValueDescriptorProto*)[[[PBEnumValueDescriptorProto builder] mergeFromData:data] build]; } + (PBEnumValueDescriptorProto*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBEnumValueDescriptorProto*)[[[PBEnumValueDescriptorProto builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBEnumValueDescriptorProto*) parseFromInputStream:(NSInputStream*) input { return (PBEnumValueDescriptorProto*)[[[PBEnumValueDescriptorProto builder] mergeFromInputStream:input] build]; } + (PBEnumValueDescriptorProto*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBEnumValueDescriptorProto*)[[[PBEnumValueDescriptorProto builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBEnumValueDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBEnumValueDescriptorProto*)[[[PBEnumValueDescriptorProto builder] mergeFromCodedInputStream:input] build]; } + (PBEnumValueDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBEnumValueDescriptorProto*)[[[PBEnumValueDescriptorProto builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBEnumValueDescriptorProto_Builder*) builder { return [[[PBEnumValueDescriptorProto_Builder alloc] init] autorelease]; } + (PBEnumValueDescriptorProto_Builder*) builderWithPrototype:(PBEnumValueDescriptorProto*) prototype { return [[PBEnumValueDescriptorProto builder] mergeFrom:prototype]; } - (PBEnumValueDescriptorProto_Builder*) builder { return [PBEnumValueDescriptorProto builder]; } @end @interface PBEnumValueDescriptorProto_Builder() @property (retain) PBEnumValueDescriptorProto* result; @end @implementation PBEnumValueDescriptorProto_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBEnumValueDescriptorProto alloc] init] autorelease]; } return self; } - (PBGeneratedMessage*) internalGetResult { return result; } - (PBEnumValueDescriptorProto_Builder*) clear { self.result = [[[PBEnumValueDescriptorProto alloc] init] autorelease]; return self; } - (PBEnumValueDescriptorProto_Builder*) clone { return [PBEnumValueDescriptorProto builderWithPrototype:result]; } - (PBEnumValueDescriptorProto*) defaultInstance { return [PBEnumValueDescriptorProto defaultInstance]; } - (PBEnumValueDescriptorProto*) build { [self checkInitialized]; return [self buildPartial]; } - (PBEnumValueDescriptorProto*) buildPartial { PBEnumValueDescriptorProto* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBEnumValueDescriptorProto_Builder*) mergeFrom:(PBEnumValueDescriptorProto*) other { if (other == [PBEnumValueDescriptorProto defaultInstance]) { return self; } if (other.hasName) { [self setName:other.name]; } if (other.hasNumber) { [self setNumber:other.number]; } if (other.hasOptions) { [self mergeOptions:other.options]; } [self mergeUnknownFields:other.unknownFields]; return self; } - (PBEnumValueDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBEnumValueDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 10: { [self setName:[input readString]]; break; } case 16: { [self setNumber:[input readInt32]]; break; } case 26: { PBEnumValueOptions_Builder* subBuilder = [PBEnumValueOptions builder]; if (self.hasOptions) { [subBuilder mergeFrom:self.options]; } [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self setOptions:[subBuilder buildPartial]]; break; } } } } - (BOOL) hasName { return result.hasName; } - (NSString*) name { return result.name; } - (PBEnumValueDescriptorProto_Builder*) setName:(NSString*) value { result.hasName = YES; result.name = value; return self; } - (PBEnumValueDescriptorProto_Builder*) clearName { result.hasName = NO; result.name = @""; return self; } - (BOOL) hasNumber { return result.hasNumber; } - (int32_t) number { return result.number; } - (PBEnumValueDescriptorProto_Builder*) setNumber:(int32_t) value { result.hasNumber = YES; result.number = value; return self; } - (PBEnumValueDescriptorProto_Builder*) clearNumber { result.hasNumber = NO; result.number = 0; return self; } - (BOOL) hasOptions { return result.hasOptions; } - (PBEnumValueOptions*) options { return result.options; } - (PBEnumValueDescriptorProto_Builder*) setOptions:(PBEnumValueOptions*) value { result.hasOptions = YES; result.options = value; return self; } - (PBEnumValueDescriptorProto_Builder*) setOptionsBuilder:(PBEnumValueOptions_Builder*) builderForValue { return [self setOptions:[builderForValue build]]; } - (PBEnumValueDescriptorProto_Builder*) mergeOptions:(PBEnumValueOptions*) value { if (result.hasOptions && result.options != [PBEnumValueOptions defaultInstance]) { result.options = [[[PBEnumValueOptions builderWithPrototype:result.options] mergeFrom:value] buildPartial]; } else { result.options = value; } result.hasOptions = YES; return self; } - (PBEnumValueDescriptorProto_Builder*) clearOptions { result.hasOptions = NO; result.options = [PBEnumValueOptions defaultInstance]; return self; } @end @interface PBServiceDescriptorProto () @property (retain) NSString* name; @property (retain) PBAppendableArray * methodArray; @property (retain) PBServiceOptions* options; @end @implementation PBServiceDescriptorProto - (BOOL) hasName { return !!hasName_; } - (void) setHasName:(BOOL) value { hasName_ = !!value; } @synthesize name; @synthesize methodArray; @dynamic method; - (BOOL) hasOptions { return !!hasOptions_; } - (void) setHasOptions:(BOOL) value { hasOptions_ = !!value; } @synthesize options; - (void) dealloc { self.name = nil; self.methodArray = nil; self.options = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.name = @""; self.options = [PBServiceOptions defaultInstance]; } return self; } static PBServiceDescriptorProto* defaultPBServiceDescriptorProtoInstance = nil; + (void) initialize { if (self == [PBServiceDescriptorProto class]) { defaultPBServiceDescriptorProtoInstance = [[PBServiceDescriptorProto alloc] init]; } } + (PBServiceDescriptorProto*) defaultInstance { return defaultPBServiceDescriptorProtoInstance; } - (PBServiceDescriptorProto*) defaultInstance { return defaultPBServiceDescriptorProtoInstance; } - (PBArray *)method { return methodArray; } - (PBMethodDescriptorProto*)methodAtIndex:(NSUInteger)index { return [methodArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBMethodDescriptorProto* element in self.method) { if (!element.isInitialized) { return NO; } } if (self.hasOptions) { if (!self.options.isInitialized) { return NO; } } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { if (self.hasName) { [output writeString:1 value:self.name]; } for (PBMethodDescriptorProto *element in self.methodArray) { [output writeMessage:2 value:element]; } if (self.hasOptions) { [output writeMessage:3 value:self.options]; } [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; if (self.hasName) { size += computeStringSize(1, self.name); } for (PBMethodDescriptorProto *element in self.methodArray) { size += computeMessageSize(2, element); } if (self.hasOptions) { size += computeMessageSize(3, self.options); } size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBServiceDescriptorProto*) parseFromData:(NSData*) data { return (PBServiceDescriptorProto*)[[[PBServiceDescriptorProto builder] mergeFromData:data] build]; } + (PBServiceDescriptorProto*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBServiceDescriptorProto*)[[[PBServiceDescriptorProto builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBServiceDescriptorProto*) parseFromInputStream:(NSInputStream*) input { return (PBServiceDescriptorProto*)[[[PBServiceDescriptorProto builder] mergeFromInputStream:input] build]; } + (PBServiceDescriptorProto*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBServiceDescriptorProto*)[[[PBServiceDescriptorProto builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBServiceDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBServiceDescriptorProto*)[[[PBServiceDescriptorProto builder] mergeFromCodedInputStream:input] build]; } + (PBServiceDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBServiceDescriptorProto*)[[[PBServiceDescriptorProto builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBServiceDescriptorProto_Builder*) builder { return [[[PBServiceDescriptorProto_Builder alloc] init] autorelease]; } + (PBServiceDescriptorProto_Builder*) builderWithPrototype:(PBServiceDescriptorProto*) prototype { return [[PBServiceDescriptorProto builder] mergeFrom:prototype]; } - (PBServiceDescriptorProto_Builder*) builder { return [PBServiceDescriptorProto builder]; } @end @interface PBServiceDescriptorProto_Builder() @property (retain) PBServiceDescriptorProto* result; @end @implementation PBServiceDescriptorProto_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBServiceDescriptorProto alloc] init] autorelease]; } return self; } - (PBGeneratedMessage*) internalGetResult { return result; } - (PBServiceDescriptorProto_Builder*) clear { self.result = [[[PBServiceDescriptorProto alloc] init] autorelease]; return self; } - (PBServiceDescriptorProto_Builder*) clone { return [PBServiceDescriptorProto builderWithPrototype:result]; } - (PBServiceDescriptorProto*) defaultInstance { return [PBServiceDescriptorProto defaultInstance]; } - (PBServiceDescriptorProto*) build { [self checkInitialized]; return [self buildPartial]; } - (PBServiceDescriptorProto*) buildPartial { PBServiceDescriptorProto* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBServiceDescriptorProto_Builder*) mergeFrom:(PBServiceDescriptorProto*) other { if (other == [PBServiceDescriptorProto defaultInstance]) { return self; } if (other.hasName) { [self setName:other.name]; } if (other.methodArray.count > 0) { if (result.methodArray == nil) { result.methodArray = [other.methodArray copyWithZone:[other.methodArray zone]]; } else { [result.methodArray appendArray:other.methodArray]; } } if (other.hasOptions) { [self mergeOptions:other.options]; } [self mergeUnknownFields:other.unknownFields]; return self; } - (PBServiceDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBServiceDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 10: { [self setName:[input readString]]; break; } case 18: { PBMethodDescriptorProto_Builder* subBuilder = [PBMethodDescriptorProto builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addMethod:[subBuilder buildPartial]]; break; } case 26: { PBServiceOptions_Builder* subBuilder = [PBServiceOptions builder]; if (self.hasOptions) { [subBuilder mergeFrom:self.options]; } [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self setOptions:[subBuilder buildPartial]]; break; } } } } - (BOOL) hasName { return result.hasName; } - (NSString*) name { return result.name; } - (PBServiceDescriptorProto_Builder*) setName:(NSString*) value { result.hasName = YES; result.name = value; return self; } - (PBServiceDescriptorProto_Builder*) clearName { result.hasName = NO; result.name = @""; return self; } - (PBAppendableArray *)method { return result.methodArray; } - (PBMethodDescriptorProto*)methodAtIndex:(NSUInteger)index { return [result methodAtIndex:index]; } - (PBServiceDescriptorProto_Builder *)addMethod:(PBMethodDescriptorProto*)value { if (result.methodArray == nil) { result.methodArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.methodArray addObject:value]; return self; } - (PBServiceDescriptorProto_Builder *)setMethodArray:(NSArray *)array { result.methodArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBServiceDescriptorProto_Builder *)setMethodValues:(const PBMethodDescriptorProto* *)values count:(NSUInteger)count { result.methodArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBServiceDescriptorProto_Builder *)clearMethod { result.methodArray = nil; return self; } - (BOOL) hasOptions { return result.hasOptions; } - (PBServiceOptions*) options { return result.options; } - (PBServiceDescriptorProto_Builder*) setOptions:(PBServiceOptions*) value { result.hasOptions = YES; result.options = value; return self; } - (PBServiceDescriptorProto_Builder*) setOptionsBuilder:(PBServiceOptions_Builder*) builderForValue { return [self setOptions:[builderForValue build]]; } - (PBServiceDescriptorProto_Builder*) mergeOptions:(PBServiceOptions*) value { if (result.hasOptions && result.options != [PBServiceOptions defaultInstance]) { result.options = [[[PBServiceOptions builderWithPrototype:result.options] mergeFrom:value] buildPartial]; } else { result.options = value; } result.hasOptions = YES; return self; } - (PBServiceDescriptorProto_Builder*) clearOptions { result.hasOptions = NO; result.options = [PBServiceOptions defaultInstance]; return self; } @end @interface PBMethodDescriptorProto () @property (retain) NSString* name; @property (retain) NSString* inputType; @property (retain) NSString* outputType; @property (retain) PBMethodOptions* options; @end @implementation PBMethodDescriptorProto - (BOOL) hasName { return !!hasName_; } - (void) setHasName:(BOOL) value { hasName_ = !!value; } @synthesize name; - (BOOL) hasInputType { return !!hasInputType_; } - (void) setHasInputType:(BOOL) value { hasInputType_ = !!value; } @synthesize inputType; - (BOOL) hasOutputType { return !!hasOutputType_; } - (void) setHasOutputType:(BOOL) value { hasOutputType_ = !!value; } @synthesize outputType; - (BOOL) hasOptions { return !!hasOptions_; } - (void) setHasOptions:(BOOL) value { hasOptions_ = !!value; } @synthesize options; - (void) dealloc { self.name = nil; self.inputType = nil; self.outputType = nil; self.options = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.name = @""; self.inputType = @""; self.outputType = @""; self.options = [PBMethodOptions defaultInstance]; } return self; } static PBMethodDescriptorProto* defaultPBMethodDescriptorProtoInstance = nil; + (void) initialize { if (self == [PBMethodDescriptorProto class]) { defaultPBMethodDescriptorProtoInstance = [[PBMethodDescriptorProto alloc] init]; } } + (PBMethodDescriptorProto*) defaultInstance { return defaultPBMethodDescriptorProtoInstance; } - (PBMethodDescriptorProto*) defaultInstance { return defaultPBMethodDescriptorProtoInstance; } - (BOOL) isInitialized { if (self.hasOptions) { if (!self.options.isInitialized) { return NO; } } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { if (self.hasName) { [output writeString:1 value:self.name]; } if (self.hasInputType) { [output writeString:2 value:self.inputType]; } if (self.hasOutputType) { [output writeString:3 value:self.outputType]; } if (self.hasOptions) { [output writeMessage:4 value:self.options]; } [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; if (self.hasName) { size += computeStringSize(1, self.name); } if (self.hasInputType) { size += computeStringSize(2, self.inputType); } if (self.hasOutputType) { size += computeStringSize(3, self.outputType); } if (self.hasOptions) { size += computeMessageSize(4, self.options); } size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBMethodDescriptorProto*) parseFromData:(NSData*) data { return (PBMethodDescriptorProto*)[[[PBMethodDescriptorProto builder] mergeFromData:data] build]; } + (PBMethodDescriptorProto*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBMethodDescriptorProto*)[[[PBMethodDescriptorProto builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBMethodDescriptorProto*) parseFromInputStream:(NSInputStream*) input { return (PBMethodDescriptorProto*)[[[PBMethodDescriptorProto builder] mergeFromInputStream:input] build]; } + (PBMethodDescriptorProto*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBMethodDescriptorProto*)[[[PBMethodDescriptorProto builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBMethodDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBMethodDescriptorProto*)[[[PBMethodDescriptorProto builder] mergeFromCodedInputStream:input] build]; } + (PBMethodDescriptorProto*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBMethodDescriptorProto*)[[[PBMethodDescriptorProto builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBMethodDescriptorProto_Builder*) builder { return [[[PBMethodDescriptorProto_Builder alloc] init] autorelease]; } + (PBMethodDescriptorProto_Builder*) builderWithPrototype:(PBMethodDescriptorProto*) prototype { return [[PBMethodDescriptorProto builder] mergeFrom:prototype]; } - (PBMethodDescriptorProto_Builder*) builder { return [PBMethodDescriptorProto builder]; } @end @interface PBMethodDescriptorProto_Builder() @property (retain) PBMethodDescriptorProto* result; @end @implementation PBMethodDescriptorProto_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBMethodDescriptorProto alloc] init] autorelease]; } return self; } - (PBGeneratedMessage*) internalGetResult { return result; } - (PBMethodDescriptorProto_Builder*) clear { self.result = [[[PBMethodDescriptorProto alloc] init] autorelease]; return self; } - (PBMethodDescriptorProto_Builder*) clone { return [PBMethodDescriptorProto builderWithPrototype:result]; } - (PBMethodDescriptorProto*) defaultInstance { return [PBMethodDescriptorProto defaultInstance]; } - (PBMethodDescriptorProto*) build { [self checkInitialized]; return [self buildPartial]; } - (PBMethodDescriptorProto*) buildPartial { PBMethodDescriptorProto* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBMethodDescriptorProto_Builder*) mergeFrom:(PBMethodDescriptorProto*) other { if (other == [PBMethodDescriptorProto defaultInstance]) { return self; } if (other.hasName) { [self setName:other.name]; } if (other.hasInputType) { [self setInputType:other.inputType]; } if (other.hasOutputType) { [self setOutputType:other.outputType]; } if (other.hasOptions) { [self mergeOptions:other.options]; } [self mergeUnknownFields:other.unknownFields]; return self; } - (PBMethodDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBMethodDescriptorProto_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 10: { [self setName:[input readString]]; break; } case 18: { [self setInputType:[input readString]]; break; } case 26: { [self setOutputType:[input readString]]; break; } case 34: { PBMethodOptions_Builder* subBuilder = [PBMethodOptions builder]; if (self.hasOptions) { [subBuilder mergeFrom:self.options]; } [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self setOptions:[subBuilder buildPartial]]; break; } } } } - (BOOL) hasName { return result.hasName; } - (NSString*) name { return result.name; } - (PBMethodDescriptorProto_Builder*) setName:(NSString*) value { result.hasName = YES; result.name = value; return self; } - (PBMethodDescriptorProto_Builder*) clearName { result.hasName = NO; result.name = @""; return self; } - (BOOL) hasInputType { return result.hasInputType; } - (NSString*) inputType { return result.inputType; } - (PBMethodDescriptorProto_Builder*) setInputType:(NSString*) value { result.hasInputType = YES; result.inputType = value; return self; } - (PBMethodDescriptorProto_Builder*) clearInputType { result.hasInputType = NO; result.inputType = @""; return self; } - (BOOL) hasOutputType { return result.hasOutputType; } - (NSString*) outputType { return result.outputType; } - (PBMethodDescriptorProto_Builder*) setOutputType:(NSString*) value { result.hasOutputType = YES; result.outputType = value; return self; } - (PBMethodDescriptorProto_Builder*) clearOutputType { result.hasOutputType = NO; result.outputType = @""; return self; } - (BOOL) hasOptions { return result.hasOptions; } - (PBMethodOptions*) options { return result.options; } - (PBMethodDescriptorProto_Builder*) setOptions:(PBMethodOptions*) value { result.hasOptions = YES; result.options = value; return self; } - (PBMethodDescriptorProto_Builder*) setOptionsBuilder:(PBMethodOptions_Builder*) builderForValue { return [self setOptions:[builderForValue build]]; } - (PBMethodDescriptorProto_Builder*) mergeOptions:(PBMethodOptions*) value { if (result.hasOptions && result.options != [PBMethodOptions defaultInstance]) { result.options = [[[PBMethodOptions builderWithPrototype:result.options] mergeFrom:value] buildPartial]; } else { result.options = value; } result.hasOptions = YES; return self; } - (PBMethodDescriptorProto_Builder*) clearOptions { result.hasOptions = NO; result.options = [PBMethodOptions defaultInstance]; return self; } @end @interface PBFileOptions () @property (retain) NSString* javaPackage; @property (retain) NSString* javaOuterClassname; @property BOOL javaMultipleFiles; @property PBFileOptions_OptimizeMode optimizeFor; @property BOOL ccGenericServices; @property BOOL javaGenericServices; @property BOOL pyGenericServices; @property (retain) PBAppendableArray * uninterpretedOptionArray; @end @implementation PBFileOptions - (BOOL) hasJavaPackage { return !!hasJavaPackage_; } - (void) setHasJavaPackage:(BOOL) value { hasJavaPackage_ = !!value; } @synthesize javaPackage; - (BOOL) hasJavaOuterClassname { return !!hasJavaOuterClassname_; } - (void) setHasJavaOuterClassname:(BOOL) value { hasJavaOuterClassname_ = !!value; } @synthesize javaOuterClassname; - (BOOL) hasJavaMultipleFiles { return !!hasJavaMultipleFiles_; } - (void) setHasJavaMultipleFiles:(BOOL) value { hasJavaMultipleFiles_ = !!value; } - (BOOL) javaMultipleFiles { return !!javaMultipleFiles_; } - (void) setJavaMultipleFiles:(BOOL) value { javaMultipleFiles_ = !!value; } - (BOOL) hasOptimizeFor { return !!hasOptimizeFor_; } - (void) setHasOptimizeFor:(BOOL) value { hasOptimizeFor_ = !!value; } @synthesize optimizeFor; - (BOOL) hasCcGenericServices { return !!hasCcGenericServices_; } - (void) setHasCcGenericServices:(BOOL) value { hasCcGenericServices_ = !!value; } - (BOOL) ccGenericServices { return !!ccGenericServices_; } - (void) setCcGenericServices:(BOOL) value { ccGenericServices_ = !!value; } - (BOOL) hasJavaGenericServices { return !!hasJavaGenericServices_; } - (void) setHasJavaGenericServices:(BOOL) value { hasJavaGenericServices_ = !!value; } - (BOOL) javaGenericServices { return !!javaGenericServices_; } - (void) setJavaGenericServices:(BOOL) value { javaGenericServices_ = !!value; } - (BOOL) hasPyGenericServices { return !!hasPyGenericServices_; } - (void) setHasPyGenericServices:(BOOL) value { hasPyGenericServices_ = !!value; } - (BOOL) pyGenericServices { return !!pyGenericServices_; } - (void) setPyGenericServices:(BOOL) value { pyGenericServices_ = !!value; } @synthesize uninterpretedOptionArray; @dynamic uninterpretedOption; - (void) dealloc { self.javaPackage = nil; self.javaOuterClassname = nil; self.uninterpretedOptionArray = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.javaPackage = @""; self.javaOuterClassname = @""; self.javaMultipleFiles = NO; self.optimizeFor = PBFileOptions_OptimizeModeSpeed; self.ccGenericServices = YES; self.javaGenericServices = YES; self.pyGenericServices = YES; } return self; } static PBFileOptions* defaultPBFileOptionsInstance = nil; + (void) initialize { if (self == [PBFileOptions class]) { defaultPBFileOptionsInstance = [[PBFileOptions alloc] init]; } } + (PBFileOptions*) defaultInstance { return defaultPBFileOptionsInstance; } - (PBFileOptions*) defaultInstance { return defaultPBFileOptionsInstance; } - (PBArray *)uninterpretedOption { return uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [uninterpretedOptionArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBUninterpretedOption* element in self.uninterpretedOption) { if (!element.isInitialized) { return NO; } } if (!self.extensionsAreInitialized) { return NO; } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { if (self.hasJavaPackage) { [output writeString:1 value:self.javaPackage]; } if (self.hasJavaOuterClassname) { [output writeString:8 value:self.javaOuterClassname]; } if (self.hasOptimizeFor) { [output writeEnum:9 value:self.optimizeFor]; } if (self.hasJavaMultipleFiles) { [output writeBool:10 value:self.javaMultipleFiles]; } if (self.hasCcGenericServices) { [output writeBool:16 value:self.ccGenericServices]; } if (self.hasJavaGenericServices) { [output writeBool:17 value:self.javaGenericServices]; } if (self.hasPyGenericServices) { [output writeBool:18 value:self.pyGenericServices]; } for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { [output writeMessage:999 value:element]; } [self writeExtensionsToCodedOutputStream:output from:1000 to:536870912]; [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; if (self.hasJavaPackage) { size += computeStringSize(1, self.javaPackage); } if (self.hasJavaOuterClassname) { size += computeStringSize(8, self.javaOuterClassname); } if (self.hasOptimizeFor) { size += computeEnumSize(9, self.optimizeFor); } if (self.hasJavaMultipleFiles) { size += computeBoolSize(10, self.javaMultipleFiles); } if (self.hasCcGenericServices) { size += computeBoolSize(16, self.ccGenericServices); } if (self.hasJavaGenericServices) { size += computeBoolSize(17, self.javaGenericServices); } if (self.hasPyGenericServices) { size += computeBoolSize(18, self.pyGenericServices); } for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { size += computeMessageSize(999, element); } size += [self extensionsSerializedSize]; size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBFileOptions*) parseFromData:(NSData*) data { return (PBFileOptions*)[[[PBFileOptions builder] mergeFromData:data] build]; } + (PBFileOptions*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFileOptions*)[[[PBFileOptions builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBFileOptions*) parseFromInputStream:(NSInputStream*) input { return (PBFileOptions*)[[[PBFileOptions builder] mergeFromInputStream:input] build]; } + (PBFileOptions*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFileOptions*)[[[PBFileOptions builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBFileOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBFileOptions*)[[[PBFileOptions builder] mergeFromCodedInputStream:input] build]; } + (PBFileOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFileOptions*)[[[PBFileOptions builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBFileOptions_Builder*) builder { return [[[PBFileOptions_Builder alloc] init] autorelease]; } + (PBFileOptions_Builder*) builderWithPrototype:(PBFileOptions*) prototype { return [[PBFileOptions builder] mergeFrom:prototype]; } - (PBFileOptions_Builder*) builder { return [PBFileOptions builder]; } @end BOOL PBFileOptions_OptimizeModeIsValidValue(PBFileOptions_OptimizeMode value) { switch (value) { case PBFileOptions_OptimizeModeSpeed: case PBFileOptions_OptimizeModeCodeSize: case PBFileOptions_OptimizeModeLiteRuntime: return YES; default: return NO; } } @interface PBFileOptions_Builder() @property (retain) PBFileOptions* result; @end @implementation PBFileOptions_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBFileOptions alloc] init] autorelease]; } return self; } - (PBExtendableMessage*) internalGetResult { return result; } - (PBFileOptions_Builder*) clear { self.result = [[[PBFileOptions alloc] init] autorelease]; return self; } - (PBFileOptions_Builder*) clone { return [PBFileOptions builderWithPrototype:result]; } - (PBFileOptions*) defaultInstance { return [PBFileOptions defaultInstance]; } - (PBFileOptions*) build { [self checkInitialized]; return [self buildPartial]; } - (PBFileOptions*) buildPartial { PBFileOptions* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBFileOptions_Builder*) mergeFrom:(PBFileOptions*) other { if (other == [PBFileOptions defaultInstance]) { return self; } if (other.hasJavaPackage) { [self setJavaPackage:other.javaPackage]; } if (other.hasJavaOuterClassname) { [self setJavaOuterClassname:other.javaOuterClassname]; } if (other.hasJavaMultipleFiles) { [self setJavaMultipleFiles:other.javaMultipleFiles]; } if (other.hasOptimizeFor) { [self setOptimizeFor:other.optimizeFor]; } if (other.hasCcGenericServices) { [self setCcGenericServices:other.ccGenericServices]; } if (other.hasJavaGenericServices) { [self setJavaGenericServices:other.javaGenericServices]; } if (other.hasPyGenericServices) { [self setPyGenericServices:other.pyGenericServices]; } if (other.uninterpretedOptionArray.count > 0) { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [other.uninterpretedOptionArray copyWithZone:[other.uninterpretedOptionArray zone]]; } else { [result.uninterpretedOptionArray appendArray:other.uninterpretedOptionArray]; } } [self mergeExtensionFields:other]; [self mergeUnknownFields:other.unknownFields]; return self; } - (PBFileOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBFileOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 10: { [self setJavaPackage:[input readString]]; break; } case 66: { [self setJavaOuterClassname:[input readString]]; break; } case 72: { int32_t value = [input readEnum]; if (PBFileOptions_OptimizeModeIsValidValue(value)) { [self setOptimizeFor:value]; } else { [unknownFields mergeVarintField:9 value:value]; } break; } case 80: { [self setJavaMultipleFiles:[input readBool]]; break; } case 128: { [self setCcGenericServices:[input readBool]]; break; } case 136: { [self setJavaGenericServices:[input readBool]]; break; } case 144: { [self setPyGenericServices:[input readBool]]; break; } case 7994: { PBUninterpretedOption_Builder* subBuilder = [PBUninterpretedOption builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addUninterpretedOption:[subBuilder buildPartial]]; break; } } } } - (BOOL) hasJavaPackage { return result.hasJavaPackage; } - (NSString*) javaPackage { return result.javaPackage; } - (PBFileOptions_Builder*) setJavaPackage:(NSString*) value { result.hasJavaPackage = YES; result.javaPackage = value; return self; } - (PBFileOptions_Builder*) clearJavaPackage { result.hasJavaPackage = NO; result.javaPackage = @""; return self; } - (BOOL) hasJavaOuterClassname { return result.hasJavaOuterClassname; } - (NSString*) javaOuterClassname { return result.javaOuterClassname; } - (PBFileOptions_Builder*) setJavaOuterClassname:(NSString*) value { result.hasJavaOuterClassname = YES; result.javaOuterClassname = value; return self; } - (PBFileOptions_Builder*) clearJavaOuterClassname { result.hasJavaOuterClassname = NO; result.javaOuterClassname = @""; return self; } - (BOOL) hasJavaMultipleFiles { return result.hasJavaMultipleFiles; } - (BOOL) javaMultipleFiles { return result.javaMultipleFiles; } - (PBFileOptions_Builder*) setJavaMultipleFiles:(BOOL) value { result.hasJavaMultipleFiles = YES; result.javaMultipleFiles = value; return self; } - (PBFileOptions_Builder*) clearJavaMultipleFiles { result.hasJavaMultipleFiles = NO; result.javaMultipleFiles = NO; return self; } - (BOOL) hasOptimizeFor { return result.hasOptimizeFor; } - (PBFileOptions_OptimizeMode) optimizeFor { return result.optimizeFor; } - (PBFileOptions_Builder*) setOptimizeFor:(PBFileOptions_OptimizeMode) value { result.hasOptimizeFor = YES; result.optimizeFor = value; return self; } - (PBFileOptions_Builder*) clearOptimizeFor { result.hasOptimizeFor = NO; result.optimizeFor = PBFileOptions_OptimizeModeSpeed; return self; } - (BOOL) hasCcGenericServices { return result.hasCcGenericServices; } - (BOOL) ccGenericServices { return result.ccGenericServices; } - (PBFileOptions_Builder*) setCcGenericServices:(BOOL) value { result.hasCcGenericServices = YES; result.ccGenericServices = value; return self; } - (PBFileOptions_Builder*) clearCcGenericServices { result.hasCcGenericServices = NO; result.ccGenericServices = YES; return self; } - (BOOL) hasJavaGenericServices { return result.hasJavaGenericServices; } - (BOOL) javaGenericServices { return result.javaGenericServices; } - (PBFileOptions_Builder*) setJavaGenericServices:(BOOL) value { result.hasJavaGenericServices = YES; result.javaGenericServices = value; return self; } - (PBFileOptions_Builder*) clearJavaGenericServices { result.hasJavaGenericServices = NO; result.javaGenericServices = YES; return self; } - (BOOL) hasPyGenericServices { return result.hasPyGenericServices; } - (BOOL) pyGenericServices { return result.pyGenericServices; } - (PBFileOptions_Builder*) setPyGenericServices:(BOOL) value { result.hasPyGenericServices = YES; result.pyGenericServices = value; return self; } - (PBFileOptions_Builder*) clearPyGenericServices { result.hasPyGenericServices = NO; result.pyGenericServices = YES; return self; } - (PBAppendableArray *)uninterpretedOption { return result.uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [result uninterpretedOptionAtIndex:index]; } - (PBFileOptions_Builder *)addUninterpretedOption:(PBUninterpretedOption*)value { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.uninterpretedOptionArray addObject:value]; return self; } - (PBFileOptions_Builder *)setUninterpretedOptionArray:(NSArray *)array { result.uninterpretedOptionArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBFileOptions_Builder *)setUninterpretedOptionValues:(const PBUninterpretedOption* *)values count:(NSUInteger)count { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBFileOptions_Builder *)clearUninterpretedOption { result.uninterpretedOptionArray = nil; return self; } @end @interface PBMessageOptions () @property BOOL messageSetWireFormat; @property BOOL noStandardDescriptorAccessor; @property (retain) PBAppendableArray * uninterpretedOptionArray; @end @implementation PBMessageOptions - (BOOL) hasMessageSetWireFormat { return !!hasMessageSetWireFormat_; } - (void) setHasMessageSetWireFormat:(BOOL) value { hasMessageSetWireFormat_ = !!value; } - (BOOL) messageSetWireFormat { return !!messageSetWireFormat_; } - (void) setMessageSetWireFormat:(BOOL) value { messageSetWireFormat_ = !!value; } - (BOOL) hasNoStandardDescriptorAccessor { return !!hasNoStandardDescriptorAccessor_; } - (void) setHasNoStandardDescriptorAccessor:(BOOL) value { hasNoStandardDescriptorAccessor_ = !!value; } - (BOOL) noStandardDescriptorAccessor { return !!noStandardDescriptorAccessor_; } - (void) setNoStandardDescriptorAccessor:(BOOL) value { noStandardDescriptorAccessor_ = !!value; } @synthesize uninterpretedOptionArray; @dynamic uninterpretedOption; - (void) dealloc { self.uninterpretedOptionArray = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.messageSetWireFormat = NO; self.noStandardDescriptorAccessor = NO; } return self; } static PBMessageOptions* defaultPBMessageOptionsInstance = nil; + (void) initialize { if (self == [PBMessageOptions class]) { defaultPBMessageOptionsInstance = [[PBMessageOptions alloc] init]; } } + (PBMessageOptions*) defaultInstance { return defaultPBMessageOptionsInstance; } - (PBMessageOptions*) defaultInstance { return defaultPBMessageOptionsInstance; } - (PBArray *)uninterpretedOption { return uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [uninterpretedOptionArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBUninterpretedOption* element in self.uninterpretedOption) { if (!element.isInitialized) { return NO; } } if (!self.extensionsAreInitialized) { return NO; } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { if (self.hasMessageSetWireFormat) { [output writeBool:1 value:self.messageSetWireFormat]; } if (self.hasNoStandardDescriptorAccessor) { [output writeBool:2 value:self.noStandardDescriptorAccessor]; } for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { [output writeMessage:999 value:element]; } [self writeExtensionsToCodedOutputStream:output from:1000 to:536870912]; [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; if (self.hasMessageSetWireFormat) { size += computeBoolSize(1, self.messageSetWireFormat); } if (self.hasNoStandardDescriptorAccessor) { size += computeBoolSize(2, self.noStandardDescriptorAccessor); } for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { size += computeMessageSize(999, element); } size += [self extensionsSerializedSize]; size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBMessageOptions*) parseFromData:(NSData*) data { return (PBMessageOptions*)[[[PBMessageOptions builder] mergeFromData:data] build]; } + (PBMessageOptions*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBMessageOptions*)[[[PBMessageOptions builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBMessageOptions*) parseFromInputStream:(NSInputStream*) input { return (PBMessageOptions*)[[[PBMessageOptions builder] mergeFromInputStream:input] build]; } + (PBMessageOptions*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBMessageOptions*)[[[PBMessageOptions builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBMessageOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBMessageOptions*)[[[PBMessageOptions builder] mergeFromCodedInputStream:input] build]; } + (PBMessageOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBMessageOptions*)[[[PBMessageOptions builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBMessageOptions_Builder*) builder { return [[[PBMessageOptions_Builder alloc] init] autorelease]; } + (PBMessageOptions_Builder*) builderWithPrototype:(PBMessageOptions*) prototype { return [[PBMessageOptions builder] mergeFrom:prototype]; } - (PBMessageOptions_Builder*) builder { return [PBMessageOptions builder]; } @end @interface PBMessageOptions_Builder() @property (retain) PBMessageOptions* result; @end @implementation PBMessageOptions_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBMessageOptions alloc] init] autorelease]; } return self; } - (PBExtendableMessage*) internalGetResult { return result; } - (PBMessageOptions_Builder*) clear { self.result = [[[PBMessageOptions alloc] init] autorelease]; return self; } - (PBMessageOptions_Builder*) clone { return [PBMessageOptions builderWithPrototype:result]; } - (PBMessageOptions*) defaultInstance { return [PBMessageOptions defaultInstance]; } - (PBMessageOptions*) build { [self checkInitialized]; return [self buildPartial]; } - (PBMessageOptions*) buildPartial { PBMessageOptions* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBMessageOptions_Builder*) mergeFrom:(PBMessageOptions*) other { if (other == [PBMessageOptions defaultInstance]) { return self; } if (other.hasMessageSetWireFormat) { [self setMessageSetWireFormat:other.messageSetWireFormat]; } if (other.hasNoStandardDescriptorAccessor) { [self setNoStandardDescriptorAccessor:other.noStandardDescriptorAccessor]; } if (other.uninterpretedOptionArray.count > 0) { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [other.uninterpretedOptionArray copyWithZone:[other.uninterpretedOptionArray zone]]; } else { [result.uninterpretedOptionArray appendArray:other.uninterpretedOptionArray]; } } [self mergeExtensionFields:other]; [self mergeUnknownFields:other.unknownFields]; return self; } - (PBMessageOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBMessageOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 8: { [self setMessageSetWireFormat:[input readBool]]; break; } case 16: { [self setNoStandardDescriptorAccessor:[input readBool]]; break; } case 7994: { PBUninterpretedOption_Builder* subBuilder = [PBUninterpretedOption builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addUninterpretedOption:[subBuilder buildPartial]]; break; } } } } - (BOOL) hasMessageSetWireFormat { return result.hasMessageSetWireFormat; } - (BOOL) messageSetWireFormat { return result.messageSetWireFormat; } - (PBMessageOptions_Builder*) setMessageSetWireFormat:(BOOL) value { result.hasMessageSetWireFormat = YES; result.messageSetWireFormat = value; return self; } - (PBMessageOptions_Builder*) clearMessageSetWireFormat { result.hasMessageSetWireFormat = NO; result.messageSetWireFormat = NO; return self; } - (BOOL) hasNoStandardDescriptorAccessor { return result.hasNoStandardDescriptorAccessor; } - (BOOL) noStandardDescriptorAccessor { return result.noStandardDescriptorAccessor; } - (PBMessageOptions_Builder*) setNoStandardDescriptorAccessor:(BOOL) value { result.hasNoStandardDescriptorAccessor = YES; result.noStandardDescriptorAccessor = value; return self; } - (PBMessageOptions_Builder*) clearNoStandardDescriptorAccessor { result.hasNoStandardDescriptorAccessor = NO; result.noStandardDescriptorAccessor = NO; return self; } - (PBAppendableArray *)uninterpretedOption { return result.uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [result uninterpretedOptionAtIndex:index]; } - (PBMessageOptions_Builder *)addUninterpretedOption:(PBUninterpretedOption*)value { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.uninterpretedOptionArray addObject:value]; return self; } - (PBMessageOptions_Builder *)setUninterpretedOptionArray:(NSArray *)array { result.uninterpretedOptionArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBMessageOptions_Builder *)setUninterpretedOptionValues:(const PBUninterpretedOption* *)values count:(NSUInteger)count { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBMessageOptions_Builder *)clearUninterpretedOption { result.uninterpretedOptionArray = nil; return self; } @end @interface PBFieldOptions () @property PBFieldOptions_CType ctype; @property BOOL packed; @property BOOL deprecated; @property (retain) NSString* experimentalMapKey; @property (retain) PBAppendableArray * uninterpretedOptionArray; @end @implementation PBFieldOptions - (BOOL) hasCtype { return !!hasCtype_; } - (void) setHasCtype:(BOOL) value { hasCtype_ = !!value; } @synthesize ctype; - (BOOL) hasPacked { return !!hasPacked_; } - (void) setHasPacked:(BOOL) value { hasPacked_ = !!value; } - (BOOL) packed { return !!packed_; } - (void) setPacked:(BOOL) value { packed_ = !!value; } - (BOOL) hasDeprecated { return !!hasDeprecated_; } - (void) setHasDeprecated:(BOOL) value { hasDeprecated_ = !!value; } - (BOOL) deprecated { return !!deprecated_; } - (void) setDeprecated:(BOOL) value { deprecated_ = !!value; } - (BOOL) hasExperimentalMapKey { return !!hasExperimentalMapKey_; } - (void) setHasExperimentalMapKey:(BOOL) value { hasExperimentalMapKey_ = !!value; } @synthesize experimentalMapKey; @synthesize uninterpretedOptionArray; @dynamic uninterpretedOption; - (void) dealloc { self.experimentalMapKey = nil; self.uninterpretedOptionArray = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.ctype = PBFieldOptions_CTypeString; self.packed = NO; self.deprecated = NO; self.experimentalMapKey = @""; } return self; } static PBFieldOptions* defaultPBFieldOptionsInstance = nil; + (void) initialize { if (self == [PBFieldOptions class]) { defaultPBFieldOptionsInstance = [[PBFieldOptions alloc] init]; } } + (PBFieldOptions*) defaultInstance { return defaultPBFieldOptionsInstance; } - (PBFieldOptions*) defaultInstance { return defaultPBFieldOptionsInstance; } - (PBArray *)uninterpretedOption { return uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [uninterpretedOptionArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBUninterpretedOption* element in self.uninterpretedOption) { if (!element.isInitialized) { return NO; } } if (!self.extensionsAreInitialized) { return NO; } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { if (self.hasCtype) { [output writeEnum:1 value:self.ctype]; } if (self.hasPacked) { [output writeBool:2 value:self.packed]; } if (self.hasDeprecated) { [output writeBool:3 value:self.deprecated]; } if (self.hasExperimentalMapKey) { [output writeString:9 value:self.experimentalMapKey]; } for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { [output writeMessage:999 value:element]; } [self writeExtensionsToCodedOutputStream:output from:1000 to:536870912]; [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; if (self.hasCtype) { size += computeEnumSize(1, self.ctype); } if (self.hasPacked) { size += computeBoolSize(2, self.packed); } if (self.hasDeprecated) { size += computeBoolSize(3, self.deprecated); } if (self.hasExperimentalMapKey) { size += computeStringSize(9, self.experimentalMapKey); } for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { size += computeMessageSize(999, element); } size += [self extensionsSerializedSize]; size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBFieldOptions*) parseFromData:(NSData*) data { return (PBFieldOptions*)[[[PBFieldOptions builder] mergeFromData:data] build]; } + (PBFieldOptions*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFieldOptions*)[[[PBFieldOptions builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBFieldOptions*) parseFromInputStream:(NSInputStream*) input { return (PBFieldOptions*)[[[PBFieldOptions builder] mergeFromInputStream:input] build]; } + (PBFieldOptions*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFieldOptions*)[[[PBFieldOptions builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBFieldOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBFieldOptions*)[[[PBFieldOptions builder] mergeFromCodedInputStream:input] build]; } + (PBFieldOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBFieldOptions*)[[[PBFieldOptions builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBFieldOptions_Builder*) builder { return [[[PBFieldOptions_Builder alloc] init] autorelease]; } + (PBFieldOptions_Builder*) builderWithPrototype:(PBFieldOptions*) prototype { return [[PBFieldOptions builder] mergeFrom:prototype]; } - (PBFieldOptions_Builder*) builder { return [PBFieldOptions builder]; } @end BOOL PBFieldOptions_CTypeIsValidValue(PBFieldOptions_CType value) { switch (value) { case PBFieldOptions_CTypeString: case PBFieldOptions_CTypeCord: case PBFieldOptions_CTypeStringPiece: return YES; default: return NO; } } @interface PBFieldOptions_Builder() @property (retain) PBFieldOptions* result; @end @implementation PBFieldOptions_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBFieldOptions alloc] init] autorelease]; } return self; } - (PBExtendableMessage*) internalGetResult { return result; } - (PBFieldOptions_Builder*) clear { self.result = [[[PBFieldOptions alloc] init] autorelease]; return self; } - (PBFieldOptions_Builder*) clone { return [PBFieldOptions builderWithPrototype:result]; } - (PBFieldOptions*) defaultInstance { return [PBFieldOptions defaultInstance]; } - (PBFieldOptions*) build { [self checkInitialized]; return [self buildPartial]; } - (PBFieldOptions*) buildPartial { PBFieldOptions* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBFieldOptions_Builder*) mergeFrom:(PBFieldOptions*) other { if (other == [PBFieldOptions defaultInstance]) { return self; } if (other.hasCtype) { [self setCtype:other.ctype]; } if (other.hasPacked) { [self setPacked:other.packed]; } if (other.hasDeprecated) { [self setDeprecated:other.deprecated]; } if (other.hasExperimentalMapKey) { [self setExperimentalMapKey:other.experimentalMapKey]; } if (other.uninterpretedOptionArray.count > 0) { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [other.uninterpretedOptionArray copyWithZone:[other.uninterpretedOptionArray zone]]; } else { [result.uninterpretedOptionArray appendArray:other.uninterpretedOptionArray]; } } [self mergeExtensionFields:other]; [self mergeUnknownFields:other.unknownFields]; return self; } - (PBFieldOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBFieldOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 8: { int32_t value = [input readEnum]; if (PBFieldOptions_CTypeIsValidValue(value)) { [self setCtype:value]; } else { [unknownFields mergeVarintField:1 value:value]; } break; } case 16: { [self setPacked:[input readBool]]; break; } case 24: { [self setDeprecated:[input readBool]]; break; } case 74: { [self setExperimentalMapKey:[input readString]]; break; } case 7994: { PBUninterpretedOption_Builder* subBuilder = [PBUninterpretedOption builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addUninterpretedOption:[subBuilder buildPartial]]; break; } } } } - (BOOL) hasCtype { return result.hasCtype; } - (PBFieldOptions_CType) ctype { return result.ctype; } - (PBFieldOptions_Builder*) setCtype:(PBFieldOptions_CType) value { result.hasCtype = YES; result.ctype = value; return self; } - (PBFieldOptions_Builder*) clearCtype { result.hasCtype = NO; result.ctype = PBFieldOptions_CTypeString; return self; } - (BOOL) hasPacked { return result.hasPacked; } - (BOOL) packed { return result.packed; } - (PBFieldOptions_Builder*) setPacked:(BOOL) value { result.hasPacked = YES; result.packed = value; return self; } - (PBFieldOptions_Builder*) clearPacked { result.hasPacked = NO; result.packed = NO; return self; } - (BOOL) hasDeprecated { return result.hasDeprecated; } - (BOOL) deprecated { return result.deprecated; } - (PBFieldOptions_Builder*) setDeprecated:(BOOL) value { result.hasDeprecated = YES; result.deprecated = value; return self; } - (PBFieldOptions_Builder*) clearDeprecated { result.hasDeprecated = NO; result.deprecated = NO; return self; } - (BOOL) hasExperimentalMapKey { return result.hasExperimentalMapKey; } - (NSString*) experimentalMapKey { return result.experimentalMapKey; } - (PBFieldOptions_Builder*) setExperimentalMapKey:(NSString*) value { result.hasExperimentalMapKey = YES; result.experimentalMapKey = value; return self; } - (PBFieldOptions_Builder*) clearExperimentalMapKey { result.hasExperimentalMapKey = NO; result.experimentalMapKey = @""; return self; } - (PBAppendableArray *)uninterpretedOption { return result.uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [result uninterpretedOptionAtIndex:index]; } - (PBFieldOptions_Builder *)addUninterpretedOption:(PBUninterpretedOption*)value { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.uninterpretedOptionArray addObject:value]; return self; } - (PBFieldOptions_Builder *)setUninterpretedOptionArray:(NSArray *)array { result.uninterpretedOptionArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBFieldOptions_Builder *)setUninterpretedOptionValues:(const PBUninterpretedOption* *)values count:(NSUInteger)count { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBFieldOptions_Builder *)clearUninterpretedOption { result.uninterpretedOptionArray = nil; return self; } @end @interface PBEnumOptions () @property (retain) PBAppendableArray * uninterpretedOptionArray; @end @implementation PBEnumOptions @synthesize uninterpretedOptionArray; @dynamic uninterpretedOption; - (void) dealloc { self.uninterpretedOptionArray = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { } return self; } static PBEnumOptions* defaultPBEnumOptionsInstance = nil; + (void) initialize { if (self == [PBEnumOptions class]) { defaultPBEnumOptionsInstance = [[PBEnumOptions alloc] init]; } } + (PBEnumOptions*) defaultInstance { return defaultPBEnumOptionsInstance; } - (PBEnumOptions*) defaultInstance { return defaultPBEnumOptionsInstance; } - (PBArray *)uninterpretedOption { return uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [uninterpretedOptionArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBUninterpretedOption* element in self.uninterpretedOption) { if (!element.isInitialized) { return NO; } } if (!self.extensionsAreInitialized) { return NO; } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { [output writeMessage:999 value:element]; } [self writeExtensionsToCodedOutputStream:output from:1000 to:536870912]; [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { size += computeMessageSize(999, element); } size += [self extensionsSerializedSize]; size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBEnumOptions*) parseFromData:(NSData*) data { return (PBEnumOptions*)[[[PBEnumOptions builder] mergeFromData:data] build]; } + (PBEnumOptions*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBEnumOptions*)[[[PBEnumOptions builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBEnumOptions*) parseFromInputStream:(NSInputStream*) input { return (PBEnumOptions*)[[[PBEnumOptions builder] mergeFromInputStream:input] build]; } + (PBEnumOptions*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBEnumOptions*)[[[PBEnumOptions builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBEnumOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBEnumOptions*)[[[PBEnumOptions builder] mergeFromCodedInputStream:input] build]; } + (PBEnumOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBEnumOptions*)[[[PBEnumOptions builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBEnumOptions_Builder*) builder { return [[[PBEnumOptions_Builder alloc] init] autorelease]; } + (PBEnumOptions_Builder*) builderWithPrototype:(PBEnumOptions*) prototype { return [[PBEnumOptions builder] mergeFrom:prototype]; } - (PBEnumOptions_Builder*) builder { return [PBEnumOptions builder]; } @end @interface PBEnumOptions_Builder() @property (retain) PBEnumOptions* result; @end @implementation PBEnumOptions_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBEnumOptions alloc] init] autorelease]; } return self; } - (PBExtendableMessage*) internalGetResult { return result; } - (PBEnumOptions_Builder*) clear { self.result = [[[PBEnumOptions alloc] init] autorelease]; return self; } - (PBEnumOptions_Builder*) clone { return [PBEnumOptions builderWithPrototype:result]; } - (PBEnumOptions*) defaultInstance { return [PBEnumOptions defaultInstance]; } - (PBEnumOptions*) build { [self checkInitialized]; return [self buildPartial]; } - (PBEnumOptions*) buildPartial { PBEnumOptions* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBEnumOptions_Builder*) mergeFrom:(PBEnumOptions*) other { if (other == [PBEnumOptions defaultInstance]) { return self; } if (other.uninterpretedOptionArray.count > 0) { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [other.uninterpretedOptionArray copyWithZone:[other.uninterpretedOptionArray zone]]; } else { [result.uninterpretedOptionArray appendArray:other.uninterpretedOptionArray]; } } [self mergeExtensionFields:other]; [self mergeUnknownFields:other.unknownFields]; return self; } - (PBEnumOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBEnumOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 7994: { PBUninterpretedOption_Builder* subBuilder = [PBUninterpretedOption builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addUninterpretedOption:[subBuilder buildPartial]]; break; } } } } - (PBAppendableArray *)uninterpretedOption { return result.uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [result uninterpretedOptionAtIndex:index]; } - (PBEnumOptions_Builder *)addUninterpretedOption:(PBUninterpretedOption*)value { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.uninterpretedOptionArray addObject:value]; return self; } - (PBEnumOptions_Builder *)setUninterpretedOptionArray:(NSArray *)array { result.uninterpretedOptionArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBEnumOptions_Builder *)setUninterpretedOptionValues:(const PBUninterpretedOption* *)values count:(NSUInteger)count { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBEnumOptions_Builder *)clearUninterpretedOption { result.uninterpretedOptionArray = nil; return self; } @end @interface PBEnumValueOptions () @property (retain) PBAppendableArray * uninterpretedOptionArray; @end @implementation PBEnumValueOptions @synthesize uninterpretedOptionArray; @dynamic uninterpretedOption; - (void) dealloc { self.uninterpretedOptionArray = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { } return self; } static PBEnumValueOptions* defaultPBEnumValueOptionsInstance = nil; + (void) initialize { if (self == [PBEnumValueOptions class]) { defaultPBEnumValueOptionsInstance = [[PBEnumValueOptions alloc] init]; } } + (PBEnumValueOptions*) defaultInstance { return defaultPBEnumValueOptionsInstance; } - (PBEnumValueOptions*) defaultInstance { return defaultPBEnumValueOptionsInstance; } - (PBArray *)uninterpretedOption { return uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [uninterpretedOptionArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBUninterpretedOption* element in self.uninterpretedOption) { if (!element.isInitialized) { return NO; } } if (!self.extensionsAreInitialized) { return NO; } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { [output writeMessage:999 value:element]; } [self writeExtensionsToCodedOutputStream:output from:1000 to:536870912]; [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { size += computeMessageSize(999, element); } size += [self extensionsSerializedSize]; size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBEnumValueOptions*) parseFromData:(NSData*) data { return (PBEnumValueOptions*)[[[PBEnumValueOptions builder] mergeFromData:data] build]; } + (PBEnumValueOptions*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBEnumValueOptions*)[[[PBEnumValueOptions builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBEnumValueOptions*) parseFromInputStream:(NSInputStream*) input { return (PBEnumValueOptions*)[[[PBEnumValueOptions builder] mergeFromInputStream:input] build]; } + (PBEnumValueOptions*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBEnumValueOptions*)[[[PBEnumValueOptions builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBEnumValueOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBEnumValueOptions*)[[[PBEnumValueOptions builder] mergeFromCodedInputStream:input] build]; } + (PBEnumValueOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBEnumValueOptions*)[[[PBEnumValueOptions builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBEnumValueOptions_Builder*) builder { return [[[PBEnumValueOptions_Builder alloc] init] autorelease]; } + (PBEnumValueOptions_Builder*) builderWithPrototype:(PBEnumValueOptions*) prototype { return [[PBEnumValueOptions builder] mergeFrom:prototype]; } - (PBEnumValueOptions_Builder*) builder { return [PBEnumValueOptions builder]; } @end @interface PBEnumValueOptions_Builder() @property (retain) PBEnumValueOptions* result; @end @implementation PBEnumValueOptions_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBEnumValueOptions alloc] init] autorelease]; } return self; } - (PBExtendableMessage*) internalGetResult { return result; } - (PBEnumValueOptions_Builder*) clear { self.result = [[[PBEnumValueOptions alloc] init] autorelease]; return self; } - (PBEnumValueOptions_Builder*) clone { return [PBEnumValueOptions builderWithPrototype:result]; } - (PBEnumValueOptions*) defaultInstance { return [PBEnumValueOptions defaultInstance]; } - (PBEnumValueOptions*) build { [self checkInitialized]; return [self buildPartial]; } - (PBEnumValueOptions*) buildPartial { PBEnumValueOptions* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBEnumValueOptions_Builder*) mergeFrom:(PBEnumValueOptions*) other { if (other == [PBEnumValueOptions defaultInstance]) { return self; } if (other.uninterpretedOptionArray.count > 0) { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [other.uninterpretedOptionArray copyWithZone:[other.uninterpretedOptionArray zone]]; } else { [result.uninterpretedOptionArray appendArray:other.uninterpretedOptionArray]; } } [self mergeExtensionFields:other]; [self mergeUnknownFields:other.unknownFields]; return self; } - (PBEnumValueOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBEnumValueOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 7994: { PBUninterpretedOption_Builder* subBuilder = [PBUninterpretedOption builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addUninterpretedOption:[subBuilder buildPartial]]; break; } } } } - (PBAppendableArray *)uninterpretedOption { return result.uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [result uninterpretedOptionAtIndex:index]; } - (PBEnumValueOptions_Builder *)addUninterpretedOption:(PBUninterpretedOption*)value { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.uninterpretedOptionArray addObject:value]; return self; } - (PBEnumValueOptions_Builder *)setUninterpretedOptionArray:(NSArray *)array { result.uninterpretedOptionArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBEnumValueOptions_Builder *)setUninterpretedOptionValues:(const PBUninterpretedOption* *)values count:(NSUInteger)count { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBEnumValueOptions_Builder *)clearUninterpretedOption { result.uninterpretedOptionArray = nil; return self; } @end @interface PBServiceOptions () @property (retain) PBAppendableArray * uninterpretedOptionArray; @end @implementation PBServiceOptions @synthesize uninterpretedOptionArray; @dynamic uninterpretedOption; - (void) dealloc { self.uninterpretedOptionArray = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { } return self; } static PBServiceOptions* defaultPBServiceOptionsInstance = nil; + (void) initialize { if (self == [PBServiceOptions class]) { defaultPBServiceOptionsInstance = [[PBServiceOptions alloc] init]; } } + (PBServiceOptions*) defaultInstance { return defaultPBServiceOptionsInstance; } - (PBServiceOptions*) defaultInstance { return defaultPBServiceOptionsInstance; } - (PBArray *)uninterpretedOption { return uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [uninterpretedOptionArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBUninterpretedOption* element in self.uninterpretedOption) { if (!element.isInitialized) { return NO; } } if (!self.extensionsAreInitialized) { return NO; } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { [output writeMessage:999 value:element]; } [self writeExtensionsToCodedOutputStream:output from:1000 to:536870912]; [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { size += computeMessageSize(999, element); } size += [self extensionsSerializedSize]; size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBServiceOptions*) parseFromData:(NSData*) data { return (PBServiceOptions*)[[[PBServiceOptions builder] mergeFromData:data] build]; } + (PBServiceOptions*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBServiceOptions*)[[[PBServiceOptions builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBServiceOptions*) parseFromInputStream:(NSInputStream*) input { return (PBServiceOptions*)[[[PBServiceOptions builder] mergeFromInputStream:input] build]; } + (PBServiceOptions*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBServiceOptions*)[[[PBServiceOptions builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBServiceOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBServiceOptions*)[[[PBServiceOptions builder] mergeFromCodedInputStream:input] build]; } + (PBServiceOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBServiceOptions*)[[[PBServiceOptions builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBServiceOptions_Builder*) builder { return [[[PBServiceOptions_Builder alloc] init] autorelease]; } + (PBServiceOptions_Builder*) builderWithPrototype:(PBServiceOptions*) prototype { return [[PBServiceOptions builder] mergeFrom:prototype]; } - (PBServiceOptions_Builder*) builder { return [PBServiceOptions builder]; } @end @interface PBServiceOptions_Builder() @property (retain) PBServiceOptions* result; @end @implementation PBServiceOptions_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBServiceOptions alloc] init] autorelease]; } return self; } - (PBExtendableMessage*) internalGetResult { return result; } - (PBServiceOptions_Builder*) clear { self.result = [[[PBServiceOptions alloc] init] autorelease]; return self; } - (PBServiceOptions_Builder*) clone { return [PBServiceOptions builderWithPrototype:result]; } - (PBServiceOptions*) defaultInstance { return [PBServiceOptions defaultInstance]; } - (PBServiceOptions*) build { [self checkInitialized]; return [self buildPartial]; } - (PBServiceOptions*) buildPartial { PBServiceOptions* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBServiceOptions_Builder*) mergeFrom:(PBServiceOptions*) other { if (other == [PBServiceOptions defaultInstance]) { return self; } if (other.uninterpretedOptionArray.count > 0) { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [other.uninterpretedOptionArray copyWithZone:[other.uninterpretedOptionArray zone]]; } else { [result.uninterpretedOptionArray appendArray:other.uninterpretedOptionArray]; } } [self mergeExtensionFields:other]; [self mergeUnknownFields:other.unknownFields]; return self; } - (PBServiceOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBServiceOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 7994: { PBUninterpretedOption_Builder* subBuilder = [PBUninterpretedOption builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addUninterpretedOption:[subBuilder buildPartial]]; break; } } } } - (PBAppendableArray *)uninterpretedOption { return result.uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [result uninterpretedOptionAtIndex:index]; } - (PBServiceOptions_Builder *)addUninterpretedOption:(PBUninterpretedOption*)value { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.uninterpretedOptionArray addObject:value]; return self; } - (PBServiceOptions_Builder *)setUninterpretedOptionArray:(NSArray *)array { result.uninterpretedOptionArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBServiceOptions_Builder *)setUninterpretedOptionValues:(const PBUninterpretedOption* *)values count:(NSUInteger)count { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBServiceOptions_Builder *)clearUninterpretedOption { result.uninterpretedOptionArray = nil; return self; } @end @interface PBMethodOptions () @property (retain) PBAppendableArray * uninterpretedOptionArray; @end @implementation PBMethodOptions @synthesize uninterpretedOptionArray; @dynamic uninterpretedOption; - (void) dealloc { self.uninterpretedOptionArray = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { } return self; } static PBMethodOptions* defaultPBMethodOptionsInstance = nil; + (void) initialize { if (self == [PBMethodOptions class]) { defaultPBMethodOptionsInstance = [[PBMethodOptions alloc] init]; } } + (PBMethodOptions*) defaultInstance { return defaultPBMethodOptionsInstance; } - (PBMethodOptions*) defaultInstance { return defaultPBMethodOptionsInstance; } - (PBArray *)uninterpretedOption { return uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [uninterpretedOptionArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBUninterpretedOption* element in self.uninterpretedOption) { if (!element.isInitialized) { return NO; } } if (!self.extensionsAreInitialized) { return NO; } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { [output writeMessage:999 value:element]; } [self writeExtensionsToCodedOutputStream:output from:1000 to:536870912]; [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; for (PBUninterpretedOption *element in self.uninterpretedOptionArray) { size += computeMessageSize(999, element); } size += [self extensionsSerializedSize]; size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBMethodOptions*) parseFromData:(NSData*) data { return (PBMethodOptions*)[[[PBMethodOptions builder] mergeFromData:data] build]; } + (PBMethodOptions*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBMethodOptions*)[[[PBMethodOptions builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBMethodOptions*) parseFromInputStream:(NSInputStream*) input { return (PBMethodOptions*)[[[PBMethodOptions builder] mergeFromInputStream:input] build]; } + (PBMethodOptions*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBMethodOptions*)[[[PBMethodOptions builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBMethodOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBMethodOptions*)[[[PBMethodOptions builder] mergeFromCodedInputStream:input] build]; } + (PBMethodOptions*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBMethodOptions*)[[[PBMethodOptions builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBMethodOptions_Builder*) builder { return [[[PBMethodOptions_Builder alloc] init] autorelease]; } + (PBMethodOptions_Builder*) builderWithPrototype:(PBMethodOptions*) prototype { return [[PBMethodOptions builder] mergeFrom:prototype]; } - (PBMethodOptions_Builder*) builder { return [PBMethodOptions builder]; } @end @interface PBMethodOptions_Builder() @property (retain) PBMethodOptions* result; @end @implementation PBMethodOptions_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBMethodOptions alloc] init] autorelease]; } return self; } - (PBExtendableMessage*) internalGetResult { return result; } - (PBMethodOptions_Builder*) clear { self.result = [[[PBMethodOptions alloc] init] autorelease]; return self; } - (PBMethodOptions_Builder*) clone { return [PBMethodOptions builderWithPrototype:result]; } - (PBMethodOptions*) defaultInstance { return [PBMethodOptions defaultInstance]; } - (PBMethodOptions*) build { [self checkInitialized]; return [self buildPartial]; } - (PBMethodOptions*) buildPartial { PBMethodOptions* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBMethodOptions_Builder*) mergeFrom:(PBMethodOptions*) other { if (other == [PBMethodOptions defaultInstance]) { return self; } if (other.uninterpretedOptionArray.count > 0) { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [other.uninterpretedOptionArray copyWithZone:[other.uninterpretedOptionArray zone]]; } else { [result.uninterpretedOptionArray appendArray:other.uninterpretedOptionArray]; } } [self mergeExtensionFields:other]; [self mergeUnknownFields:other.unknownFields]; return self; } - (PBMethodOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBMethodOptions_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 7994: { PBUninterpretedOption_Builder* subBuilder = [PBUninterpretedOption builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addUninterpretedOption:[subBuilder buildPartial]]; break; } } } } - (PBAppendableArray *)uninterpretedOption { return result.uninterpretedOptionArray; } - (PBUninterpretedOption*)uninterpretedOptionAtIndex:(NSUInteger)index { return [result uninterpretedOptionAtIndex:index]; } - (PBMethodOptions_Builder *)addUninterpretedOption:(PBUninterpretedOption*)value { if (result.uninterpretedOptionArray == nil) { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.uninterpretedOptionArray addObject:value]; return self; } - (PBMethodOptions_Builder *)setUninterpretedOptionArray:(NSArray *)array { result.uninterpretedOptionArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBMethodOptions_Builder *)setUninterpretedOptionValues:(const PBUninterpretedOption* *)values count:(NSUInteger)count { result.uninterpretedOptionArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBMethodOptions_Builder *)clearUninterpretedOption { result.uninterpretedOptionArray = nil; return self; } @end @interface PBUninterpretedOption () @property (retain) PBAppendableArray * nameArray; @property (retain) NSString* identifierValue; @property int64_t positiveIntValue; @property int64_t negativeIntValue; @property Float64 doubleValue; @property (retain) NSData* stringValue; @end @implementation PBUninterpretedOption @synthesize nameArray; @dynamic name; - (BOOL) hasIdentifierValue { return !!hasIdentifierValue_; } - (void) setHasIdentifierValue:(BOOL) value { hasIdentifierValue_ = !!value; } @synthesize identifierValue; - (BOOL) hasPositiveIntValue { return !!hasPositiveIntValue_; } - (void) setHasPositiveIntValue:(BOOL) value { hasPositiveIntValue_ = !!value; } @synthesize positiveIntValue; - (BOOL) hasNegativeIntValue { return !!hasNegativeIntValue_; } - (void) setHasNegativeIntValue:(BOOL) value { hasNegativeIntValue_ = !!value; } @synthesize negativeIntValue; - (BOOL) hasDoubleValue { return !!hasDoubleValue_; } - (void) setHasDoubleValue:(BOOL) value { hasDoubleValue_ = !!value; } @synthesize doubleValue; - (BOOL) hasStringValue { return !!hasStringValue_; } - (void) setHasStringValue:(BOOL) value { hasStringValue_ = !!value; } @synthesize stringValue; - (void) dealloc { self.nameArray = nil; self.identifierValue = nil; self.stringValue = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.identifierValue = @""; self.positiveIntValue = 0L; self.negativeIntValue = 0L; self.doubleValue = 0; self.stringValue = [NSData data]; } return self; } static PBUninterpretedOption* defaultPBUninterpretedOptionInstance = nil; + (void) initialize { if (self == [PBUninterpretedOption class]) { defaultPBUninterpretedOptionInstance = [[PBUninterpretedOption alloc] init]; } } + (PBUninterpretedOption*) defaultInstance { return defaultPBUninterpretedOptionInstance; } - (PBUninterpretedOption*) defaultInstance { return defaultPBUninterpretedOptionInstance; } - (PBArray *)name { return nameArray; } - (PBUninterpretedOption_NamePart*)nameAtIndex:(NSUInteger)index { return [nameArray objectAtIndex:index]; } - (BOOL) isInitialized { for (PBUninterpretedOption_NamePart* element in self.name) { if (!element.isInitialized) { return NO; } } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { for (PBUninterpretedOption_NamePart *element in self.nameArray) { [output writeMessage:2 value:element]; } if (self.hasIdentifierValue) { [output writeString:3 value:self.identifierValue]; } if (self.hasPositiveIntValue) { [output writeUInt64:4 value:self.positiveIntValue]; } if (self.hasNegativeIntValue) { [output writeInt64:5 value:self.negativeIntValue]; } if (self.hasDoubleValue) { [output writeDouble:6 value:self.doubleValue]; } if (self.hasStringValue) { [output writeData:7 value:self.stringValue]; } [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; for (PBUninterpretedOption_NamePart *element in self.nameArray) { size += computeMessageSize(2, element); } if (self.hasIdentifierValue) { size += computeStringSize(3, self.identifierValue); } if (self.hasPositiveIntValue) { size += computeUInt64Size(4, self.positiveIntValue); } if (self.hasNegativeIntValue) { size += computeInt64Size(5, self.negativeIntValue); } if (self.hasDoubleValue) { size += computeDoubleSize(6, self.doubleValue); } if (self.hasStringValue) { size += computeDataSize(7, self.stringValue); } size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBUninterpretedOption*) parseFromData:(NSData*) data { return (PBUninterpretedOption*)[[[PBUninterpretedOption builder] mergeFromData:data] build]; } + (PBUninterpretedOption*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBUninterpretedOption*)[[[PBUninterpretedOption builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBUninterpretedOption*) parseFromInputStream:(NSInputStream*) input { return (PBUninterpretedOption*)[[[PBUninterpretedOption builder] mergeFromInputStream:input] build]; } + (PBUninterpretedOption*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBUninterpretedOption*)[[[PBUninterpretedOption builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBUninterpretedOption*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBUninterpretedOption*)[[[PBUninterpretedOption builder] mergeFromCodedInputStream:input] build]; } + (PBUninterpretedOption*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBUninterpretedOption*)[[[PBUninterpretedOption builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBUninterpretedOption_Builder*) builder { return [[[PBUninterpretedOption_Builder alloc] init] autorelease]; } + (PBUninterpretedOption_Builder*) builderWithPrototype:(PBUninterpretedOption*) prototype { return [[PBUninterpretedOption builder] mergeFrom:prototype]; } - (PBUninterpretedOption_Builder*) builder { return [PBUninterpretedOption builder]; } @end @interface PBUninterpretedOption_NamePart () @property (retain) NSString* namePart; @property BOOL isExtension; @end @implementation PBUninterpretedOption_NamePart - (BOOL) hasNamePart { return !!hasNamePart_; } - (void) setHasNamePart:(BOOL) value { hasNamePart_ = !!value; } @synthesize namePart; - (BOOL) hasIsExtension { return !!hasIsExtension_; } - (void) setHasIsExtension:(BOOL) value { hasIsExtension_ = !!value; } - (BOOL) isExtension { return !!isExtension_; } - (void) setIsExtension:(BOOL) value { isExtension_ = !!value; } - (void) dealloc { self.namePart = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.namePart = @""; self.isExtension = NO; } return self; } static PBUninterpretedOption_NamePart* defaultPBUninterpretedOption_NamePartInstance = nil; + (void) initialize { if (self == [PBUninterpretedOption_NamePart class]) { defaultPBUninterpretedOption_NamePartInstance = [[PBUninterpretedOption_NamePart alloc] init]; } } + (PBUninterpretedOption_NamePart*) defaultInstance { return defaultPBUninterpretedOption_NamePartInstance; } - (PBUninterpretedOption_NamePart*) defaultInstance { return defaultPBUninterpretedOption_NamePartInstance; } - (BOOL) isInitialized { if (!self.hasNamePart) { return NO; } if (!self.hasIsExtension) { return NO; } return YES; } - (void) writeToCodedOutputStream:(PBCodedOutputStream*) output { if (self.hasNamePart) { [output writeString:1 value:self.namePart]; } if (self.hasIsExtension) { [output writeBool:2 value:self.isExtension]; } [self.unknownFields writeToCodedOutputStream:output]; } - (int32_t) serializedSize { int32_t size = memoizedSerializedSize; if (size != -1) { return size; } size = 0; if (self.hasNamePart) { size += computeStringSize(1, self.namePart); } if (self.hasIsExtension) { size += computeBoolSize(2, self.isExtension); } size += self.unknownFields.serializedSize; memoizedSerializedSize = size; return size; } + (PBUninterpretedOption_NamePart*) parseFromData:(NSData*) data { return (PBUninterpretedOption_NamePart*)[[[PBUninterpretedOption_NamePart builder] mergeFromData:data] build]; } + (PBUninterpretedOption_NamePart*) parseFromData:(NSData*) data extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBUninterpretedOption_NamePart*)[[[PBUninterpretedOption_NamePart builder] mergeFromData:data extensionRegistry:extensionRegistry] build]; } + (PBUninterpretedOption_NamePart*) parseFromInputStream:(NSInputStream*) input { return (PBUninterpretedOption_NamePart*)[[[PBUninterpretedOption_NamePart builder] mergeFromInputStream:input] build]; } + (PBUninterpretedOption_NamePart*) parseFromInputStream:(NSInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBUninterpretedOption_NamePart*)[[[PBUninterpretedOption_NamePart builder] mergeFromInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBUninterpretedOption_NamePart*) parseFromCodedInputStream:(PBCodedInputStream*) input { return (PBUninterpretedOption_NamePart*)[[[PBUninterpretedOption_NamePart builder] mergeFromCodedInputStream:input] build]; } + (PBUninterpretedOption_NamePart*) parseFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { return (PBUninterpretedOption_NamePart*)[[[PBUninterpretedOption_NamePart builder] mergeFromCodedInputStream:input extensionRegistry:extensionRegistry] build]; } + (PBUninterpretedOption_NamePart_Builder*) builder { return [[[PBUninterpretedOption_NamePart_Builder alloc] init] autorelease]; } + (PBUninterpretedOption_NamePart_Builder*) builderWithPrototype:(PBUninterpretedOption_NamePart*) prototype { return [[PBUninterpretedOption_NamePart builder] mergeFrom:prototype]; } - (PBUninterpretedOption_NamePart_Builder*) builder { return [PBUninterpretedOption_NamePart builder]; } @end @interface PBUninterpretedOption_NamePart_Builder() @property (retain) PBUninterpretedOption_NamePart* result; @end @implementation PBUninterpretedOption_NamePart_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBUninterpretedOption_NamePart alloc] init] autorelease]; } return self; } - (PBGeneratedMessage*) internalGetResult { return result; } - (PBUninterpretedOption_NamePart_Builder*) clear { self.result = [[[PBUninterpretedOption_NamePart alloc] init] autorelease]; return self; } - (PBUninterpretedOption_NamePart_Builder*) clone { return [PBUninterpretedOption_NamePart builderWithPrototype:result]; } - (PBUninterpretedOption_NamePart*) defaultInstance { return [PBUninterpretedOption_NamePart defaultInstance]; } - (PBUninterpretedOption_NamePart*) build { [self checkInitialized]; return [self buildPartial]; } - (PBUninterpretedOption_NamePart*) buildPartial { PBUninterpretedOption_NamePart* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBUninterpretedOption_NamePart_Builder*) mergeFrom:(PBUninterpretedOption_NamePart*) other { if (other == [PBUninterpretedOption_NamePart defaultInstance]) { return self; } if (other.hasNamePart) { [self setNamePart:other.namePart]; } if (other.hasIsExtension) { [self setIsExtension:other.isExtension]; } [self mergeUnknownFields:other.unknownFields]; return self; } - (PBUninterpretedOption_NamePart_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBUninterpretedOption_NamePart_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 10: { [self setNamePart:[input readString]]; break; } case 16: { [self setIsExtension:[input readBool]]; break; } } } } - (BOOL) hasNamePart { return result.hasNamePart; } - (NSString*) namePart { return result.namePart; } - (PBUninterpretedOption_NamePart_Builder*) setNamePart:(NSString*) value { result.hasNamePart = YES; result.namePart = value; return self; } - (PBUninterpretedOption_NamePart_Builder*) clearNamePart { result.hasNamePart = NO; result.namePart = @""; return self; } - (BOOL) hasIsExtension { return result.hasIsExtension; } - (BOOL) isExtension { return result.isExtension; } - (PBUninterpretedOption_NamePart_Builder*) setIsExtension:(BOOL) value { result.hasIsExtension = YES; result.isExtension = value; return self; } - (PBUninterpretedOption_NamePart_Builder*) clearIsExtension { result.hasIsExtension = NO; result.isExtension = NO; return self; } @end @interface PBUninterpretedOption_Builder() @property (retain) PBUninterpretedOption* result; @end @implementation PBUninterpretedOption_Builder @synthesize result; - (void) dealloc { self.result = nil; [super dealloc]; } - (id) init { if ((self = [super init])) { self.result = [[[PBUninterpretedOption alloc] init] autorelease]; } return self; } - (PBGeneratedMessage*) internalGetResult { return result; } - (PBUninterpretedOption_Builder*) clear { self.result = [[[PBUninterpretedOption alloc] init] autorelease]; return self; } - (PBUninterpretedOption_Builder*) clone { return [PBUninterpretedOption builderWithPrototype:result]; } - (PBUninterpretedOption*) defaultInstance { return [PBUninterpretedOption defaultInstance]; } - (PBUninterpretedOption*) build { [self checkInitialized]; return [self buildPartial]; } - (PBUninterpretedOption*) buildPartial { PBUninterpretedOption* returnMe = [[result retain] autorelease]; self.result = nil; return returnMe; } - (PBUninterpretedOption_Builder*) mergeFrom:(PBUninterpretedOption*) other { if (other == [PBUninterpretedOption defaultInstance]) { return self; } if (other.nameArray.count > 0) { if (result.nameArray == nil) { result.nameArray = [other.nameArray copyWithZone:[other.nameArray zone]]; } else { [result.nameArray appendArray:other.nameArray]; } } if (other.hasIdentifierValue) { [self setIdentifierValue:other.identifierValue]; } if (other.hasPositiveIntValue) { [self setPositiveIntValue:other.positiveIntValue]; } if (other.hasNegativeIntValue) { [self setNegativeIntValue:other.negativeIntValue]; } if (other.hasDoubleValue) { [self setDoubleValue:other.doubleValue]; } if (other.hasStringValue) { [self setStringValue:other.stringValue]; } [self mergeUnknownFields:other.unknownFields]; return self; } - (PBUninterpretedOption_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input { return [self mergeFromCodedInputStream:input extensionRegistry:[PBExtensionRegistry emptyRegistry]]; } - (PBUninterpretedOption_Builder*) mergeFromCodedInputStream:(PBCodedInputStream*) input extensionRegistry:(PBExtensionRegistry*) extensionRegistry { PBUnknownFieldSet_Builder* unknownFields = [PBUnknownFieldSet builderWithUnknownFields:self.unknownFields]; while (YES) { int32_t tag = [input readTag]; switch (tag) { case 0: [self setUnknownFields:[unknownFields build]]; return self; default: { if (![self parseUnknownField:input unknownFields:unknownFields extensionRegistry:extensionRegistry tag:tag]) { [self setUnknownFields:[unknownFields build]]; return self; } break; } case 18: { PBUninterpretedOption_NamePart_Builder* subBuilder = [PBUninterpretedOption_NamePart builder]; [input readMessage:subBuilder extensionRegistry:extensionRegistry]; [self addName:[subBuilder buildPartial]]; break; } case 26: { [self setIdentifierValue:[input readString]]; break; } case 32: { [self setPositiveIntValue:[input readUInt64]]; break; } case 40: { [self setNegativeIntValue:[input readInt64]]; break; } case 49: { [self setDoubleValue:[input readDouble]]; break; } case 58: { [self setStringValue:[input readData]]; break; } } } } - (PBAppendableArray *)name { return result.nameArray; } - (PBUninterpretedOption_NamePart*)nameAtIndex:(NSUInteger)index { return [result nameAtIndex:index]; } - (PBUninterpretedOption_Builder *)addName:(PBUninterpretedOption_NamePart*)value { if (result.nameArray == nil) { result.nameArray = [PBAppendableArray arrayWithValueType:PBArrayValueTypeObject]; } [result.nameArray addObject:value]; return self; } - (PBUninterpretedOption_Builder *)setNameArray:(NSArray *)array { result.nameArray = [PBAppendableArray arrayWithArray:array valueType:PBArrayValueTypeObject]; return self; } - (PBUninterpretedOption_Builder *)setNameValues:(const PBUninterpretedOption_NamePart* *)values count:(NSUInteger)count { result.nameArray = [PBAppendableArray arrayWithValues:values count:count valueType:PBArrayValueTypeObject]; return self; } - (PBUninterpretedOption_Builder *)clearName { result.nameArray = nil; return self; } - (BOOL) hasIdentifierValue { return result.hasIdentifierValue; } - (NSString*) identifierValue { return result.identifierValue; } - (PBUninterpretedOption_Builder*) setIdentifierValue:(NSString*) value { result.hasIdentifierValue = YES; result.identifierValue = value; return self; } - (PBUninterpretedOption_Builder*) clearIdentifierValue { result.hasIdentifierValue = NO; result.identifierValue = @""; return self; } - (BOOL) hasPositiveIntValue { return result.hasPositiveIntValue; } - (int64_t) positiveIntValue { return result.positiveIntValue; } - (PBUninterpretedOption_Builder*) setPositiveIntValue:(int64_t) value { result.hasPositiveIntValue = YES; result.positiveIntValue = value; return self; } - (PBUninterpretedOption_Builder*) clearPositiveIntValue { result.hasPositiveIntValue = NO; result.positiveIntValue = 0L; return self; } - (BOOL) hasNegativeIntValue { return result.hasNegativeIntValue; } - (int64_t) negativeIntValue { return result.negativeIntValue; } - (PBUninterpretedOption_Builder*) setNegativeIntValue:(int64_t) value { result.hasNegativeIntValue = YES; result.negativeIntValue = value; return self; } - (PBUninterpretedOption_Builder*) clearNegativeIntValue { result.hasNegativeIntValue = NO; result.negativeIntValue = 0L; return self; } - (BOOL) hasDoubleValue { return result.hasDoubleValue; } - (Float64) doubleValue { return result.doubleValue; } - (PBUninterpretedOption_Builder*) setDoubleValue:(Float64) value { result.hasDoubleValue = YES; result.doubleValue = value; return self; } - (PBUninterpretedOption_Builder*) clearDoubleValue { result.hasDoubleValue = NO; result.doubleValue = 0; return self; } - (BOOL) hasStringValue { return result.hasStringValue; } - (NSData*) stringValue { return result.stringValue; } - (PBUninterpretedOption_Builder*) setStringValue:(NSData*) value { result.hasStringValue = YES; result.stringValue = value; return self; } - (PBUninterpretedOption_Builder*) clearStringValue { result.hasStringValue = NO; result.stringValue = [NSData data]; return self; } @end