vendor: github.com/gogo/googleapis v1.3.2

full diff: d31c731455...v1.3.2

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn 2020-04-16 17:41:22 +02:00
parent cdde30e030
commit d7c34b6a0f
No known key found for this signature in database
GPG Key ID: 76698F39D527CE8C
5 changed files with 430 additions and 356 deletions

View File

@ -23,7 +23,7 @@ github.com/docker/go-units 519db1ee28dcc9fd2474ae59fca2
github.com/docker/swarmkit 49e35619b18200845c9365c1e953440c28868002
github.com/evanphx/json-patch 72bf35d0ff611848c1dc9df0f976c81192392fa5 # v4.1.0
github.com/gofrs/flock 392e7fae8f1b0bdbd67dad7237d23f618feb6dbb # v0.7.1
github.com/gogo/googleapis d31c731455cb061f42baff3bda55bad0118b126b # v1.2.0
github.com/gogo/googleapis 01e0f9cca9b92166042241267ee2a5cdf5cff46c # v1.3.2
github.com/gogo/protobuf ba06b47c162d49f2af050fb4c75bcbc86a159d5c # v1.2.1
github.com/golang/glog 23def4e6c14b4da8ac2ed8007337bc5eb5007998
github.com/golang/protobuf aa810b61a9c79d51363740d207bb46cf8e620ed5 # v1.2.0

View File

@ -2,4 +2,4 @@ module github.com/gogo/googleapis
go 1.12
require github.com/gogo/protobuf v1.2.1
require github.com/gogo/protobuf v1.3.1

View File

@ -19,7 +19,7 @@ var _ = math.Inf
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package
// The canonical error codes for Google APIs.
//

File diff suppressed because it is too large Load Diff

View File

