FieldMask.pbobjc.h 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168
  1. // Generated by the protocol buffer compiler. DO NOT EDIT!
  2. // source: google/protobuf/field_mask.proto
  3. #import "GPBProtocolBuffers.h"
  4. #if GOOGLE_PROTOBUF_OBJC_GEN_VERSION != 30000
  5. #error This file was generated by a different version of protoc-gen-objc which is incompatible with your Protocol Buffer sources.
  6. #endif
  7. // @@protoc_insertion_point(imports)
  8. CF_EXTERN_C_BEGIN
  9. NS_ASSUME_NONNULL_BEGIN
  10. #pragma mark - GPBFieldMaskRoot
  11. @interface GPBFieldMaskRoot : GPBRootObject
  12. // The base class provides:
  13. // + (GPBExtensionRegistry *)extensionRegistry;
  14. // which is an GPBExtensionRegistry that includes all the extensions defined by
  15. // this file and all files that it depends on.
  16. @end
  17. #pragma mark - GPBFieldMask
  18. typedef GPB_ENUM(GPBFieldMask_FieldNumber) {
  19. GPBFieldMask_FieldNumber_PathsArray = 1,
  20. };
  21. // `FieldMask` represents a set of symbolic field paths, for example:
  22. //
  23. // paths: "f.a"
  24. // paths: "f.b.d"
  25. //
  26. // Here `f` represents a field in some root message, `a` and `b`
  27. // fields in the message found in `f`, and `d` a field found in the
  28. // message in `f.b`.
  29. //
  30. // Field masks are used to specify a subset of fields that should be
  31. // returned by a get operation or modified by an update operation.
  32. // Field masks also have a custom JSON encoding (see below).
  33. //
  34. // # Field Masks in Projections
  35. //
  36. // When used in the context of a projection, a response message or
  37. // sub-message is filtered by the API to only contain those fields as
  38. // specified in the mask. For example, if the mask in the previous
  39. // example is applied to a response message as follows:
  40. //
  41. // f {
  42. // a : 22
  43. // b {
  44. // d : 1
  45. // x : 2
  46. // }
  47. // y : 13
  48. // }
  49. // z: 8
  50. //
  51. // The result will not contain specific values for fields x,y and z
  52. // (there value will be set to the default, and omitted in proto text
  53. // output):
  54. //
  55. //
  56. // f {
  57. // a : 22
  58. // b {
  59. // d : 1
  60. // }
  61. // }
  62. //
  63. // A repeated field is not allowed except at the last position of a
  64. // field mask.
  65. //
  66. // If a FieldMask object is not present in a get operation, the
  67. // operation applies to all fields (as if a FieldMask of all fields
  68. // had been specified).
  69. //
  70. // Note that a field mask does not necessarily applies to the
  71. // top-level response message. In case of a REST get operation, the
  72. // field mask applies directly to the response, but in case of a REST
  73. // list operation, the mask instead applies to each individual message
  74. // in the returned resource list. In case of a REST custom method,
  75. // other definitions may be used. Where the mask applies will be
  76. // clearly documented together with its declaration in the API. In
  77. // any case, the effect on the returned resource/resources is required
  78. // behavior for APIs.
  79. //
  80. // # Field Masks in Update Operations
  81. //
  82. // A field mask in update operations specifies which fields of the
  83. // targeted resource are going to be updated. The API is required
  84. // to only change the values of the fields as specified in the mask
  85. // and leave the others untouched. If a resource is passed in to
  86. // describe the updated values, the API ignores the values of all
  87. // fields not covered by the mask.
  88. //
  89. // In order to reset a field's value to the default, the field must
  90. // be in the mask and set to the default value in the provided resource.
  91. // Hence, in order to reset all fields of a resource, provide a default
  92. // instance of the resource and set all fields in the mask, or do
  93. // not provide a mask as described below.
  94. //
  95. // If a field mask is not present on update, the operation applies to
  96. // all fields (as if a field mask of all fields has been specified).
  97. // Note that in the presence of schema evolution, this may mean that
  98. // fields the client does not know and has therefore not filled into
  99. // the request will be reset to their default. If this is unwanted
  100. // behavior, a specific service may require a client to always specify
  101. // a field mask, producing an error if not.
  102. //
  103. // As with get operations, the location of the resource which
  104. // describes the updated values in the request message depends on the
  105. // operation kind. In any case, the effect of the field mask is
  106. // required to be honored by the API.
  107. //
  108. // ## Considerations for HTTP REST
  109. //
  110. // The HTTP kind of an update operation which uses a field mask must
  111. // be set to PATCH instead of PUT in order to satisfy HTTP semantics
  112. // (PUT must only be used for full updates).
  113. //
  114. // # JSON Encoding of Field Masks
  115. //
  116. // In JSON, a field mask is encoded as a single string where paths are
  117. // separated by a comma. Fields name in each path are converted
  118. // to/from lower-camel naming conventions.
  119. //
  120. // As an example, consider the following message declarations:
  121. //
  122. // message Profile {
  123. // User user = 1;
  124. // Photo photo = 2;
  125. // }
  126. // message User {
  127. // string display_name = 1;
  128. // string address = 2;
  129. // }
  130. //
  131. // In proto a field mask for `Profile` may look as such:
  132. //
  133. // mask {
  134. // paths: "user.display_name"
  135. // paths: "photo"
  136. // }
  137. //
  138. // In JSON, the same mask is represented as below:
  139. //
  140. // {
  141. // mask: "user.displayName,photo"
  142. // }
  143. @interface GPBFieldMask : GPBMessage
  144. // The set of field mask paths.
  145. // |pathsArray| contains |NSString|
  146. @property(nonatomic, readwrite, strong, null_resettable) NSMutableArray *pathsArray;
  147. @property(nonatomic, readonly) NSUInteger pathsArray_Count;
  148. @end
  149. NS_ASSUME_NONNULL_END
  150. CF_EXTERN_C_END
  151. // @@protoc_insertion_point(global_scope)