gitee.com/ks-custle/core-gm@v0.0.0-20230922171213-b83bdd97b62c/grpc/interop/grpc_testing/core/stats.pb.go (about)

     1  // Copyright 2017 gRPC authors.
     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  
    15  // Code generated by protoc-gen-go. DO NOT EDIT.
    16  // versions:
    17  // 	protoc-gen-go v1.25.0
    18  // 	protoc        v3.14.0
    19  // source: grpc/core/stats.proto
    20  
    21  package grpc_core
    22  
    23  import (
    24  	proto "github.com/golang/protobuf/proto"
    25  	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
    26  	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
    27  	reflect "reflect"
    28  	sync "sync"
    29  )
    30  
    31  const (
    32  	// Verify that this generated code is sufficiently up-to-date.
    33  	_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
    34  	// Verify that runtime/protoimpl is sufficiently up-to-date.
    35  	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
    36  )
    37  
    38  // This is a compile-time assertion that a sufficiently up-to-date version
    39  // of the legacy proto package is being used.
    40  const _ = proto.ProtoPackageIsVersion4
    41  
    42  type Bucket struct {
    43  	state         protoimpl.MessageState
    44  	sizeCache     protoimpl.SizeCache
    45  	unknownFields protoimpl.UnknownFields
    46  
    47  	Start float64 `protobuf:"fixed64,1,opt,name=start,proto3" json:"start,omitempty"`
    48  	Count uint64  `protobuf:"varint,2,opt,name=count,proto3" json:"count,omitempty"`
    49  }
    50  
    51  func (x *Bucket) Reset() {
    52  	*x = Bucket{}
    53  	if protoimpl.UnsafeEnabled {
    54  		mi := &file_grpc_core_stats_proto_msgTypes[0]
    55  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
    56  		ms.StoreMessageInfo(mi)
    57  	}
    58  }
    59  
    60  func (x *Bucket) String() string {
    61  	return protoimpl.X.MessageStringOf(x)
    62  }
    63  
    64  func (*Bucket) ProtoMessage() {}
    65  
    66  func (x *Bucket) ProtoReflect() protoreflect.Message {
    67  	mi := &file_grpc_core_stats_proto_msgTypes[0]
    68  	if protoimpl.UnsafeEnabled && x != nil {
    69  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
    70  		if ms.LoadMessageInfo() == nil {
    71  			ms.StoreMessageInfo(mi)
    72  		}
    73  		return ms
    74  	}
    75  	return mi.MessageOf(x)
    76  }
    77  
    78  // Deprecated: Use Bucket.ProtoReflect.Descriptor instead.
    79  func (*Bucket) Descriptor() ([]byte, []int) {
    80  	return file_grpc_core_stats_proto_rawDescGZIP(), []int{0}
    81  }
    82  
    83  func (x *Bucket) GetStart() float64 {
    84  	if x != nil {
    85  		return x.Start
    86  	}
    87  	return 0
    88  }
    89  
    90  func (x *Bucket) GetCount() uint64 {
    91  	if x != nil {
    92  		return x.Count
    93  	}
    94  	return 0
    95  }
    96  
    97  type Histogram struct {
    98  	state         protoimpl.MessageState
    99  	sizeCache     protoimpl.SizeCache
   100  	unknownFields protoimpl.UnknownFields
   101  
   102  	Buckets []*Bucket `protobuf:"bytes,1,rep,name=buckets,proto3" json:"buckets,omitempty"`
   103  }
   104  
   105  func (x *Histogram) Reset() {
   106  	*x = Histogram{}
   107  	if protoimpl.UnsafeEnabled {
   108  		mi := &file_grpc_core_stats_proto_msgTypes[1]
   109  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
   110  		ms.StoreMessageInfo(mi)
   111  	}
   112  }
   113  
   114  func (x *Histogram) String() string {
   115  	return protoimpl.X.MessageStringOf(x)
   116  }
   117  
   118  func (*Histogram) ProtoMessage() {}
   119  
   120  func (x *Histogram) ProtoReflect() protoreflect.Message {
   121  	mi := &file_grpc_core_stats_proto_msgTypes[1]
   122  	if protoimpl.UnsafeEnabled && x != nil {
   123  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
   124  		if ms.LoadMessageInfo() == nil {
   125  			ms.StoreMessageInfo(mi)
   126  		}
   127  		return ms
   128  	}
   129  	return mi.MessageOf(x)
   130  }
   131  
   132  // Deprecated: Use Histogram.ProtoReflect.Descriptor instead.
   133  func (*Histogram) Descriptor() ([]byte, []int) {
   134  	return file_grpc_core_stats_proto_rawDescGZIP(), []int{1}
   135  }
   136  
   137  func (x *Histogram) GetBuckets() []*Bucket {
   138  	if x != nil {
   139  		return x.Buckets
   140  	}
   141  	return nil
   142  }
   143  
   144  type Metric struct {
   145  	state         protoimpl.MessageState
   146  	sizeCache     protoimpl.SizeCache
   147  	unknownFields protoimpl.UnknownFields
   148  
   149  	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
   150  	// Types that are assignable to Value:
   151  	//	*Metric_Count
   152  	//	*Metric_Histogram
   153  	Value isMetric_Value `protobuf_oneof:"value"`
   154  }
   155  
   156  func (x *Metric) Reset() {
   157  	*x = Metric{}
   158  	if protoimpl.UnsafeEnabled {
   159  		mi := &file_grpc_core_stats_proto_msgTypes[2]
   160  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
   161  		ms.StoreMessageInfo(mi)
   162  	}
   163  }
   164  
   165  func (x *Metric) String() string {
   166  	return protoimpl.X.MessageStringOf(x)
   167  }
   168  
   169  func (*Metric) ProtoMessage() {}
   170  
   171  func (x *Metric) ProtoReflect() protoreflect.Message {
   172  	mi := &file_grpc_core_stats_proto_msgTypes[2]
   173  	if protoimpl.UnsafeEnabled && x != nil {
   174  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
   175  		if ms.LoadMessageInfo() == nil {
   176  			ms.StoreMessageInfo(mi)
   177  		}
   178  		return ms
   179  	}
   180  	return mi.MessageOf(x)
   181  }
   182  
   183  // Deprecated: Use Metric.ProtoReflect.Descriptor instead.
   184  func (*Metric) Descriptor() ([]byte, []int) {
   185  	return file_grpc_core_stats_proto_rawDescGZIP(), []int{2}
   186  }
   187  
   188  func (x *Metric) GetName() string {
   189  	if x != nil {
   190  		return x.Name
   191  	}
   192  	return ""
   193  }
   194  
   195  func (m *Metric) GetValue() isMetric_Value {
   196  	if m != nil {
   197  		return m.Value
   198  	}
   199  	return nil
   200  }
   201  
   202  func (x *Metric) GetCount() uint64 {
   203  	if x, ok := x.GetValue().(*Metric_Count); ok {
   204  		return x.Count
   205  	}
   206  	return 0
   207  }
   208  
   209  func (x *Metric) GetHistogram() *Histogram {
   210  	if x, ok := x.GetValue().(*Metric_Histogram); ok {
   211  		return x.Histogram
   212  	}
   213  	return nil
   214  }
   215  
   216  type isMetric_Value interface {
   217  	isMetric_Value()
   218  }
   219  
   220  type Metric_Count struct {
   221  	Count uint64 `protobuf:"varint,10,opt,name=count,proto3,oneof"`
   222  }
   223  
   224  type Metric_Histogram struct {
   225  	Histogram *Histogram `protobuf:"bytes,11,opt,name=histogram,proto3,oneof"`
   226  }
   227  
   228  func (*Metric_Count) isMetric_Value() {}
   229  
   230  func (*Metric_Histogram) isMetric_Value() {}
   231  
   232  type Stats struct {
   233  	state         protoimpl.MessageState
   234  	sizeCache     protoimpl.SizeCache
   235  	unknownFields protoimpl.UnknownFields
   236  
   237  	Metrics []*Metric `protobuf:"bytes,1,rep,name=metrics,proto3" json:"metrics,omitempty"`
   238  }
   239  
   240  func (x *Stats) Reset() {
   241  	*x = Stats{}
   242  	if protoimpl.UnsafeEnabled {
   243  		mi := &file_grpc_core_stats_proto_msgTypes[3]
   244  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
   245  		ms.StoreMessageInfo(mi)
   246  	}
   247  }
   248  
   249  func (x *Stats) String() string {
   250  	return protoimpl.X.MessageStringOf(x)
   251  }
   252  
   253  func (*Stats) ProtoMessage() {}
   254  
   255  func (x *Stats) ProtoReflect() protoreflect.Message {
   256  	mi := &file_grpc_core_stats_proto_msgTypes[3]
   257  	if protoimpl.UnsafeEnabled && x != nil {
   258  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
   259  		if ms.LoadMessageInfo() == nil {
   260  			ms.StoreMessageInfo(mi)
   261  		}
   262  		return ms
   263  	}
   264  	return mi.MessageOf(x)
   265  }
   266  
   267  // Deprecated: Use Stats.ProtoReflect.Descriptor instead.
   268  func (*Stats) Descriptor() ([]byte, []int) {
   269  	return file_grpc_core_stats_proto_rawDescGZIP(), []int{3}
   270  }
   271  
   272  func (x *Stats) GetMetrics() []*Metric {
   273  	if x != nil {
   274  		return x.Metrics
   275  	}
   276  	return nil
   277  }
   278  
   279  var File_grpc_core_stats_proto protoreflect.FileDescriptor
   280  
   281  var file_grpc_core_stats_proto_rawDesc = []byte{
   282  	0x0a, 0x15, 0x67, 0x72, 0x70, 0x63, 0x2f, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74,
   283  	0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x09, 0x67, 0x72, 0x70, 0x63, 0x2e, 0x63, 0x6f,
   284  	0x72, 0x65, 0x22, 0x34, 0x0a, 0x06, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x12, 0x14, 0x0a, 0x05,
   285  	0x73, 0x74, 0x61, 0x72, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, 0x52, 0x05, 0x73, 0x74, 0x61,
   286  	0x72, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28,
   287  	0x04, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x38, 0x0a, 0x09, 0x48, 0x69, 0x73, 0x74,
   288  	0x6f, 0x67, 0x72, 0x61, 0x6d, 0x12, 0x2b, 0x0a, 0x07, 0x62, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x73,
   289  	0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x67, 0x72, 0x70, 0x63, 0x2e, 0x63, 0x6f,
   290  	0x72, 0x65, 0x2e, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x52, 0x07, 0x62, 0x75, 0x63, 0x6b, 0x65,
   291  	0x74, 0x73, 0x22, 0x73, 0x0a, 0x06, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x12, 0x12, 0x0a, 0x04,
   292  	0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65,
   293  	0x12, 0x16, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x04, 0x48,
   294  	0x00, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x34, 0x0a, 0x09, 0x68, 0x69, 0x73, 0x74,
   295  	0x6f, 0x67, 0x72, 0x61, 0x6d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x72,
   296  	0x70, 0x63, 0x2e, 0x63, 0x6f, 0x72, 0x65, 0x2e, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x67, 0x72, 0x61,
   297  	0x6d, 0x48, 0x00, 0x52, 0x09, 0x68, 0x69, 0x73, 0x74, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x42, 0x07,
   298  	0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x34, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73,
   299  	0x12, 0x2b, 0x0a, 0x07, 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28,
   300  	0x0b, 0x32, 0x11, 0x2e, 0x67, 0x72, 0x70, 0x63, 0x2e, 0x63, 0x6f, 0x72, 0x65, 0x2e, 0x4d, 0x65,
   301  	0x74, 0x72, 0x69, 0x63, 0x52, 0x07, 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x62, 0x06, 0x70,
   302  	0x72, 0x6f, 0x74, 0x6f, 0x33,
   303  }
   304  
   305  var (
   306  	file_grpc_core_stats_proto_rawDescOnce sync.Once
   307  	file_grpc_core_stats_proto_rawDescData = file_grpc_core_stats_proto_rawDesc
   308  )
   309  
   310  func file_grpc_core_stats_proto_rawDescGZIP() []byte {
   311  	file_grpc_core_stats_proto_rawDescOnce.Do(func() {
   312  		file_grpc_core_stats_proto_rawDescData = protoimpl.X.CompressGZIP(file_grpc_core_stats_proto_rawDescData)
   313  	})
   314  	return file_grpc_core_stats_proto_rawDescData
   315  }
   316  
   317  var file_grpc_core_stats_proto_msgTypes = make([]protoimpl.MessageInfo, 4)
   318  var file_grpc_core_stats_proto_goTypes = []interface{}{
   319  	(*Bucket)(nil),    // 0: grpc.core.Bucket
   320  	(*Histogram)(nil), // 1: grpc.core.Histogram
   321  	(*Metric)(nil),    // 2: grpc.core.Metric
   322  	(*Stats)(nil),     // 3: grpc.core.Stats
   323  }
   324  var file_grpc_core_stats_proto_depIdxs = []int32{
   325  	0, // 0: grpc.core.Histogram.buckets:type_name -> grpc.core.Bucket
   326  	1, // 1: grpc.core.Metric.histogram:type_name -> grpc.core.Histogram
   327  	2, // 2: grpc.core.Stats.metrics:type_name -> grpc.core.Metric
   328  	3, // [3:3] is the sub-list for method output_type
   329  	3, // [3:3] is the sub-list for method input_type
   330  	3, // [3:3] is the sub-list for extension type_name
   331  	3, // [3:3] is the sub-list for extension extendee
   332  	0, // [0:3] is the sub-list for field type_name
   333  }
   334  
   335  func init() { file_grpc_core_stats_proto_init() }
   336  func file_grpc_core_stats_proto_init() {
   337  	if File_grpc_core_stats_proto != nil {
   338  		return
   339  	}
   340  	if !protoimpl.UnsafeEnabled {
   341  		file_grpc_core_stats_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
   342  			switch v := v.(*Bucket); i {
   343  			case 0:
   344  				return &v.state
   345  			case 1:
   346  				return &v.sizeCache
   347  			case 2:
   348  				return &v.unknownFields
   349  			default:
   350  				return nil
   351  			}
   352  		}
   353  		file_grpc_core_stats_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
   354  			switch v := v.(*Histogram); i {
   355  			case 0:
   356  				return &v.state
   357  			case 1:
   358  				return &v.sizeCache
   359  			case 2:
   360  				return &v.unknownFields
   361  			default:
   362  				return nil
   363  			}
   364  		}
   365  		file_grpc_core_stats_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
   366  			switch v := v.(*Metric); i {
   367  			case 0:
   368  				return &v.state
   369  			case 1:
   370  				return &v.sizeCache
   371  			case 2:
   372  				return &v.unknownFields
   373  			default:
   374  				return nil
   375  			}
   376  		}
   377  		file_grpc_core_stats_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
   378  			switch v := v.(*Stats); i {
   379  			case 0:
   380  				return &v.state
   381  			case 1:
   382  				return &v.sizeCache
   383  			case 2:
   384  				return &v.unknownFields
   385  			default:
   386  				return nil
   387  			}
   388  		}
   389  	}
   390  	file_grpc_core_stats_proto_msgTypes[2].OneofWrappers = []interface{}{
   391  		(*Metric_Count)(nil),
   392  		(*Metric_Histogram)(nil),
   393  	}
   394  	type x struct{}
   395  	out := protoimpl.TypeBuilder{
   396  		File: protoimpl.DescBuilder{
   397  			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
   398  			RawDescriptor: file_grpc_core_stats_proto_rawDesc,
   399  			NumEnums:      0,
   400  			NumMessages:   4,
   401  			NumExtensions: 0,
   402  			NumServices:   0,
   403  		},
   404  		GoTypes:           file_grpc_core_stats_proto_goTypes,
   405  		DependencyIndexes: file_grpc_core_stats_proto_depIdxs,
   406  		MessageInfos:      file_grpc_core_stats_proto_msgTypes,
   407  	}.Build()
   408  	File_grpc_core_stats_proto = out.File
   409  	file_grpc_core_stats_proto_rawDesc = nil
   410  	file_grpc_core_stats_proto_goTypes = nil
   411  	file_grpc_core_stats_proto_depIdxs = nil
   412  }