chore: upgrade dependencies
This commit is contained in:
18
vendor/github.com/aws/smithy-go/document/document.go
generated
vendored
18
vendor/github.com/aws/smithy-go/document/document.go
generated
vendored
@@ -36,7 +36,7 @@ import (
|
||||
// - document field tag is "-"
|
||||
// - document field tag specifies "omitempty", and is a zero value.
|
||||
//
|
||||
// Pointer and interfaces values are encoded as the value pointed to or
|
||||
// Pointer and interface values are encoded as the value pointed to or
|
||||
// contained in the interface. A nil value encodes as a null
|
||||
// value unless `omitempty` struct tag is provided.
|
||||
//
|
||||
@@ -46,7 +46,7 @@ import (
|
||||
// time.Time is not supported and will cause the Marshaler to return an error. These values should be represented
|
||||
// by your application as a string or numerical representation.
|
||||
//
|
||||
// Errors that occur when marshaling will stop the marshaller, and return the error.
|
||||
// Errors that occur when marshaling will stop the marshaler, and return the error.
|
||||
//
|
||||
// Marshal cannot represent cyclic data structures and will not handle them.
|
||||
// Passing cyclic structures to Marshal will result in an infinite recursion.
|
||||
@@ -54,14 +54,14 @@ type Marshaler interface {
|
||||
MarshalSmithyDocument() ([]byte, error)
|
||||
}
|
||||
|
||||
// Unmarshaler is an interface for a type that unmarshalls a document from its protocol-specific representation, and
|
||||
// Unmarshaler is an interface for a type that unmarshals a document from its protocol-specific representation, and
|
||||
// stores the result into the value pointed by v. If v is nil or not a pointer then InvalidUnmarshalError will be
|
||||
// returned.
|
||||
//
|
||||
// Unmarshaler supports the same encodings produced by a document Marshaler. This includes support for the `document`
|
||||
// struct field tag for controlling how struct fields are unmarshalled.
|
||||
// struct field tag for controlling how struct fields are unmarshaled.
|
||||
//
|
||||
// Both generic interface{} and concrete types are valid unmarshal destination types. When unmarshalling a document
|
||||
// Both generic interface{} and concrete types are valid unmarshal destination types. When unmarshaling a document
|
||||
// into an empty interface the Unmarshaler will store one of these values:
|
||||
// bool, for boolean values
|
||||
// document.Number, for arbitrary-precision numbers (int64, float64, big.Int, big.Float)
|
||||
@@ -70,7 +70,7 @@ type Marshaler interface {
|
||||
// map[string]interface{}, for objects
|
||||
// nil, for null values
|
||||
//
|
||||
// When unmarshalling, any error that occurs will halt the unmarshal and return the error.
|
||||
// When unmarshaling, any error that occurs will halt the unmarshal and return the error.
|
||||
type Unmarshaler interface {
|
||||
UnmarshalSmithyDocument(v interface{}) error
|
||||
}
|
||||
@@ -79,7 +79,7 @@ type noSerde interface {
|
||||
noSmithyDocumentSerde()
|
||||
}
|
||||
|
||||
// NoSerde is a sentinel value to indicate that a given type should not be marshaled or unmarshalled
|
||||
// NoSerde is a sentinel value to indicate that a given type should not be marshaled or unmarshaled
|
||||
// into a protocol document.
|
||||
type NoSerde struct{}
|
||||
|
||||
@@ -93,7 +93,7 @@ func IsNoSerde(x interface{}) bool {
|
||||
return ok
|
||||
}
|
||||
|
||||
// Number is a arbitrary precision numerical value
|
||||
// Number is an arbitrary precision numerical value
|
||||
type Number string
|
||||
|
||||
// Int64 returns the number as a string.
|
||||
@@ -110,7 +110,7 @@ func (n Number) intOfBitSize(bitSize int) (int64, error) {
|
||||
return strconv.ParseInt(string(n), 10, bitSize)
|
||||
}
|
||||
|
||||
// Uint64 returns the number as an uint64.
|
||||
// Uint64 returns the number as a uint64.
|
||||
func (n Number) Uint64() (uint64, error) {
|
||||
return n.uintOfBitSize(64)
|
||||
}
|
||||
|
||||
20
vendor/github.com/aws/smithy-go/document/errors.go
generated
vendored
20
vendor/github.com/aws/smithy-go/document/errors.go
generated
vendored
@@ -5,8 +5,8 @@ import (
|
||||
"reflect"
|
||||
)
|
||||
|
||||
// UnmarshalTypeError is an error type representing aa error
|
||||
// unmarshalling a Smithy document to a Go value type. This is different
|
||||
// UnmarshalTypeError is an error type representing an error
|
||||
// unmarshaling a Smithy document to a Go value type. This is different
|
||||
// from UnmarshalError in that it does not wrap an underlying error type.
|
||||
type UnmarshalTypeError struct {
|
||||
Value string
|
||||
@@ -14,20 +14,20 @@ type UnmarshalTypeError struct {
|
||||
}
|
||||
|
||||
// Error returns the string representation of the error.
|
||||
// satisfying the error interface
|
||||
// Satisfying the error interface.
|
||||
func (e *UnmarshalTypeError) Error() string {
|
||||
return fmt.Sprintf("unmarshal failed, cannot unmarshal %s into Go value type %s",
|
||||
e.Value, e.Type.String())
|
||||
}
|
||||
|
||||
// An InvalidUnmarshalError is an error type representing an invalid type
|
||||
// encountered while unmarshalling a Smithy document to a Go value type.
|
||||
// encountered while unmarshaling a Smithy document to a Go value type.
|
||||
type InvalidUnmarshalError struct {
|
||||
Type reflect.Type
|
||||
}
|
||||
|
||||
// Error returns the string representation of the error.
|
||||
// satisfying the error interface
|
||||
// Satisfying the error interface.
|
||||
func (e *InvalidUnmarshalError) Error() string {
|
||||
var msg string
|
||||
if e.Type == nil {
|
||||
@@ -41,7 +41,7 @@ func (e *InvalidUnmarshalError) Error() string {
|
||||
return fmt.Sprintf("unmarshal failed, %s", msg)
|
||||
}
|
||||
|
||||
// An UnmarshalError wraps an error that occurred while unmarshalling a
|
||||
// An UnmarshalError wraps an error that occurred while unmarshaling a
|
||||
// Smithy document into a Go type. This is different from
|
||||
// UnmarshalTypeError in that it wraps the underlying error that occurred.
|
||||
type UnmarshalError struct {
|
||||
@@ -50,13 +50,13 @@ type UnmarshalError struct {
|
||||
Type reflect.Type
|
||||
}
|
||||
|
||||
// Unwrap returns the underlying unmarshalling error
|
||||
// Unwrap returns the underlying unmarshaling error
|
||||
func (e *UnmarshalError) Unwrap() error {
|
||||
return e.Err
|
||||
}
|
||||
|
||||
// Error returns the string representation of the error satisfying the error
|
||||
// interface.
|
||||
// Error returns the string representation of the error.
|
||||
// Satisfying the error interface.
|
||||
func (e *UnmarshalError) Error() string {
|
||||
return fmt.Sprintf("unmarshal failed, cannot unmarshal %q into %s, %v",
|
||||
e.Value, e.Type.String(), e.Err)
|
||||
@@ -69,7 +69,7 @@ type InvalidMarshalError struct {
|
||||
}
|
||||
|
||||
// Error returns the string representation of the error.
|
||||
// satisfying the error interface
|
||||
// Satisfying the error interface.
|
||||
func (e *InvalidMarshalError) Error() string {
|
||||
return fmt.Sprintf("marshal failed, %s", e.Message)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user