aboutsummaryrefslogtreecommitdiff
path: root/objectivec/GPBDescriptor.h
diff options
context:
space:
mode:
Diffstat (limited to 'objectivec/GPBDescriptor.h')
-rw-r--r--objectivec/GPBDescriptor.h17
1 files changed, 6 insertions, 11 deletions
diff --git a/objectivec/GPBDescriptor.h b/objectivec/GPBDescriptor.h
index 360afe96..a6eff0fb 100644
--- a/objectivec/GPBDescriptor.h
+++ b/objectivec/GPBDescriptor.h
@@ -34,19 +34,18 @@
@class GPBEnumDescriptor;
@class GPBFieldDescriptor;
-@class GPBFieldOptions;
@class GPBFileDescriptor;
@class GPBOneofDescriptor;
NS_ASSUME_NONNULL_BEGIN
-typedef NS_ENUM(NSInteger, GPBFileSyntax) {
+typedef NS_ENUM(uint8_t, GPBFileSyntax) {
GPBFileSyntaxUnknown = 0,
GPBFileSyntaxProto2 = 2,
GPBFileSyntaxProto3 = 3,
};
-typedef NS_ENUM(NSInteger, GPBFieldType) {
+typedef NS_ENUM(uint8_t, GPBFieldType) {
GPBFieldTypeSingle, // optional/required
GPBFieldTypeRepeated, // repeated
GPBFieldTypeMap, // map<K,V>
@@ -55,11 +54,10 @@ typedef NS_ENUM(NSInteger, GPBFieldType) {
@interface GPBDescriptor : NSObject<NSCopying>
@property(nonatomic, readonly, copy) NSString *name;
-@property(nonatomic, readonly, strong, nullable) NSArray *fields;
-@property(nonatomic, readonly, strong, nullable) NSArray *oneofs;
-@property(nonatomic, readonly, strong, nullable) NSArray *enums;
+@property(nonatomic, readonly, strong, nullable) NSArray<GPBFieldDescriptor*> *fields;
+@property(nonatomic, readonly, strong, nullable) NSArray<GPBOneofDescriptor*> *oneofs;
@property(nonatomic, readonly, nullable) const GPBExtensionRange *extensionRanges;
-@property(nonatomic, readonly) NSUInteger extensionRangesCount;
+@property(nonatomic, readonly) uint32_t extensionRangesCount;
@property(nonatomic, readonly, assign) GPBFileDescriptor *file;
@property(nonatomic, readonly, getter=isWireFormat) BOOL wireFormat;
@@ -68,7 +66,6 @@ typedef NS_ENUM(NSInteger, GPBFieldType) {
- (nullable GPBFieldDescriptor *)fieldWithNumber:(uint32_t)fieldNumber;
- (nullable GPBFieldDescriptor *)fieldWithName:(NSString *)name;
- (nullable GPBOneofDescriptor *)oneofWithName:(NSString *)name;
-- (nullable GPBEnumDescriptor *)enumWithName:(NSString *)name;
@end
@@ -81,7 +78,7 @@ typedef NS_ENUM(NSInteger, GPBFieldType) {
@interface GPBOneofDescriptor : NSObject
@property(nonatomic, readonly) NSString *name;
-@property(nonatomic, readonly) NSArray *fields;
+@property(nonatomic, readonly) NSArray<GPBFieldDescriptor*> *fields;
- (nullable GPBFieldDescriptor *)fieldWithNumber:(uint32_t)fieldNumber;
- (nullable GPBFieldDescriptor *)fieldWithName:(NSString *)name;
@@ -103,8 +100,6 @@ typedef NS_ENUM(NSInteger, GPBFieldType) {
@property(nonatomic, readonly, assign, nullable) GPBOneofDescriptor *containingOneof;
-@property(nonatomic, readonly, nullable) GPBFieldOptions *fieldOptions;
-
// Message properties
@property(nonatomic, readonly, assign, nullable) Class msgClass;