forked from forgejo/forgejo
[Vendor] update go-swagger v0.21.0 -> v0.25.0 (#12670)
* Update go-swagger * vendor
This commit is contained in:
parent
66843f2237
commit
3270e7a443
350 changed files with 26353 additions and 5552 deletions
29
vendor/github.com/go-openapi/strfmt/date.go
generated
vendored
29
vendor/github.com/go-openapi/strfmt/date.go
generated
vendored
|
@ -151,3 +151,32 @@ func (d *Date) DeepCopy() *Date {
|
|||
d.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// GobEncode implements the gob.GobEncoder interface.
|
||||
func (d Date) GobEncode() ([]byte, error) {
|
||||
return d.MarshalBinary()
|
||||
}
|
||||
|
||||
// GobDecode implements the gob.GobDecoder interface.
|
||||
func (d *Date) GobDecode(data []byte) error {
|
||||
return d.UnmarshalBinary(data)
|
||||
}
|
||||
|
||||
// MarshalBinary implements the encoding.BinaryMarshaler interface.
|
||||
func (d Date) MarshalBinary() ([]byte, error) {
|
||||
return time.Time(d).MarshalBinary()
|
||||
}
|
||||
|
||||
// UnmarshalBinary implements the encoding.BinaryUnmarshaler interface.
|
||||
func (d *Date) UnmarshalBinary(data []byte) error {
|
||||
var original time.Time
|
||||
|
||||
err := original.UnmarshalBinary(data)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*d = Date(original)
|
||||
|
||||
return nil
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue