address.pb.go 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // versions:
  3. // protoc-gen-go v1.26.0
  4. // protoc v3.15.6
  5. // source: common/net/address.proto
  6. package net
  7. import (
  8. protoreflect "google.golang.org/protobuf/reflect/protoreflect"
  9. protoimpl "google.golang.org/protobuf/runtime/protoimpl"
  10. reflect "reflect"
  11. sync "sync"
  12. )
  13. const (
  14. // Verify that this generated code is sufficiently up-to-date.
  15. _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
  16. // Verify that runtime/protoimpl is sufficiently up-to-date.
  17. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
  18. )
  19. // Address of a network host. It may be either an IP address or a domain
  20. // address.
  21. type IPOrDomain struct {
  22. state protoimpl.MessageState
  23. sizeCache protoimpl.SizeCache
  24. unknownFields protoimpl.UnknownFields
  25. // Types that are assignable to Address:
  26. // *IPOrDomain_Ip
  27. // *IPOrDomain_Domain
  28. Address isIPOrDomain_Address `protobuf_oneof:"address"`
  29. }
  30. func (x *IPOrDomain) Reset() {
  31. *x = IPOrDomain{}
  32. if protoimpl.UnsafeEnabled {
  33. mi := &file_common_net_address_proto_msgTypes[0]
  34. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  35. ms.StoreMessageInfo(mi)
  36. }
  37. }
  38. func (x *IPOrDomain) String() string {
  39. return protoimpl.X.MessageStringOf(x)
  40. }
  41. func (*IPOrDomain) ProtoMessage() {}
  42. func (x *IPOrDomain) ProtoReflect() protoreflect.Message {
  43. mi := &file_common_net_address_proto_msgTypes[0]
  44. if protoimpl.UnsafeEnabled && x != nil {
  45. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  46. if ms.LoadMessageInfo() == nil {
  47. ms.StoreMessageInfo(mi)
  48. }
  49. return ms
  50. }
  51. return mi.MessageOf(x)
  52. }
  53. // Deprecated: Use IPOrDomain.ProtoReflect.Descriptor instead.
  54. func (*IPOrDomain) Descriptor() ([]byte, []int) {
  55. return file_common_net_address_proto_rawDescGZIP(), []int{0}
  56. }
  57. func (m *IPOrDomain) GetAddress() isIPOrDomain_Address {
  58. if m != nil {
  59. return m.Address
  60. }
  61. return nil
  62. }
  63. func (x *IPOrDomain) GetIp() []byte {
  64. if x, ok := x.GetAddress().(*IPOrDomain_Ip); ok {
  65. return x.Ip
  66. }
  67. return nil
  68. }
  69. func (x *IPOrDomain) GetDomain() string {
  70. if x, ok := x.GetAddress().(*IPOrDomain_Domain); ok {
  71. return x.Domain
  72. }
  73. return ""
  74. }
  75. type isIPOrDomain_Address interface {
  76. isIPOrDomain_Address()
  77. }
  78. type IPOrDomain_Ip struct {
  79. // IP address. Must by either 4 or 16 bytes.
  80. Ip []byte `protobuf:"bytes,1,opt,name=ip,proto3,oneof"`
  81. }
  82. type IPOrDomain_Domain struct {
  83. // Domain address.
  84. Domain string `protobuf:"bytes,2,opt,name=domain,proto3,oneof"`
  85. }
  86. func (*IPOrDomain_Ip) isIPOrDomain_Address() {}
  87. func (*IPOrDomain_Domain) isIPOrDomain_Address() {}
  88. var File_common_net_address_proto protoreflect.FileDescriptor
  89. var file_common_net_address_proto_rawDesc = []byte{
  90. 0x0a, 0x18, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x6e, 0x65, 0x74, 0x2f, 0x61, 0x64, 0x64,
  91. 0x72, 0x65, 0x73, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x76, 0x32, 0x72, 0x61,
  92. 0x79, 0x2e, 0x63, 0x6f, 0x72, 0x65, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x6e, 0x65,
  93. 0x74, 0x22, 0x43, 0x0a, 0x0a, 0x49, 0x50, 0x4f, 0x72, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x12,
  94. 0x10, 0x0a, 0x02, 0x69, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x48, 0x00, 0x52, 0x02, 0x69,
  95. 0x70, 0x12, 0x18, 0x0a, 0x06, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28,
  96. 0x09, 0x48, 0x00, 0x52, 0x06, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x42, 0x09, 0x0a, 0x07, 0x61,
  97. 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x42, 0x60, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x76, 0x32,
  98. 0x72, 0x61, 0x79, 0x2e, 0x63, 0x6f, 0x72, 0x65, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e,
  99. 0x6e, 0x65, 0x74, 0x50, 0x01, 0x5a, 0x29, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f,
  100. 0x6d, 0x2f, 0x76, 0x32, 0x66, 0x6c, 0x79, 0x2f, 0x76, 0x32, 0x72, 0x61, 0x79, 0x2d, 0x63, 0x6f,
  101. 0x72, 0x65, 0x2f, 0x76, 0x34, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x6e, 0x65, 0x74,
  102. 0xaa, 0x02, 0x15, 0x56, 0x32, 0x52, 0x61, 0x79, 0x2e, 0x43, 0x6f, 0x72, 0x65, 0x2e, 0x43, 0x6f,
  103. 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x4e, 0x65, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
  104. }
  105. var (
  106. file_common_net_address_proto_rawDescOnce sync.Once
  107. file_common_net_address_proto_rawDescData = file_common_net_address_proto_rawDesc
  108. )
  109. func file_common_net_address_proto_rawDescGZIP() []byte {
  110. file_common_net_address_proto_rawDescOnce.Do(func() {
  111. file_common_net_address_proto_rawDescData = protoimpl.X.CompressGZIP(file_common_net_address_proto_rawDescData)
  112. })
  113. return file_common_net_address_proto_rawDescData
  114. }
  115. var file_common_net_address_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
  116. var file_common_net_address_proto_goTypes = []interface{}{
  117. (*IPOrDomain)(nil), // 0: v2ray.core.common.net.IPOrDomain
  118. }
  119. var file_common_net_address_proto_depIdxs = []int32{
  120. 0, // [0:0] is the sub-list for method output_type
  121. 0, // [0:0] is the sub-list for method input_type
  122. 0, // [0:0] is the sub-list for extension type_name
  123. 0, // [0:0] is the sub-list for extension extendee
  124. 0, // [0:0] is the sub-list for field type_name
  125. }
  126. func init() { file_common_net_address_proto_init() }
  127. func file_common_net_address_proto_init() {
  128. if File_common_net_address_proto != nil {
  129. return
  130. }
  131. if !protoimpl.UnsafeEnabled {
  132. file_common_net_address_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
  133. switch v := v.(*IPOrDomain); i {
  134. case 0:
  135. return &v.state
  136. case 1:
  137. return &v.sizeCache
  138. case 2:
  139. return &v.unknownFields
  140. default:
  141. return nil
  142. }
  143. }
  144. }
  145. file_common_net_address_proto_msgTypes[0].OneofWrappers = []interface{}{
  146. (*IPOrDomain_Ip)(nil),
  147. (*IPOrDomain_Domain)(nil),
  148. }
  149. type x struct{}
  150. out := protoimpl.TypeBuilder{
  151. File: protoimpl.DescBuilder{
  152. GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
  153. RawDescriptor: file_common_net_address_proto_rawDesc,
  154. NumEnums: 0,
  155. NumMessages: 1,
  156. NumExtensions: 0,
  157. NumServices: 0,
  158. },
  159. GoTypes: file_common_net_address_proto_goTypes,
  160. DependencyIndexes: file_common_net_address_proto_depIdxs,
  161. MessageInfos: file_common_net_address_proto_msgTypes,
  162. }.Build()
  163. File_common_net_address_proto = out.File
  164. file_common_net_address_proto_rawDesc = nil
  165. file_common_net_address_proto_goTypes = nil
  166. file_common_net_address_proto_depIdxs = nil
  167. }