@ -10,6 +10,7 @@ import (
types "github.com/gogo/protobuf/types"
io "io"
math "math"
math_bits "math/bits"
reflect "reflect"
strings "strings"
)
@ -23,7 +24,7 @@ var _ = math.Inf
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package
// The `Status` type defines a logical error model that is suitable for
// different programming environments, including REST APIs and RPC APIs. It is
@ -108,7 +109,7 @@ func (m *Status) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Status.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalTo(b)
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
@ -295,7 +296,7 @@ func valueToGoStringStatus(v interface{}, typ string) string {
func (m *Status) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalTo(dAtA)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
@ -303,47 +304,58 @@ func (m *Status) Marshal() (dAtA []byte, err error) {
}
func (m *Status) MarshalTo(dAtA []byte) (int, error) {
var i int
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *Status) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
if m.Code != 0 {
dAtA[i] = 0x8
i++
i = encodeVarintStatus(dAtA, i, uint64(m.Code))
}
if len(m.Message) > 0 {
dAtA[i] = 0x12
i++
i = encodeVarintStatus(dAtA, i, uint64(len(m.Message)))
i += copy(dAtA[i:], m.Message)
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
if len(m.Details) > 0 {
for _, msg := range m.Details {
dAtA[i] = 0x1a
i++
i = encodeVarintStatus(dAtA, i, uint64(msg.Size()))
n, err := msg.MarshalTo(dAtA[i:])
if err != nil {
return 0, err
for iNdEx := len(m.Details) - 1; iNdEx >= 0; iNdEx-- {
{
size, err := m.Details[iNdEx].MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintStatus(dAtA, i, uint64(size))
}
i += n
i--
dAtA[i] = 0x1a
}
}
if m.XXX_unrecognized != nil {
i += copy(dAtA[i:], m.XXX_unrecognized)
if len(m.Message) > 0 {
i -= len(m.Message)
copy(dAtA[i:], m.Message)
i = encodeVarintStatus(dAtA, i, uint64(len(m.Message)))
i--
dAtA[i] = 0x12
}
return i, nil
if m.Code != 0 {
i = encodeVarintStatus(dAtA, i, uint64(m.Code))
i--
dAtA[i] = 0x8
}
return len(dAtA) - i, nil
}
func encodeVarintStatus(dAtA []byte, offset int, v uint64) int {
offset -= sovStatus(v)
base := offset
for v >= 1<<7 {
dAtA[offset] = uint8(v&0x7f | 0x80)
v >>= 7
offset++
}
dAtA[offset] = uint8(v)
return offset + 1
return base
}
func NewPopulatedStatus(r randyStatus, easy bool) *Status {
this := &Status{}
@ -352,7 +364,7 @@ func NewPopulatedStatus(r randyStatus, easy bool) *Status {
this.Code *= -1
}
this.Message = string(randStringStatus(r))
if r.Intn(10) != 0 {
if r.Intn(5) != 0 {
v1 := r.Intn(5)
this.Details = make([]*types.Any, v1)
for i := 0; i < v1; i++ {
@ -463,14 +475,7 @@ func (m *Status) Size() (n int) {
}
func sovStatus(x uint64) (n int) {
for {
n++
x >>= 7
if x == 0 {
break
}
}
return n
return (math_bits.Len64(x|1) + 6) / 7
}
func sozStatus(x uint64) (n int) {
return sovStatus(uint64((x << 1) ^ uint64((int64(x) >> 63))))
@ -479,10 +484,15 @@ func (this *Status) String() string {
if this == nil {
return "nil"
}
repeatedStringForDetails := "[]*Any{"
for _, f := range this.Details {
repeatedStringForDetails += strings.Replace(fmt.Sprintf("%v", f), "Any", "types.Any", 1) + ","
}
repeatedStringForDetails += "}"
s := strings.Join([]string{`&Status{`,
`Code:` + fmt.Sprintf("%v", this.Code) + `,`,
`Message:` + fmt.Sprintf("%v", this.Message) + `,`,
`Details:` + strings.Replace(fmt.Sprintf("%v", this.Details), "Any", "types.Any", 1) + `,`,
`Details:` + repeatedStringForDetails + `,`,
`XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
`}`,
}, "")
@ -638,6 +648,7 @@ func (m *Status) Unmarshal(dAtA []byte) error {
func skipStatus(dAtA []byte) (n int, err error) {
l := len(dAtA)
iNdEx := 0
depth := 0
for iNdEx < l {
var wire uint64
for shift := uint(0); ; shift += 7 {
@ -669,10 +680,8 @@ func skipStatus(dAtA []byte) (n int, err error) {
break
}
}
return iNdEx, nil
case 1:
iNdEx += 8
return iNdEx, nil
case 2:
var length int
for shift := uint(0); ; shift += 7 {
@ -693,55 +702,30 @@ func skipStatus(dAtA []byte) (n int, err error) {
return 0, ErrInvalidLengthStatus
}
iNdEx += length
if iNdEx < 0 {
return 0, ErrInvalidLengthStatus
}
return iNdEx, nil
case 3:
for {
var innerWire uint64
var start int = iNdEx
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return 0, ErrIntOverflowStatus
}
if iNdEx >= l {
return 0, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
innerWire |= (uint64(b) & 0x7F) << shift
if b < 0x80 {
break
}
}
innerWireType := int(innerWire & 0x7)
if innerWireType == 4 {
break
}
next, err := skipStatus(dAtA[start:])
if err != nil {
return 0, err
}
iNdEx = start + next
if iNdEx < 0 {
return 0, ErrInvalidLengthStatus
}
}
return iNdEx, nil
depth++
case 4:
return iNdEx, nil
if depth == 0 {
return 0, ErrUnexpectedEndOfGroupStatus
}
depth--
case 5:
iNdEx += 4
return iNdEx, nil
default:
return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
}
if iNdEx < 0 {
return 0, ErrInvalidLengthStatus
}
if depth == 0 {
return iNdEx, nil
}
}
panic("unreachable")
return 0, io.ErrUnexpectedEOF
}
var (
ErrInvalidLengthStatus = fmt.Errorf("proto: negative length found during unmarshaling")
ErrIntOverflowStatus = fmt.Errorf("proto: integer overflow")
ErrInvalidLengthStatus = fmt.Errorf("proto: negative length found during unmarshaling")
ErrIntOverflowStatus = fmt.Errorf("proto: integer overflow")
ErrUnexpectedEndOfGroupStatus = fmt.Errorf("proto: unexpected end of group")
)