Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(477)

Side by Side Diff: third_party/protobuf/objectivec/google/protobuf/Any.pbobjc.h

Issue 2495533002: third_party/protobuf: Update to HEAD (83d681ee2c) (Closed)
Patch Set: Make chrome settings proto generated file a component Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Generated by the protocol buffer compiler. DO NOT EDIT! 1 // Generated by the protocol buffer compiler. DO NOT EDIT!
2 // source: google/protobuf/any.proto 2 // source: google/protobuf/any.proto
3 3
4 #import "GPBProtocolBuffers.h" 4 // This CPP symbol can be defined to use imports that match up to the framework
5 // imports needed when using CocoaPods.
6 #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS)
7 #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0
8 #endif
5 9
6 #if GOOGLE_PROTOBUF_OBJC_GEN_VERSION != 30001 10 #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS
7 #error This file was generated by a different version of protoc which is incompa tible with your Protocol Buffer library sources. 11 #import <Protobuf/GPBProtocolBuffers.h>
12 #else
13 #import "GPBProtocolBuffers.h"
14 #endif
15
16 #if GOOGLE_PROTOBUF_OBJC_VERSION < 30002
17 #error This file was generated by a newer version of protoc which is incompatibl e with your Protocol Buffer library sources.
18 #endif
19 #if 30002 < GOOGLE_PROTOBUF_OBJC_MIN_SUPPORTED_VERSION
20 #error This file was generated by an older version of protoc which is incompatib le with your Protocol Buffer library sources.
8 #endif 21 #endif
9 22
10 // @@protoc_insertion_point(imports) 23 // @@protoc_insertion_point(imports)
11 24
12 #pragma clang diagnostic push 25 #pragma clang diagnostic push
13 #pragma clang diagnostic ignored "-Wdeprecated-declarations" 26 #pragma clang diagnostic ignored "-Wdeprecated-declarations"
14 27
15 CF_EXTERN_C_BEGIN 28 CF_EXTERN_C_BEGIN
16 29
17 NS_ASSUME_NONNULL_BEGIN 30 NS_ASSUME_NONNULL_BEGIN
18 31
19 #pragma mark - GPBAnyRoot 32 #pragma mark - GPBAnyRoot
20 33
21 /// Exposes the extension registry for this file. 34 /**
22 /// 35 * Exposes the extension registry for this file.
23 /// The base class provides: 36 *
24 /// @code 37 * The base class provides:
25 /// + (GPBExtensionRegistry *)extensionRegistry; 38 * @code
26 /// @endcode 39 * + (GPBExtensionRegistry *)extensionRegistry;
27 /// which is a @c GPBExtensionRegistry that includes all the extensions defined by 40 * @endcode
28 /// this file and all files that it depends on. 41 * which is a @c GPBExtensionRegistry that includes all the extensions defined b y
42 * this file and all files that it depends on.
43 **/
29 @interface GPBAnyRoot : GPBRootObject 44 @interface GPBAnyRoot : GPBRootObject
30 @end 45 @end
31 46
32 #pragma mark - GPBAny 47 #pragma mark - GPBAny
33 48
34 typedef GPB_ENUM(GPBAny_FieldNumber) { 49 typedef GPB_ENUM(GPBAny_FieldNumber) {
35 GPBAny_FieldNumber_TypeURL = 1, 50 GPBAny_FieldNumber_TypeURL = 1,
36 GPBAny_FieldNumber_Value = 2, 51 GPBAny_FieldNumber_Value = 2,
37 }; 52 };
38 53
39 /// `Any` contains an arbitrary serialized protocol buffer message along with a 54 /**
40 /// URL that describes the type of the serialized message. 55 * `Any` contains an arbitrary serialized protocol buffer message along with a
41 /// 56 * URL that describes the type of the serialized message.
42 /// Protobuf library provides support to pack/unpack Any values in the form 57 *
43 /// of utility functions or additional generated methods of the Any type. 58 * Protobuf library provides support to pack/unpack Any values in the form
44 /// 59 * of utility functions or additional generated methods of the Any type.
45 /// Example 1: Pack and unpack a message in C++. 60 *
46 /// 61 * Example 1: Pack and unpack a message in C++.
47 /// Foo foo = ...; 62 *
48 /// Any any; 63 * Foo foo = ...;
49 /// any.PackFrom(foo); 64 * Any any;
50 /// ... 65 * any.PackFrom(foo);
51 /// if (any.UnpackTo(&foo)) { 66 * ...
52 /// ... 67 * if (any.UnpackTo(&foo)) {
53 /// } 68 * ...
54 /// 69 * }
55 /// Example 2: Pack and unpack a message in Java. 70 *
56 /// 71 * Example 2: Pack and unpack a message in Java.
57 /// Foo foo = ...; 72 *
58 /// Any any = Any.pack(foo); 73 * Foo foo = ...;
59 /// ... 74 * Any any = Any.pack(foo);
60 /// if (any.is(Foo.class)) { 75 * ...
61 /// foo = any.unpack(Foo.class); 76 * if (any.is(Foo.class)) {
62 /// } 77 * foo = any.unpack(Foo.class);
63 /// 78 * }
64 /// The pack methods provided by protobuf library will by default use 79 *
65 /// 'type.googleapis.com/full.type.name' as the type URL and the unpack 80 * Example 3: Pack and unpack a message in Python.
66 /// methods only use the fully qualified type name after the last '/' 81 *
67 /// in the type URL, for example "foo.bar.com/x/y.z" will yield type 82 * foo = Foo(...)
68 /// name "y.z". 83 * any = Any()
69 /// 84 * any.Pack(foo)
70 /// 85 * ...
71 /// JSON 86 * if any.Is(Foo.DESCRIPTOR):
72 /// ==== 87 * any.Unpack(foo)
73 /// The JSON representation of an `Any` value uses the regular 88 * ...
74 /// representation of the deserialized, embedded message, with an 89 *
75 /// additional field `\@type` which contains the type URL. Example: 90 * The pack methods provided by protobuf library will by default use
76 /// 91 * 'type.googleapis.com/full.type.name' as the type URL and the unpack
77 /// package google.profile; 92 * methods only use the fully qualified type name after the last '/'
78 /// message Person { 93 * in the type URL, for example "foo.bar.com/x/y.z" will yield type
79 /// string first_name = 1; 94 * name "y.z".
80 /// string last_name = 2; 95 *
81 /// } 96 *
82 /// 97 * JSON
83 /// { 98 * ====
84 /// "\@type": "type.googleapis.com/google.profile.Person", 99 * The JSON representation of an `Any` value uses the regular
85 /// "firstName": <string>, 100 * representation of the deserialized, embedded message, with an
86 /// "lastName": <string> 101 * additional field `\@type` which contains the type URL. Example:
87 /// } 102 *
88 /// 103 * package google.profile;
89 /// If the embedded message type is well-known and has a custom JSON 104 * message Person {
90 /// representation, that representation will be embedded adding a field 105 * string first_name = 1;
91 /// `value` which holds the custom JSON in addition to the `\@type` 106 * string last_name = 2;
92 /// field. Example (for message [google.protobuf.Duration][]): 107 * }
93 /// 108 *
94 /// { 109 * {
95 /// "\@type": "type.googleapis.com/google.protobuf.Duration", 110 * "\@type": "type.googleapis.com/google.profile.Person",
96 /// "value": "1.212s" 111 * "firstName": <string>,
97 /// } 112 * "lastName": <string>
113 * }
114 *
115 * If the embedded message type is well-known and has a custom JSON
116 * representation, that representation will be embedded adding a field
117 * `value` which holds the custom JSON in addition to the `\@type`
118 * field. Example (for message [google.protobuf.Duration][]):
119 *
120 * {
121 * "\@type": "type.googleapis.com/google.protobuf.Duration",
122 * "value": "1.212s"
123 * }
124 **/
98 @interface GPBAny : GPBMessage 125 @interface GPBAny : GPBMessage
99 126
100 /// A URL/resource name whose content describes the type of the 127 /**
101 /// serialized protocol buffer message. 128 * A URL/resource name whose content describes the type of the
102 /// 129 * serialized protocol buffer message.
103 /// For URLs which use the schema `http`, `https`, or no schema, the 130 *
104 /// following restrictions and interpretations apply: 131 * For URLs which use the scheme `http`, `https`, or no scheme, the
105 /// 132 * following restrictions and interpretations apply:
106 /// * If no schema is provided, `https` is assumed. 133 *
107 /// * The last segment of the URL's path must represent the fully 134 * * If no scheme is provided, `https` is assumed.
108 /// qualified name of the type (as in `path/google.protobuf.Duration`). 135 * * The last segment of the URL's path must represent the fully
109 /// The name should be in a canonical form (e.g., leading "." is 136 * qualified name of the type (as in `path/google.protobuf.Duration`).
110 /// not accepted). 137 * The name should be in a canonical form (e.g., leading "." is
111 /// * An HTTP GET on the URL must yield a [google.protobuf.Type][] 138 * not accepted).
112 /// value in binary format, or produce an error. 139 * * An HTTP GET on the URL must yield a [google.protobuf.Type][]
113 /// * Applications are allowed to cache lookup results based on the 140 * value in binary format, or produce an error.
114 /// URL, or have them precompiled into a binary to avoid any 141 * * Applications are allowed to cache lookup results based on the
115 /// lookup. Therefore, binary compatibility needs to be preserved 142 * URL, or have them precompiled into a binary to avoid any
116 /// on changes to types. (Use versioned type names to manage 143 * lookup. Therefore, binary compatibility needs to be preserved
117 /// breaking changes.) 144 * on changes to types. (Use versioned type names to manage
118 /// 145 * breaking changes.)
119 /// Schemas other than `http`, `https` (or the empty schema) might be 146 *
120 /// used with implementation specific semantics. 147 * Schemes other than `http`, `https` (or the empty scheme) might be
148 * used with implementation specific semantics.
149 **/
121 @property(nonatomic, readwrite, copy, null_resettable) NSString *typeURL; 150 @property(nonatomic, readwrite, copy, null_resettable) NSString *typeURL;
122 151
123 /// Must be a valid serialized protocol buffer of the above specified type. 152 /** Must be a valid serialized protocol buffer of the above specified type. */
124 @property(nonatomic, readwrite, copy, null_resettable) NSData *value; 153 @property(nonatomic, readwrite, copy, null_resettable) NSData *value;
125 154
126 @end 155 @end
127 156
128 NS_ASSUME_NONNULL_END 157 NS_ASSUME_NONNULL_END
129 158
130 CF_EXTERN_C_END 159 CF_EXTERN_C_END
131 160
132 #pragma clang diagnostic pop 161 #pragma clang diagnostic pop
133 162
134 // @@protoc_insertion_point(global_scope) 163 // @@protoc_insertion_point(global_scope)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698