github.com/zhuohuang-hust/src-cbuild@v0.0.0-20230105071821-c7aab3e7c840/mergeCode/libnetwork/drivers/overlay/overlay.pb.go (about)

     1  // Code generated by protoc-gen-gogo.
     2  // source: overlay.proto
     3  // DO NOT EDIT!
     4  
     5  /*
     6  	Package overlay is a generated protocol buffer package.
     7  
     8  	It is generated from these files:
     9  		overlay.proto
    10  
    11  	It has these top-level messages:
    12  		PeerRecord
    13  */
    14  package overlay
    15  
    16  import proto "github.com/gogo/protobuf/proto"
    17  import fmt "fmt"
    18  import math "math"
    19  import _ "github.com/gogo/protobuf/gogoproto"
    20  
    21  import strings "strings"
    22  import github_com_gogo_protobuf_proto "github.com/gogo/protobuf/proto"
    23  import sort "sort"
    24  import strconv "strconv"
    25  import reflect "reflect"
    26  
    27  import io "io"
    28  
    29  // Reference imports to suppress errors if they are not otherwise used.
    30  var _ = proto.Marshal
    31  var _ = fmt.Errorf
    32  var _ = math.Inf
    33  
    34  // This is a compile-time assertion to ensure that this generated file
    35  // is compatible with the proto package it is being compiled against.
    36  const _ = proto.GoGoProtoPackageIsVersion1
    37  
    38  // PeerRecord defines the information corresponding to a peer
    39  // container in the overlay network.
    40  type PeerRecord struct {
    41  	// Endpoint IP is the IP of the container attachment on the
    42  	// given overlay network.
    43  	EndpointIP string `protobuf:"bytes,1,opt,name=endpoint_ip,json=endpointIp,proto3" json:"endpoint_ip,omitempty"`
    44  	// Endpoint MAC is the mac address of the container attachment
    45  	// on the given overlay network.
    46  	EndpointMAC string `protobuf:"bytes,2,opt,name=endpoint_mac,json=endpointMac,proto3" json:"endpoint_mac,omitempty"`
    47  	// Tunnel Endpoint IP defines the host IP for the host in
    48  	// which this container is running and can be reached by
    49  	// building a tunnel to that host IP.
    50  	TunnelEndpointIP string `protobuf:"bytes,3,opt,name=tunnel_endpoint_ip,json=tunnelEndpointIp,proto3" json:"tunnel_endpoint_ip,omitempty"`
    51  }
    52  
    53  func (m *PeerRecord) Reset()                    { *m = PeerRecord{} }
    54  func (*PeerRecord) ProtoMessage()               {}
    55  func (*PeerRecord) Descriptor() ([]byte, []int) { return fileDescriptorOverlay, []int{0} }
    56  
    57  func init() {
    58  	proto.RegisterType((*PeerRecord)(nil), "overlay.PeerRecord")
    59  }
    60  func (this *PeerRecord) GoString() string {
    61  	if this == nil {
    62  		return "nil"
    63  	}
    64  	s := make([]string, 0, 7)
    65  	s = append(s, "&overlay.PeerRecord{")
    66  	s = append(s, "EndpointIP: "+fmt.Sprintf("%#v", this.EndpointIP)+",\n")
    67  	s = append(s, "EndpointMAC: "+fmt.Sprintf("%#v", this.EndpointMAC)+",\n")
    68  	s = append(s, "TunnelEndpointIP: "+fmt.Sprintf("%#v", this.TunnelEndpointIP)+",\n")
    69  	s = append(s, "}")
    70  	return strings.Join(s, "")
    71  }
    72  func valueToGoStringOverlay(v interface{}, typ string) string {
    73  	rv := reflect.ValueOf(v)
    74  	if rv.IsNil() {
    75  		return "nil"
    76  	}
    77  	pv := reflect.Indirect(rv).Interface()
    78  	return fmt.Sprintf("func(v %v) *%v { return &v } ( %#v )", typ, typ, pv)
    79  }
    80  func extensionToGoStringOverlay(e map[int32]github_com_gogo_protobuf_proto.Extension) string {
    81  	if e == nil {
    82  		return "nil"
    83  	}
    84  	s := "map[int32]proto.Extension{"
    85  	keys := make([]int, 0, len(e))
    86  	for k := range e {
    87  		keys = append(keys, int(k))
    88  	}
    89  	sort.Ints(keys)
    90  	ss := []string{}
    91  	for _, k := range keys {
    92  		ss = append(ss, strconv.Itoa(k)+": "+e[int32(k)].GoString())
    93  	}
    94  	s += strings.Join(ss, ",") + "}"
    95  	return s
    96  }
    97  func (m *PeerRecord) Marshal() (data []byte, err error) {
    98  	size := m.Size()
    99  	data = make([]byte, size)
   100  	n, err := m.MarshalTo(data)
   101  	if err != nil {
   102  		return nil, err
   103  	}
   104  	return data[:n], nil
   105  }
   106  
   107  func (m *PeerRecord) MarshalTo(data []byte) (int, error) {
   108  	var i int
   109  	_ = i
   110  	var l int
   111  	_ = l
   112  	if len(m.EndpointIP) > 0 {
   113  		data[i] = 0xa
   114  		i++
   115  		i = encodeVarintOverlay(data, i, uint64(len(m.EndpointIP)))
   116  		i += copy(data[i:], m.EndpointIP)
   117  	}
   118  	if len(m.EndpointMAC) > 0 {
   119  		data[i] = 0x12
   120  		i++
   121  		i = encodeVarintOverlay(data, i, uint64(len(m.EndpointMAC)))
   122  		i += copy(data[i:], m.EndpointMAC)
   123  	}
   124  	if len(m.TunnelEndpointIP) > 0 {
   125  		data[i] = 0x1a
   126  		i++
   127  		i = encodeVarintOverlay(data, i, uint64(len(m.TunnelEndpointIP)))
   128  		i += copy(data[i:], m.TunnelEndpointIP)
   129  	}
   130  	return i, nil
   131  }
   132  
   133  func encodeFixed64Overlay(data []byte, offset int, v uint64) int {
   134  	data[offset] = uint8(v)
   135  	data[offset+1] = uint8(v >> 8)
   136  	data[offset+2] = uint8(v >> 16)
   137  	data[offset+3] = uint8(v >> 24)
   138  	data[offset+4] = uint8(v >> 32)
   139  	data[offset+5] = uint8(v >> 40)
   140  	data[offset+6] = uint8(v >> 48)
   141  	data[offset+7] = uint8(v >> 56)
   142  	return offset + 8
   143  }
   144  func encodeFixed32Overlay(data []byte, offset int, v uint32) int {
   145  	data[offset] = uint8(v)
   146  	data[offset+1] = uint8(v >> 8)
   147  	data[offset+2] = uint8(v >> 16)
   148  	data[offset+3] = uint8(v >> 24)
   149  	return offset + 4
   150  }
   151  func encodeVarintOverlay(data []byte, offset int, v uint64) int {
   152  	for v >= 1<<7 {
   153  		data[offset] = uint8(v&0x7f | 0x80)
   154  		v >>= 7
   155  		offset++
   156  	}
   157  	data[offset] = uint8(v)
   158  	return offset + 1
   159  }
   160  func (m *PeerRecord) Size() (n int) {
   161  	var l int
   162  	_ = l
   163  	l = len(m.EndpointIP)
   164  	if l > 0 {
   165  		n += 1 + l + sovOverlay(uint64(l))
   166  	}
   167  	l = len(m.EndpointMAC)
   168  	if l > 0 {
   169  		n += 1 + l + sovOverlay(uint64(l))
   170  	}
   171  	l = len(m.TunnelEndpointIP)
   172  	if l > 0 {
   173  		n += 1 + l + sovOverlay(uint64(l))
   174  	}
   175  	return n
   176  }
   177  
   178  func sovOverlay(x uint64) (n int) {
   179  	for {
   180  		n++
   181  		x >>= 7
   182  		if x == 0 {
   183  			break
   184  		}
   185  	}
   186  	return n
   187  }
   188  func sozOverlay(x uint64) (n int) {
   189  	return sovOverlay(uint64((x << 1) ^ uint64((int64(x) >> 63))))
   190  }
   191  func (this *PeerRecord) String() string {
   192  	if this == nil {
   193  		return "nil"
   194  	}
   195  	s := strings.Join([]string{`&PeerRecord{`,
   196  		`EndpointIP:` + fmt.Sprintf("%v", this.EndpointIP) + `,`,
   197  		`EndpointMAC:` + fmt.Sprintf("%v", this.EndpointMAC) + `,`,
   198  		`TunnelEndpointIP:` + fmt.Sprintf("%v", this.TunnelEndpointIP) + `,`,
   199  		`}`,
   200  	}, "")
   201  	return s
   202  }
   203  func valueToStringOverlay(v interface{}) string {
   204  	rv := reflect.ValueOf(v)
   205  	if rv.IsNil() {
   206  		return "nil"
   207  	}
   208  	pv := reflect.Indirect(rv).Interface()
   209  	return fmt.Sprintf("*%v", pv)
   210  }
   211  func (m *PeerRecord) Unmarshal(data []byte) error {
   212  	l := len(data)
   213  	iNdEx := 0
   214  	for iNdEx < l {
   215  		preIndex := iNdEx
   216  		var wire uint64
   217  		for shift := uint(0); ; shift += 7 {
   218  			if shift >= 64 {
   219  				return ErrIntOverflowOverlay
   220  			}
   221  			if iNdEx >= l {
   222  				return io.ErrUnexpectedEOF
   223  			}
   224  			b := data[iNdEx]
   225  			iNdEx++
   226  			wire |= (uint64(b) & 0x7F) << shift
   227  			if b < 0x80 {
   228  				break
   229  			}
   230  		}
   231  		fieldNum := int32(wire >> 3)
   232  		wireType := int(wire & 0x7)
   233  		if wireType == 4 {
   234  			return fmt.Errorf("proto: PeerRecord: wiretype end group for non-group")
   235  		}
   236  		if fieldNum <= 0 {
   237  			return fmt.Errorf("proto: PeerRecord: illegal tag %d (wire type %d)", fieldNum, wire)
   238  		}
   239  		switch fieldNum {
   240  		case 1:
   241  			if wireType != 2 {
   242  				return fmt.Errorf("proto: wrong wireType = %d for field EndpointIP", wireType)
   243  			}
   244  			var stringLen uint64
   245  			for shift := uint(0); ; shift += 7 {
   246  				if shift >= 64 {
   247  					return ErrIntOverflowOverlay
   248  				}
   249  				if iNdEx >= l {
   250  					return io.ErrUnexpectedEOF
   251  				}
   252  				b := data[iNdEx]
   253  				iNdEx++
   254  				stringLen |= (uint64(b) & 0x7F) << shift
   255  				if b < 0x80 {
   256  					break
   257  				}
   258  			}
   259  			intStringLen := int(stringLen)
   260  			if intStringLen < 0 {
   261  				return ErrInvalidLengthOverlay
   262  			}
   263  			postIndex := iNdEx + intStringLen
   264  			if postIndex > l {
   265  				return io.ErrUnexpectedEOF
   266  			}
   267  			m.EndpointIP = string(data[iNdEx:postIndex])
   268  			iNdEx = postIndex
   269  		case 2:
   270  			if wireType != 2 {
   271  				return fmt.Errorf("proto: wrong wireType = %d for field EndpointMAC", wireType)
   272  			}
   273  			var stringLen uint64
   274  			for shift := uint(0); ; shift += 7 {
   275  				if shift >= 64 {
   276  					return ErrIntOverflowOverlay
   277  				}
   278  				if iNdEx >= l {
   279  					return io.ErrUnexpectedEOF
   280  				}
   281  				b := data[iNdEx]
   282  				iNdEx++
   283  				stringLen |= (uint64(b) & 0x7F) << shift
   284  				if b < 0x80 {
   285  					break
   286  				}
   287  			}
   288  			intStringLen := int(stringLen)
   289  			if intStringLen < 0 {
   290  				return ErrInvalidLengthOverlay
   291  			}
   292  			postIndex := iNdEx + intStringLen
   293  			if postIndex > l {
   294  				return io.ErrUnexpectedEOF
   295  			}
   296  			m.EndpointMAC = string(data[iNdEx:postIndex])
   297  			iNdEx = postIndex
   298  		case 3:
   299  			if wireType != 2 {
   300  				return fmt.Errorf("proto: wrong wireType = %d for field TunnelEndpointIP", wireType)
   301  			}
   302  			var stringLen uint64
   303  			for shift := uint(0); ; shift += 7 {
   304  				if shift >= 64 {
   305  					return ErrIntOverflowOverlay
   306  				}
   307  				if iNdEx >= l {
   308  					return io.ErrUnexpectedEOF
   309  				}
   310  				b := data[iNdEx]
   311  				iNdEx++
   312  				stringLen |= (uint64(b) & 0x7F) << shift
   313  				if b < 0x80 {
   314  					break
   315  				}
   316  			}
   317  			intStringLen := int(stringLen)
   318  			if intStringLen < 0 {
   319  				return ErrInvalidLengthOverlay
   320  			}
   321  			postIndex := iNdEx + intStringLen
   322  			if postIndex > l {
   323  				return io.ErrUnexpectedEOF
   324  			}
   325  			m.TunnelEndpointIP = string(data[iNdEx:postIndex])
   326  			iNdEx = postIndex
   327  		default:
   328  			iNdEx = preIndex
   329  			skippy, err := skipOverlay(data[iNdEx:])
   330  			if err != nil {
   331  				return err
   332  			}
   333  			if skippy < 0 {
   334  				return ErrInvalidLengthOverlay
   335  			}
   336  			if (iNdEx + skippy) > l {
   337  				return io.ErrUnexpectedEOF
   338  			}
   339  			iNdEx += skippy
   340  		}
   341  	}
   342  
   343  	if iNdEx > l {
   344  		return io.ErrUnexpectedEOF
   345  	}
   346  	return nil
   347  }
   348  func skipOverlay(data []byte) (n int, err error) {
   349  	l := len(data)
   350  	iNdEx := 0
   351  	for iNdEx < l {
   352  		var wire uint64
   353  		for shift := uint(0); ; shift += 7 {
   354  			if shift >= 64 {
   355  				return 0, ErrIntOverflowOverlay
   356  			}
   357  			if iNdEx >= l {
   358  				return 0, io.ErrUnexpectedEOF
   359  			}
   360  			b := data[iNdEx]
   361  			iNdEx++
   362  			wire |= (uint64(b) & 0x7F) << shift
   363  			if b < 0x80 {
   364  				break
   365  			}
   366  		}
   367  		wireType := int(wire & 0x7)
   368  		switch wireType {
   369  		case 0:
   370  			for shift := uint(0); ; shift += 7 {
   371  				if shift >= 64 {
   372  					return 0, ErrIntOverflowOverlay
   373  				}
   374  				if iNdEx >= l {
   375  					return 0, io.ErrUnexpectedEOF
   376  				}
   377  				iNdEx++
   378  				if data[iNdEx-1] < 0x80 {
   379  					break
   380  				}
   381  			}
   382  			return iNdEx, nil
   383  		case 1:
   384  			iNdEx += 8
   385  			return iNdEx, nil
   386  		case 2:
   387  			var length int
   388  			for shift := uint(0); ; shift += 7 {
   389  				if shift >= 64 {
   390  					return 0, ErrIntOverflowOverlay
   391  				}
   392  				if iNdEx >= l {
   393  					return 0, io.ErrUnexpectedEOF
   394  				}
   395  				b := data[iNdEx]
   396  				iNdEx++
   397  				length |= (int(b) & 0x7F) << shift
   398  				if b < 0x80 {
   399  					break
   400  				}
   401  			}
   402  			iNdEx += length
   403  			if length < 0 {
   404  				return 0, ErrInvalidLengthOverlay
   405  			}
   406  			return iNdEx, nil
   407  		case 3:
   408  			for {
   409  				var innerWire uint64
   410  				var start int = iNdEx
   411  				for shift := uint(0); ; shift += 7 {
   412  					if shift >= 64 {
   413  						return 0, ErrIntOverflowOverlay
   414  					}
   415  					if iNdEx >= l {
   416  						return 0, io.ErrUnexpectedEOF
   417  					}
   418  					b := data[iNdEx]
   419  					iNdEx++
   420  					innerWire |= (uint64(b) & 0x7F) << shift
   421  					if b < 0x80 {
   422  						break
   423  					}
   424  				}
   425  				innerWireType := int(innerWire & 0x7)
   426  				if innerWireType == 4 {
   427  					break
   428  				}
   429  				next, err := skipOverlay(data[start:])
   430  				if err != nil {
   431  					return 0, err
   432  				}
   433  				iNdEx = start + next
   434  			}
   435  			return iNdEx, nil
   436  		case 4:
   437  			return iNdEx, nil
   438  		case 5:
   439  			iNdEx += 4
   440  			return iNdEx, nil
   441  		default:
   442  			return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
   443  		}
   444  	}
   445  	panic("unreachable")
   446  }
   447  
   448  var (
   449  	ErrInvalidLengthOverlay = fmt.Errorf("proto: negative length found during unmarshaling")
   450  	ErrIntOverflowOverlay   = fmt.Errorf("proto: integer overflow")
   451  )
   452  
   453  var fileDescriptorOverlay = []byte{
   454  	// 195 bytes of a gzipped FileDescriptorProto
   455  	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xe2, 0xe2, 0xcd, 0x2f, 0x4b, 0x2d,
   456  	0xca, 0x49, 0xac, 0xd4, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0x87, 0x72, 0xa5, 0x44, 0xd2,
   457  	0xf3, 0xd3, 0xf3, 0xc1, 0x62, 0xfa, 0x20, 0x16, 0x44, 0x5a, 0x69, 0x2b, 0x23, 0x17, 0x57, 0x40,
   458  	0x6a, 0x6a, 0x51, 0x50, 0x6a, 0x72, 0x7e, 0x51, 0x8a, 0x90, 0x3e, 0x17, 0x77, 0x6a, 0x5e, 0x4a,
   459  	0x41, 0x7e, 0x66, 0x5e, 0x49, 0x7c, 0x66, 0x81, 0x04, 0xa3, 0x02, 0xa3, 0x06, 0xa7, 0x13, 0xdf,
   460  	0xa3, 0x7b, 0xf2, 0x5c, 0xae, 0x50, 0x61, 0xcf, 0x80, 0x20, 0x2e, 0x98, 0x12, 0xcf, 0x02, 0x21,
   461  	0x23, 0x2e, 0x1e, 0xb8, 0x86, 0xdc, 0xc4, 0x64, 0x09, 0x26, 0xb0, 0x0e, 0x7e, 0xa0, 0x0e, 0x6e,
   462  	0x98, 0x0e, 0x5f, 0x47, 0xe7, 0x20, 0xb8, 0xa9, 0xbe, 0x89, 0xc9, 0x42, 0x4e, 0x5c, 0x42, 0x25,
   463  	0xa5, 0x79, 0x79, 0xa9, 0x39, 0xf1, 0xc8, 0x76, 0x31, 0x83, 0x75, 0x8a, 0x00, 0x75, 0x0a, 0x84,
   464  	0x80, 0x65, 0x91, 0x6c, 0x14, 0x28, 0x41, 0x15, 0x29, 0x70, 0x92, 0xb8, 0xf1, 0x50, 0x8e, 0xe1,
   465  	0xc3, 0x43, 0x39, 0xc6, 0x86, 0x47, 0x72, 0x8c, 0x27, 0x80, 0xf8, 0x02, 0x10, 0x3f, 0x00, 0xe2,
   466  	0x24, 0x36, 0xb0, 0xc7, 0x8c, 0x01, 0x01, 0x00, 0x00, 0xff, 0xff, 0xbf, 0xd7, 0x7d, 0x7d, 0x08,
   467  	0x01, 0x00, 0x00,
   468  }