status.pb.go 7.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206
  1. // Copyright 2020 Google LLC
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. // Code generated by protoc-gen-go. DO NOT EDIT.
  15. // versions:
  16. // protoc-gen-go v1.25.0
  17. // protoc v3.12.3
  18. // source: google/rpc/status.proto
  19. package status
  20. import (
  21. reflect "reflect"
  22. sync "sync"
  23. proto "github.com/golang/protobuf/proto"
  24. protoreflect "google.golang.org/protobuf/reflect/protoreflect"
  25. protoimpl "google.golang.org/protobuf/runtime/protoimpl"
  26. anypb "google.golang.org/protobuf/types/known/anypb"
  27. )
  28. const (
  29. // Verify that this generated code is sufficiently up-to-date.
  30. _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
  31. // Verify that runtime/protoimpl is sufficiently up-to-date.
  32. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
  33. )
  34. // This is a compile-time assertion that a sufficiently up-to-date version
  35. // of the legacy proto package is being used.
  36. const _ = proto.ProtoPackageIsVersion4
  37. // The `Status` type defines a logical error model that is suitable for
  38. // different programming environments, including REST APIs and RPC APIs. It is
  39. // used by [gRPC](https://github.com/grpc). Each `Status` message contains
  40. // three pieces of data: error code, error message, and error details.
  41. //
  42. // You can find out more about this error model and how to work with it in the
  43. // [API Design Guide](https://cloud.google.com/apis/design/errors).
  44. type Status struct {
  45. state protoimpl.MessageState
  46. sizeCache protoimpl.SizeCache
  47. unknownFields protoimpl.UnknownFields
  48. // The status code, which should be an enum value of [google.rpc.Code][google.rpc.Code].
  49. Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
  50. // A developer-facing error message, which should be in English. Any
  51. // user-facing error message should be localized and sent in the
  52. // [google.rpc.Status.details][google.rpc.Status.details] field, or localized by the client.
  53. Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
  54. // A list of messages that carry the error details. There is a common set of
  55. // message types for APIs to use.
  56. Details []*anypb.Any `protobuf:"bytes,3,rep,name=details,proto3" json:"details,omitempty"`
  57. }
  58. func (x *Status) Reset() {
  59. *x = Status{}
  60. if protoimpl.UnsafeEnabled {
  61. mi := &file_google_rpc_status_proto_msgTypes[0]
  62. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  63. ms.StoreMessageInfo(mi)
  64. }
  65. }
  66. func (x *Status) String() string {
  67. return protoimpl.X.MessageStringOf(x)
  68. }
  69. func (*Status) ProtoMessage() {}
  70. func (x *Status) ProtoReflect() protoreflect.Message {
  71. mi := &file_google_rpc_status_proto_msgTypes[0]
  72. if protoimpl.UnsafeEnabled && x != nil {
  73. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  74. if ms.LoadMessageInfo() == nil {
  75. ms.StoreMessageInfo(mi)
  76. }
  77. return ms
  78. }
  79. return mi.MessageOf(x)
  80. }
  81. // Deprecated: Use Status.ProtoReflect.Descriptor instead.
  82. func (*Status) Descriptor() ([]byte, []int) {
  83. return file_google_rpc_status_proto_rawDescGZIP(), []int{0}
  84. }
  85. func (x *Status) GetCode() int32 {
  86. if x != nil {
  87. return x.Code
  88. }
  89. return 0
  90. }
  91. func (x *Status) GetMessage() string {
  92. if x != nil {
  93. return x.Message
  94. }
  95. return ""
  96. }
  97. func (x *Status) GetDetails() []*anypb.Any {
  98. if x != nil {
  99. return x.Details
  100. }
  101. return nil
  102. }
  103. var File_google_rpc_status_proto protoreflect.FileDescriptor
  104. var file_google_rpc_status_proto_rawDesc = []byte{
  105. 0x0a, 0x17, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x72, 0x70, 0x63, 0x2f, 0x73, 0x74, 0x61,
  106. 0x74, 0x75, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0a, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
  107. 0x65, 0x2e, 0x72, 0x70, 0x63, 0x1a, 0x19, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72,
  108. 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x61, 0x6e, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
  109. 0x22, 0x66, 0x0a, 0x06, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f,
  110. 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x18,
  111. 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
  112. 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x2e, 0x0a, 0x07, 0x64, 0x65, 0x74, 0x61,
  113. 0x69, 0x6c, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67,
  114. 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52,
  115. 0x07, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x42, 0x61, 0x0a, 0x0e, 0x63, 0x6f, 0x6d, 0x2e,
  116. 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x72, 0x70, 0x63, 0x42, 0x0b, 0x53, 0x74, 0x61, 0x74,
  117. 0x75, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x37, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
  118. 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x67, 0x65, 0x6e,
  119. 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x61, 0x70, 0x69, 0x73,
  120. 0x2f, 0x72, 0x70, 0x63, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x3b, 0x73, 0x74, 0x61, 0x74,
  121. 0x75, 0x73, 0xf8, 0x01, 0x01, 0xa2, 0x02, 0x03, 0x52, 0x50, 0x43, 0x62, 0x06, 0x70, 0x72, 0x6f,
  122. 0x74, 0x6f, 0x33,
  123. }
  124. var (
  125. file_google_rpc_status_proto_rawDescOnce sync.Once
  126. file_google_rpc_status_proto_rawDescData = file_google_rpc_status_proto_rawDesc
  127. )
  128. func file_google_rpc_status_proto_rawDescGZIP() []byte {
  129. file_google_rpc_status_proto_rawDescOnce.Do(func() {
  130. file_google_rpc_status_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_rpc_status_proto_rawDescData)
  131. })
  132. return file_google_rpc_status_proto_rawDescData
  133. }
  134. var file_google_rpc_status_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
  135. var file_google_rpc_status_proto_goTypes = []interface{}{
  136. (*Status)(nil), // 0: google.rpc.Status
  137. (*anypb.Any)(nil), // 1: google.protobuf.Any
  138. }
  139. var file_google_rpc_status_proto_depIdxs = []int32{
  140. 1, // 0: google.rpc.Status.details:type_name -> google.protobuf.Any
  141. 1, // [1:1] is the sub-list for method output_type
  142. 1, // [1:1] is the sub-list for method input_type
  143. 1, // [1:1] is the sub-list for extension type_name
  144. 1, // [1:1] is the sub-list for extension extendee
  145. 0, // [0:1] is the sub-list for field type_name
  146. }
  147. func init() { file_google_rpc_status_proto_init() }
  148. func file_google_rpc_status_proto_init() {
  149. if File_google_rpc_status_proto != nil {
  150. return
  151. }
  152. if !protoimpl.UnsafeEnabled {
  153. file_google_rpc_status_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
  154. switch v := v.(*Status); i {
  155. case 0:
  156. return &v.state
  157. case 1:
  158. return &v.sizeCache
  159. case 2:
  160. return &v.unknownFields
  161. default:
  162. return nil
  163. }
  164. }
  165. }
  166. type x struct{}
  167. out := protoimpl.TypeBuilder{
  168. File: protoimpl.DescBuilder{
  169. GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
  170. RawDescriptor: file_google_rpc_status_proto_rawDesc,
  171. NumEnums: 0,
  172. NumMessages: 1,
  173. NumExtensions: 0,
  174. NumServices: 0,
  175. },
  176. GoTypes: file_google_rpc_status_proto_goTypes,
  177. DependencyIndexes: file_google_rpc_status_proto_depIdxs,
  178. MessageInfos: file_google_rpc_status_proto_msgTypes,
  179. }.Build()
  180. File_google_rpc_status_proto = out.File
  181. file_google_rpc_status_proto_rawDesc = nil
  182. file_google_rpc_status_proto_goTypes = nil
  183. file_google_rpc_status_proto_depIdxs = nil
  184. }