Files
QSfera/Server/protogen/gen/qsfera/messages/search/v0/search.pb.web.go
T
Курнат Андрей 2315f25754 Initial QSfera import
2026-06-07 10:20:04 +03:00

300 lines
9.7 KiB
Go

// Code generated by protoc-gen-microweb. DO NOT EDIT.
// source: v0.proto
package v0
import (
"bytes"
"encoding/json"
"github.com/golang/protobuf/jsonpb"
)
// ResourceIDJSONMarshaler describes the default jsonpb.Marshaler used by all
// instances of ResourceID. This struct is safe to replace or modify but
// should not be done so concurrently.
var ResourceIDJSONMarshaler = new(jsonpb.Marshaler)
// MarshalJSON satisfies the encoding/json Marshaler interface. This method
// uses the more correct jsonpb package to correctly marshal the message.
func (m *ResourceID) MarshalJSON() ([]byte, error) {
if m == nil {
return json.Marshal(nil)
}
buf := &bytes.Buffer{}
if err := ResourceIDJSONMarshaler.Marshal(buf, m); err != nil {
return nil, err
}
return buf.Bytes(), nil
}
var _ json.Marshaler = (*ResourceID)(nil)
// ResourceIDJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all
// instances of ResourceID. This struct is safe to replace or modify but
// should not be done so concurrently.
var ResourceIDJSONUnmarshaler = new(jsonpb.Unmarshaler)
// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method
// uses the more correct jsonpb package to correctly unmarshal the message.
func (m *ResourceID) UnmarshalJSON(b []byte) error {
return ResourceIDJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m)
}
var _ json.Unmarshaler = (*ResourceID)(nil)
// ReferenceJSONMarshaler describes the default jsonpb.Marshaler used by all
// instances of Reference. This struct is safe to replace or modify but
// should not be done so concurrently.
var ReferenceJSONMarshaler = new(jsonpb.Marshaler)
// MarshalJSON satisfies the encoding/json Marshaler interface. This method
// uses the more correct jsonpb package to correctly marshal the message.
func (m *Reference) MarshalJSON() ([]byte, error) {
if m == nil {
return json.Marshal(nil)
}
buf := &bytes.Buffer{}
if err := ReferenceJSONMarshaler.Marshal(buf, m); err != nil {
return nil, err
}
return buf.Bytes(), nil
}
var _ json.Marshaler = (*Reference)(nil)
// ReferenceJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all
// instances of Reference. This struct is safe to replace or modify but
// should not be done so concurrently.
var ReferenceJSONUnmarshaler = new(jsonpb.Unmarshaler)
// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method
// uses the more correct jsonpb package to correctly unmarshal the message.
func (m *Reference) UnmarshalJSON(b []byte) error {
return ReferenceJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m)
}
var _ json.Unmarshaler = (*Reference)(nil)
// AudioJSONMarshaler describes the default jsonpb.Marshaler used by all
// instances of Audio. This struct is safe to replace or modify but
// should not be done so concurrently.
var AudioJSONMarshaler = new(jsonpb.Marshaler)
// MarshalJSON satisfies the encoding/json Marshaler interface. This method
// uses the more correct jsonpb package to correctly marshal the message.
func (m *Audio) MarshalJSON() ([]byte, error) {
if m == nil {
return json.Marshal(nil)
}
buf := &bytes.Buffer{}
if err := AudioJSONMarshaler.Marshal(buf, m); err != nil {
return nil, err
}
return buf.Bytes(), nil
}
var _ json.Marshaler = (*Audio)(nil)
// AudioJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all
// instances of Audio. This struct is safe to replace or modify but
// should not be done so concurrently.
var AudioJSONUnmarshaler = new(jsonpb.Unmarshaler)
// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method
// uses the more correct jsonpb package to correctly unmarshal the message.
func (m *Audio) UnmarshalJSON(b []byte) error {
return AudioJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m)
}
var _ json.Unmarshaler = (*Audio)(nil)
// ImageJSONMarshaler describes the default jsonpb.Marshaler used by all
// instances of Image. This struct is safe to replace or modify but
// should not be done so concurrently.
var ImageJSONMarshaler = new(jsonpb.Marshaler)
// MarshalJSON satisfies the encoding/json Marshaler interface. This method
// uses the more correct jsonpb package to correctly marshal the message.
func (m *Image) MarshalJSON() ([]byte, error) {
if m == nil {
return json.Marshal(nil)
}
buf := &bytes.Buffer{}
if err := ImageJSONMarshaler.Marshal(buf, m); err != nil {
return nil, err
}
return buf.Bytes(), nil
}
var _ json.Marshaler = (*Image)(nil)
// ImageJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all
// instances of Image. This struct is safe to replace or modify but
// should not be done so concurrently.
var ImageJSONUnmarshaler = new(jsonpb.Unmarshaler)
// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method
// uses the more correct jsonpb package to correctly unmarshal the message.
func (m *Image) UnmarshalJSON(b []byte) error {
return ImageJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m)
}
var _ json.Unmarshaler = (*Image)(nil)
// GeoCoordinatesJSONMarshaler describes the default jsonpb.Marshaler used by all
// instances of GeoCoordinates. This struct is safe to replace or modify but
// should not be done so concurrently.
var GeoCoordinatesJSONMarshaler = new(jsonpb.Marshaler)
// MarshalJSON satisfies the encoding/json Marshaler interface. This method
// uses the more correct jsonpb package to correctly marshal the message.
func (m *GeoCoordinates) MarshalJSON() ([]byte, error) {
if m == nil {
return json.Marshal(nil)
}
buf := &bytes.Buffer{}
if err := GeoCoordinatesJSONMarshaler.Marshal(buf, m); err != nil {
return nil, err
}
return buf.Bytes(), nil
}
var _ json.Marshaler = (*GeoCoordinates)(nil)
// GeoCoordinatesJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all
// instances of GeoCoordinates. This struct is safe to replace or modify but
// should not be done so concurrently.
var GeoCoordinatesJSONUnmarshaler = new(jsonpb.Unmarshaler)
// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method
// uses the more correct jsonpb package to correctly unmarshal the message.
func (m *GeoCoordinates) UnmarshalJSON(b []byte) error {
return GeoCoordinatesJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m)
}
var _ json.Unmarshaler = (*GeoCoordinates)(nil)
// PhotoJSONMarshaler describes the default jsonpb.Marshaler used by all
// instances of Photo. This struct is safe to replace or modify but
// should not be done so concurrently.
var PhotoJSONMarshaler = new(jsonpb.Marshaler)
// MarshalJSON satisfies the encoding/json Marshaler interface. This method
// uses the more correct jsonpb package to correctly marshal the message.
func (m *Photo) MarshalJSON() ([]byte, error) {
if m == nil {
return json.Marshal(nil)
}
buf := &bytes.Buffer{}
if err := PhotoJSONMarshaler.Marshal(buf, m); err != nil {
return nil, err
}
return buf.Bytes(), nil
}
var _ json.Marshaler = (*Photo)(nil)
// PhotoJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all
// instances of Photo. This struct is safe to replace or modify but
// should not be done so concurrently.
var PhotoJSONUnmarshaler = new(jsonpb.Unmarshaler)
// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method
// uses the more correct jsonpb package to correctly unmarshal the message.
func (m *Photo) UnmarshalJSON(b []byte) error {
return PhotoJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m)
}
var _ json.Unmarshaler = (*Photo)(nil)
// EntityJSONMarshaler describes the default jsonpb.Marshaler used by all
// instances of Entity. This struct is safe to replace or modify but
// should not be done so concurrently.
var EntityJSONMarshaler = new(jsonpb.Marshaler)
// MarshalJSON satisfies the encoding/json Marshaler interface. This method
// uses the more correct jsonpb package to correctly marshal the message.
func (m *Entity) MarshalJSON() ([]byte, error) {
if m == nil {
return json.Marshal(nil)
}
buf := &bytes.Buffer{}
if err := EntityJSONMarshaler.Marshal(buf, m); err != nil {
return nil, err
}
return buf.Bytes(), nil
}
var _ json.Marshaler = (*Entity)(nil)
// EntityJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all
// instances of Entity. This struct is safe to replace or modify but
// should not be done so concurrently.
var EntityJSONUnmarshaler = new(jsonpb.Unmarshaler)
// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method
// uses the more correct jsonpb package to correctly unmarshal the message.
func (m *Entity) UnmarshalJSON(b []byte) error {
return EntityJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m)
}
var _ json.Unmarshaler = (*Entity)(nil)
// MatchJSONMarshaler describes the default jsonpb.Marshaler used by all
// instances of Match. This struct is safe to replace or modify but
// should not be done so concurrently.
var MatchJSONMarshaler = new(jsonpb.Marshaler)
// MarshalJSON satisfies the encoding/json Marshaler interface. This method
// uses the more correct jsonpb package to correctly marshal the message.
func (m *Match) MarshalJSON() ([]byte, error) {
if m == nil {
return json.Marshal(nil)
}
buf := &bytes.Buffer{}
if err := MatchJSONMarshaler.Marshal(buf, m); err != nil {
return nil, err
}
return buf.Bytes(), nil
}
var _ json.Marshaler = (*Match)(nil)
// MatchJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all
// instances of Match. This struct is safe to replace or modify but
// should not be done so concurrently.
var MatchJSONUnmarshaler = new(jsonpb.Unmarshaler)
// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method
// uses the more correct jsonpb package to correctly unmarshal the message.
func (m *Match) UnmarshalJSON(b []byte) error {
return MatchJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m)
}
var _ json.Unmarshaler = (*Match)(nil)