2024-07-05 22:20:13 -04:00
// Code generated by protoc-gen-go-pulsar. DO NOT EDIT.
package didv1
import (
fmt "fmt"
runtime "github.com/cosmos/cosmos-proto/runtime"
2024-09-05 01:24:57 -04:00
_ "github.com/cosmos/gogoproto/gogoproto"
2024-07-05 22:20:13 -04:00
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoiface "google.golang.org/protobuf/runtime/protoiface"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
io "io"
reflect "reflect"
2024-07-06 03:02:45 -04:00
sort "sort"
2024-07-05 22:20:13 -04:00
sync "sync"
)
var (
2024-09-05 01:24:57 -04:00
md_Accumulator protoreflect . MessageDescriptor
fd_Accumulator_accumulator protoreflect . FieldDescriptor
2024-07-05 22:20:13 -04:00
)
func init () {
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_init ()
2024-09-05 01:24:57 -04:00
md_Accumulator = File_did_v1_models_proto . Messages (). ByName ( "Accumulator" )
fd_Accumulator_accumulator = md_Accumulator . Fields (). ByName ( "accumulator" )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . Message = ( * fastReflection_Accumulator )( nil )
2024-08-31 12:49:44 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_Accumulator Accumulator
2024-08-31 12:49:44 -04:00
2024-09-05 01:24:57 -04:00
func ( x * Accumulator ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_Accumulator )( x )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * Accumulator ) slowProtoReflect () protoreflect . Message {
2024-08-31 12:49:44 -04:00
mi := & file_did_v1_models_proto_msgTypes [ 0 ]
2024-07-05 22:20:13 -04:00
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
2024-09-05 01:24:57 -04:00
var _fastReflection_Accumulator_messageType fastReflection_Accumulator_messageType
var _ protoreflect . MessageType = fastReflection_Accumulator_messageType {}
2024-07-05 22:20:13 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_Accumulator_messageType struct {}
2024-07-05 22:20:13 -04:00
2024-09-05 01:24:57 -04:00
func ( x fastReflection_Accumulator_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_Accumulator )( nil )
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_Accumulator_messageType ) New () protoreflect . Message {
return new ( fastReflection_Accumulator )
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_Accumulator_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_Accumulator
2024-07-05 22:20:13 -04:00
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) Descriptor () protoreflect . MessageDescriptor {
return md_Accumulator
2024-07-05 22:20:13 -04:00
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) Type () protoreflect . MessageType {
return _fastReflection_Accumulator_messageType
2024-07-05 22:20:13 -04:00
}
// New returns a newly allocated and mutable empty message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) New () protoreflect . Message {
return new ( fastReflection_Accumulator )
2024-07-05 22:20:13 -04:00
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) Interface () protoreflect . ProtoMessage {
return ( * Accumulator )( x )
2024-07-05 22:20:13 -04:00
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
if len ( x . Accumulator ) != 0 {
value := protoreflect . ValueOfBytes ( x . Accumulator )
if ! f ( fd_Accumulator_accumulator , value ) {
2024-07-05 22:20:13 -04:00
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) Has ( fd protoreflect . FieldDescriptor ) bool {
2024-07-05 22:20:13 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Accumulator.accumulator" :
return len ( x . Accumulator ) != 0
2024-07-05 22:20:13 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Accumulator" ))
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Accumulator does not contain field %s" , fd . FullName ()))
2024-07-05 22:20:13 -04:00
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) Clear ( fd protoreflect . FieldDescriptor ) {
2024-07-05 22:20:13 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Accumulator.accumulator" :
x . Accumulator = nil
2024-07-05 22:20:13 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Accumulator" ))
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Accumulator does not contain field %s" , fd . FullName ()))
2024-07-05 22:20:13 -04:00
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
2024-07-05 22:20:13 -04:00
switch descriptor . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Accumulator.accumulator" :
value := x . Accumulator
return protoreflect . ValueOfBytes ( value )
2024-07-05 22:20:13 -04:00
default :
if descriptor . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Accumulator" ))
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Accumulator does not contain field %s" , descriptor . FullName ()))
2024-07-05 22:20:13 -04:00
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
2024-07-05 22:20:13 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Accumulator.accumulator" :
x . Accumulator = value . Bytes ()
2024-07-05 22:20:13 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Accumulator" ))
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Accumulator does not contain field %s" , fd . FullName ()))
2024-07-05 22:20:13 -04:00
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-07-05 22:20:13 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Accumulator.accumulator" :
panic ( fmt . Errorf ( "field accumulator of message did.v1.Accumulator is not mutable" ))
2024-07-05 22:20:13 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Accumulator" ))
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Accumulator does not contain field %s" , fd . FullName ()))
2024-07-05 22:20:13 -04:00
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-07-05 22:20:13 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Accumulator.accumulator" :
return protoreflect . ValueOfBytes ( nil )
2024-07-05 22:20:13 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Accumulator" ))
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Accumulator does not contain field %s" , fd . FullName ()))
2024-07-05 22:20:13 -04:00
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
2024-07-05 22:20:13 -04:00
switch d . FullName () {
default :
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.Accumulator" , d . FullName ()))
2024-07-05 22:20:13 -04:00
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) GetUnknown () protoreflect . RawFields {
2024-07-05 22:20:13 -04:00
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) SetUnknown ( fields protoreflect . RawFields ) {
2024-07-05 22:20:13 -04:00
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) IsValid () bool {
2024-07-05 22:20:13 -04:00
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Accumulator ) ProtoMethods () * protoiface . Methods {
2024-07-05 22:20:13 -04:00
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Accumulator )
2024-07-05 22:20:13 -04:00
if x == nil {
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
}
}
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
2024-09-05 01:24:57 -04:00
l = len ( x . Accumulator )
2024-08-10 17:19:59 -04:00
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
2024-07-05 22:20:13 -04:00
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Accumulator )
2024-07-05 22:20:13 -04:00
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
}
2024-09-05 01:24:57 -04:00
if len ( x . Accumulator ) > 0 {
i -= len ( x . Accumulator )
copy ( dAtA [ i :], x . Accumulator )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Accumulator )))
2024-08-10 17:19:59 -04:00
i --
2024-09-05 01:24:57 -04:00
dAtA [ i ] = 0xa
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
2024-07-05 22:20:13 -04:00
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Accumulator )
2024-07-05 22:20:13 -04:00
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Accumulator: wiretype end group for non-group" )
2024-07-05 22:20:13 -04:00
}
if fieldNum <= 0 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Accumulator: illegal tag %d (wire type %d)" , fieldNum , wire )
2024-07-05 22:20:13 -04:00
}
switch fieldNum {
case 1 :
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Accumulator" , wireType )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
var byteLen int
2024-08-10 17:01:14 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-09-05 01:24:57 -04:00
byteLen |= int ( b & 0x7F ) << shift
2024-08-10 17:01:14 -04:00
if b < 0x80 {
break
}
}
2024-09-05 01:24:57 -04:00
if byteLen < 0 {
2024-08-10 17:01:14 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
2024-09-05 01:24:57 -04:00
postIndex := iNdEx + byteLen
2024-08-10 17:01:14 -04:00
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
x . Accumulator = append ( x . Accumulator [: 0 ], dAtA [ iNdEx : postIndex ] ... )
if x . Accumulator == nil {
x . Accumulator = [] byte {}
2024-08-10 17:01:14 -04:00
}
iNdEx = postIndex
2024-08-31 12:49:44 -04:00
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
2024-07-05 22:20:13 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
2024-08-31 12:49:44 -04:00
if ( iNdEx + skippy ) > l {
2024-08-10 17:01:14 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-08-31 12:49:44 -04:00
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
2024-08-10 17:19:59 -04:00
}
iNdEx += skippy
}
}
2024-08-10 17:01:14 -04:00
2024-08-10 17:19:59 -04:00
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
}
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
var _ protoreflect . List = ( * _Credential_4_list )( nil )
2024-08-10 17:01:14 -04:00
2024-08-31 12:49:44 -04:00
type _Credential_4_list struct {
list * [] string
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * _Credential_4_list ) Len () int {
2024-08-10 17:01:14 -04:00
if x . list == nil {
return 0
}
return len ( * x . list )
}
2024-08-31 12:49:44 -04:00
func ( x * _Credential_4_list ) Get ( i int ) protoreflect . Value {
return protoreflect . ValueOfString (( * x . list )[ i ])
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * _Credential_4_list ) Set ( i int , value protoreflect . Value ) {
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
2024-08-10 17:01:14 -04:00
( * x . list )[ i ] = concreteValue
}
2024-08-31 12:49:44 -04:00
func ( x * _Credential_4_list ) Append ( value protoreflect . Value ) {
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
2024-08-10 17:01:14 -04:00
* x . list = append ( * x . list , concreteValue )
}
2024-08-31 12:49:44 -04:00
func ( x * _Credential_4_list ) AppendMutable () protoreflect . Value {
panic ( fmt . Errorf ( "AppendMutable can not be called on message Credential at list field Transport as it is not of Message kind" ))
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * _Credential_4_list ) Truncate ( n int ) {
2024-08-10 17:01:14 -04:00
* x . list = ( * x . list )[: n ]
}
2024-08-31 12:49:44 -04:00
func ( x * _Credential_4_list ) NewElement () protoreflect . Value {
v := ""
return protoreflect . ValueOfString ( v )
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * _Credential_4_list ) IsValid () bool {
2024-08-10 17:01:14 -04:00
return x . list != nil
}
2024-08-10 17:19:59 -04:00
var (
2024-08-31 12:49:44 -04:00
md_Credential protoreflect . MessageDescriptor
fd_Credential_id protoreflect . FieldDescriptor
fd_Credential_credential_type protoreflect . FieldDescriptor
fd_Credential_credential_id protoreflect . FieldDescriptor
fd_Credential_transport protoreflect . FieldDescriptor
fd_Credential_subject protoreflect . FieldDescriptor
fd_Credential_controller protoreflect . FieldDescriptor
2024-08-10 17:19:59 -04:00
)
2024-08-10 17:01:14 -04:00
2024-08-10 17:19:59 -04:00
func init () {
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_init ()
md_Credential = File_did_v1_models_proto . Messages (). ByName ( "Credential" )
fd_Credential_id = md_Credential . Fields (). ByName ( "id" )
fd_Credential_credential_type = md_Credential . Fields (). ByName ( "credential_type" )
fd_Credential_credential_id = md_Credential . Fields (). ByName ( "credential_id" )
fd_Credential_transport = md_Credential . Fields (). ByName ( "transport" )
fd_Credential_subject = md_Credential . Fields (). ByName ( "subject" )
fd_Credential_controller = md_Credential . Fields (). ByName ( "controller" )
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
var _ protoreflect . Message = ( * fastReflection_Credential )( nil )
2024-08-10 17:01:14 -04:00
2024-08-31 12:49:44 -04:00
type fastReflection_Credential Credential
2024-08-10 17:01:14 -04:00
2024-08-31 12:49:44 -04:00
func ( x * Credential ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_Credential )( x )
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * Credential ) slowProtoReflect () protoreflect . Message {
mi := & file_did_v1_models_proto_msgTypes [ 1 ]
2024-08-10 17:19:59 -04:00
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
2024-08-31 12:49:44 -04:00
var _fastReflection_Credential_messageType fastReflection_Credential_messageType
var _ protoreflect . MessageType = fastReflection_Credential_messageType {}
2024-08-10 17:19:59 -04:00
2024-08-31 12:49:44 -04:00
type fastReflection_Credential_messageType struct {}
2024-08-10 17:19:59 -04:00
2024-08-31 12:49:44 -04:00
func ( x fastReflection_Credential_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_Credential )( nil )
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x fastReflection_Credential_messageType ) New () protoreflect . Message {
return new ( fastReflection_Credential )
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x fastReflection_Credential_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_Credential
2024-08-10 17:19:59 -04:00
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) Descriptor () protoreflect . MessageDescriptor {
return md_Credential
2024-08-10 17:19:59 -04:00
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) Type () protoreflect . MessageType {
return _fastReflection_Credential_messageType
2024-08-10 17:19:59 -04:00
}
// New returns a newly allocated and mutable empty message.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) New () protoreflect . Message {
return new ( fastReflection_Credential )
2024-08-10 17:19:59 -04:00
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) Interface () protoreflect . ProtoMessage {
return ( * Credential )( x )
2024-08-10 17:19:59 -04:00
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
2024-08-10 17:19:59 -04:00
if x . Id != "" {
value := protoreflect . ValueOfString ( x . Id )
2024-08-31 12:49:44 -04:00
if ! f ( fd_Credential_id , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
2024-08-31 12:49:44 -04:00
if x . CredentialType != "" {
value := protoreflect . ValueOfString ( x . CredentialType )
if ! f ( fd_Credential_credential_type , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
2024-08-31 12:49:44 -04:00
if len ( x . CredentialId ) != 0 {
value := protoreflect . ValueOfBytes ( x . CredentialId )
if ! f ( fd_Credential_credential_id , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
2024-08-31 12:49:44 -04:00
if len ( x . Transport ) != 0 {
value := protoreflect . ValueOfList ( & _Credential_4_list { list : & x . Transport })
if ! f ( fd_Credential_transport , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
2024-08-31 12:49:44 -04:00
if x . Subject != "" {
value := protoreflect . ValueOfString ( x . Subject )
if ! f ( fd_Credential_subject , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
2024-08-31 12:49:44 -04:00
if x . Controller != "" {
value := protoreflect . ValueOfString ( x . Controller )
if ! f ( fd_Credential_controller , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) Has ( fd protoreflect . FieldDescriptor ) bool {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.id" :
2024-08-10 17:19:59 -04:00
return x . Id != ""
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.credential_type" :
return x . CredentialType != ""
case "did.v1.Credential.credential_id" :
return len ( x . CredentialId ) != 0
case "did.v1.Credential.transport" :
return len ( x . Transport ) != 0
case "did.v1.Credential.subject" :
return x . Subject != ""
case "did.v1.Credential.controller" :
return x . Controller != ""
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Credential" ))
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "message did.v1.Credential does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) Clear ( fd protoreflect . FieldDescriptor ) {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.id" :
2024-08-10 17:19:59 -04:00
x . Id = ""
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.credential_type" :
x . CredentialType = ""
case "did.v1.Credential.credential_id" :
x . CredentialId = nil
case "did.v1.Credential.transport" :
x . Transport = nil
case "did.v1.Credential.subject" :
x . Subject = ""
case "did.v1.Credential.controller" :
x . Controller = ""
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Credential" ))
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "message did.v1.Credential does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:19:59 -04:00
switch descriptor . FullName () {
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.id" :
2024-08-10 17:19:59 -04:00
value := x . Id
return protoreflect . ValueOfString ( value )
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.credential_type" :
value := x . CredentialType
2024-08-10 17:19:59 -04:00
return protoreflect . ValueOfString ( value )
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.credential_id" :
value := x . CredentialId
return protoreflect . ValueOfBytes ( value )
case "did.v1.Credential.transport" :
if len ( x . Transport ) == 0 {
return protoreflect . ValueOfList ( & _Credential_4_list {})
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
listValue := & _Credential_4_list { list : & x . Transport }
2024-08-10 17:19:59 -04:00
return protoreflect . ValueOfList ( listValue )
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.subject" :
value := x . Subject
return protoreflect . ValueOfString ( value )
case "did.v1.Credential.controller" :
value := x . Controller
return protoreflect . ValueOfString ( value )
2024-08-10 17:19:59 -04:00
default :
if descriptor . IsExtension () {
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Credential" ))
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "message did.v1.Credential does not contain field %s" , descriptor . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.id" :
2024-08-10 17:19:59 -04:00
x . Id = value . Interface ().( string )
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.credential_type" :
x . CredentialType = value . Interface ().( string )
case "did.v1.Credential.credential_id" :
x . CredentialId = value . Bytes ()
case "did.v1.Credential.transport" :
2024-08-10 17:19:59 -04:00
lv := value . List ()
2024-08-31 12:49:44 -04:00
clv := lv .( * _Credential_4_list )
x . Transport = * clv . list
case "did.v1.Credential.subject" :
x . Subject = value . Interface ().( string )
case "did.v1.Credential.controller" :
x . Controller = value . Interface ().( string )
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Credential" ))
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "message did.v1.Credential does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.transport" :
if x . Transport == nil {
x . Transport = [] string {}
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
value := & _Credential_4_list { list : & x . Transport }
2024-08-10 17:19:59 -04:00
return protoreflect . ValueOfList ( value )
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.id" :
panic ( fmt . Errorf ( "field id of message did.v1.Credential is not mutable" ))
case "did.v1.Credential.credential_type" :
panic ( fmt . Errorf ( "field credential_type of message did.v1.Credential is not mutable" ))
case "did.v1.Credential.credential_id" :
panic ( fmt . Errorf ( "field credential_id of message did.v1.Credential is not mutable" ))
case "did.v1.Credential.subject" :
panic ( fmt . Errorf ( "field subject of message did.v1.Credential is not mutable" ))
case "did.v1.Credential.controller" :
panic ( fmt . Errorf ( "field controller of message did.v1.Credential is not mutable" ))
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Credential" ))
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "message did.v1.Credential does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.id" :
2024-08-10 17:19:59 -04:00
return protoreflect . ValueOfString ( "" )
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.credential_type" :
2024-08-10 17:19:59 -04:00
return protoreflect . ValueOfString ( "" )
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.credential_id" :
return protoreflect . ValueOfBytes ( nil )
case "did.v1.Credential.transport" :
list := [] string {}
return protoreflect . ValueOfList ( & _Credential_4_list { list : & list })
case "did.v1.Credential.subject" :
2024-08-10 17:19:59 -04:00
return protoreflect . ValueOfString ( "" )
2024-08-31 12:49:44 -04:00
case "did.v1.Credential.controller" :
2024-08-10 17:19:59 -04:00
return protoreflect . ValueOfString ( "" )
default :
if fd . IsExtension () {
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Credential" ))
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "message did.v1.Credential does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
2024-08-10 17:19:59 -04:00
switch d . FullName () {
default :
2024-08-31 12:49:44 -04:00
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.Credential" , d . FullName ()))
2024-08-10 17:19:59 -04:00
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) GetUnknown () protoreflect . RawFields {
2024-08-10 17:19:59 -04:00
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) SetUnknown ( fields protoreflect . RawFields ) {
2024-08-10 17:19:59 -04:00
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) IsValid () bool {
2024-08-10 17:19:59 -04:00
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
2024-08-31 12:49:44 -04:00
func ( x * fastReflection_Credential ) ProtoMethods () * protoiface . Methods {
2024-08-10 17:19:59 -04:00
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
2024-08-31 12:49:44 -04:00
x := input . Message . Interface ().( * Credential )
2024-08-10 17:19:59 -04:00
if x == nil {
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
}
}
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
l = len ( x . Id )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
2024-08-31 12:49:44 -04:00
l = len ( x . CredentialType )
2024-08-10 17:19:59 -04:00
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
2024-08-31 12:49:44 -04:00
l = len ( x . CredentialId )
2024-08-10 17:19:59 -04:00
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
2024-08-31 12:49:44 -04:00
if len ( x . Transport ) > 0 {
for _ , s := range x . Transport {
l = len ( s )
2024-08-10 17:19:59 -04:00
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
}
2024-08-31 12:49:44 -04:00
l = len ( x . Subject )
if l > 0 {
2024-08-10 17:19:59 -04:00
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
2024-08-31 12:49:44 -04:00
l = len ( x . Controller )
if l > 0 {
2024-08-10 17:19:59 -04:00
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
2024-08-31 12:49:44 -04:00
x := input . Message . Interface ().( * Credential )
2024-08-10 17:19:59 -04:00
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
}
2024-08-31 12:49:44 -04:00
if len ( x . Controller ) > 0 {
i -= len ( x . Controller )
copy ( dAtA [ i :], x . Controller )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Controller )))
2024-08-10 17:19:59 -04:00
i --
2024-08-31 12:49:44 -04:00
dAtA [ i ] = 0x3a
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
if len ( x . Subject ) > 0 {
i -= len ( x . Subject )
copy ( dAtA [ i :], x . Subject )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Subject )))
2024-08-10 17:19:59 -04:00
i --
2024-08-31 12:49:44 -04:00
dAtA [ i ] = 0x32
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
if len ( x . Transport ) > 0 {
for iNdEx := len ( x . Transport ) - 1 ; iNdEx >= 0 ; iNdEx -- {
i -= len ( x . Transport [ iNdEx ])
copy ( dAtA [ i :], x . Transport [ iNdEx ])
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Transport [ iNdEx ])))
2024-08-10 17:19:59 -04:00
i --
2024-08-31 12:49:44 -04:00
dAtA [ i ] = 0x22
2024-08-10 17:19:59 -04:00
}
}
2024-08-31 12:49:44 -04:00
if len ( x . CredentialId ) > 0 {
i -= len ( x . CredentialId )
copy ( dAtA [ i :], x . CredentialId )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . CredentialId )))
2024-08-10 17:19:59 -04:00
i --
dAtA [ i ] = 0x1a
}
2024-08-31 12:49:44 -04:00
if len ( x . CredentialType ) > 0 {
i -= len ( x . CredentialType )
copy ( dAtA [ i :], x . CredentialType )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . CredentialType )))
2024-08-10 17:19:59 -04:00
i --
dAtA [ i ] = 0x12
}
if len ( x . Id ) > 0 {
i -= len ( x . Id )
copy ( dAtA [ i :], x . Id )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Id )))
i --
dAtA [ i ] = 0xa
}
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
2024-08-31 12:49:44 -04:00
x := input . Message . Interface ().( * Credential )
2024-08-10 17:19:59 -04:00
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Credential: wiretype end group for non-group" )
2024-08-10 17:19:59 -04:00
}
if fieldNum <= 0 {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Credential: illegal tag %d (wire type %d)" , fieldNum , wire )
2024-08-10 17:19:59 -04:00
}
switch fieldNum {
case 1 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Id" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Id = string ( dAtA [ iNdEx : postIndex ])
iNdEx = postIndex
case 2 :
if wireType != 2 {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field CredentialType" , wireType )
2024-08-10 17:19:59 -04:00
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-08-31 12:49:44 -04:00
x . CredentialType = string ( dAtA [ iNdEx : postIndex ])
2024-08-10 17:19:59 -04:00
iNdEx = postIndex
case 3 :
if wireType != 2 {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field CredentialId" , wireType )
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
var byteLen int
2024-08-10 17:19:59 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-08-31 12:49:44 -04:00
byteLen |= int ( b & 0x7F ) << shift
2024-08-10 17:19:59 -04:00
if b < 0x80 {
break
}
}
2024-08-31 12:49:44 -04:00
if byteLen < 0 {
2024-08-10 17:19:59 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
2024-08-31 12:49:44 -04:00
postIndex := iNdEx + byteLen
2024-08-10 17:19:59 -04:00
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-08-31 12:49:44 -04:00
x . CredentialId = append ( x . CredentialId [: 0 ], dAtA [ iNdEx : postIndex ] ... )
if x . CredentialId == nil {
x . CredentialId = [] byte {}
}
2024-08-10 17:19:59 -04:00
iNdEx = postIndex
case 4 :
if wireType != 2 {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Transport" , wireType )
2024-08-10 17:19:59 -04:00
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-08-31 12:49:44 -04:00
x . Transport = append ( x . Transport , string ( dAtA [ iNdEx : postIndex ]))
2024-08-10 17:19:59 -04:00
iNdEx = postIndex
2024-08-31 12:49:44 -04:00
case 6 :
2024-08-10 17:19:59 -04:00
if wireType != 2 {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Subject" , wireType )
2024-08-10 17:19:59 -04:00
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-08-31 12:49:44 -04:00
x . Subject = string ( dAtA [ iNdEx : postIndex ])
2024-08-10 17:19:59 -04:00
iNdEx = postIndex
2024-08-31 12:49:44 -04:00
case 7 :
2024-08-10 17:19:59 -04:00
if wireType != 2 {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Controller" , wireType )
2024-08-10 17:19:59 -04:00
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-08-31 12:49:44 -04:00
x . Controller = string ( dAtA [ iNdEx : postIndex ])
2024-08-10 17:19:59 -04:00
iNdEx = postIndex
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
}
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . List = ( * _DID_5_list )( nil )
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
type _DID_5_list struct {
2024-08-31 12:49:44 -04:00
list * [] string
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _DID_5_list ) Len () int {
2024-08-31 12:49:44 -04:00
if x . list == nil {
return 0
}
return len ( * x . list )
}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
func ( x * _DID_5_list ) Get ( i int ) protoreflect . Value {
2024-08-31 12:49:44 -04:00
return protoreflect . ValueOfString (( * x . list )[ i ])
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _DID_5_list ) Set ( i int , value protoreflect . Value ) {
2024-08-31 12:49:44 -04:00
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
( * x . list )[ i ] = concreteValue
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _DID_5_list ) Append ( value protoreflect . Value ) {
2024-08-31 12:49:44 -04:00
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
* x . list = append ( * x . list , concreteValue )
}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
func ( x * _DID_5_list ) AppendMutable () protoreflect . Value {
panic ( fmt . Errorf ( "AppendMutable can not be called on message DID at list field Paths as it is not of Message kind" ))
2024-08-31 12:49:44 -04:00
}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
func ( x * _DID_5_list ) Truncate ( n int ) {
2024-08-31 12:49:44 -04:00
* x . list = ( * x . list )[: n ]
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
2024-09-05 01:24:57 -04:00
func ( x * _DID_5_list ) NewElement () protoreflect . Value {
2024-08-31 12:49:44 -04:00
v := ""
return protoreflect . ValueOfString ( v )
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
2024-09-05 01:24:57 -04:00
func ( x * _DID_5_list ) IsValid () bool {
2024-08-31 12:49:44 -04:00
return x . list != nil
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
var (
md_DID protoreflect . MessageDescriptor
fd_DID_method protoreflect . FieldDescriptor
fd_DID_network protoreflect . FieldDescriptor
fd_DID_subject protoreflect . FieldDescriptor
fd_DID_identifier protoreflect . FieldDescriptor
fd_DID_paths protoreflect . FieldDescriptor
)
2024-08-31 12:49:44 -04:00
2024-09-05 01:24:57 -04:00
func init () {
file_did_v1_models_proto_init ()
md_DID = File_did_v1_models_proto . Messages (). ByName ( "DID" )
fd_DID_method = md_DID . Fields (). ByName ( "method" )
fd_DID_network = md_DID . Fields (). ByName ( "network" )
fd_DID_subject = md_DID . Fields (). ByName ( "subject" )
fd_DID_identifier = md_DID . Fields (). ByName ( "identifier" )
fd_DID_paths = md_DID . Fields (). ByName ( "paths" )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . Message = ( * fastReflection_DID )( nil )
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_DID DID
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
func ( x * DID ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_DID )( x )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * DID ) slowProtoReflect () protoreflect . Message {
2024-08-31 12:49:44 -04:00
mi := & file_did_v1_models_proto_msgTypes [ 2 ]
2024-08-10 17:19:59 -04:00
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
2024-09-05 01:24:57 -04:00
var _fastReflection_DID_messageType fastReflection_DID_messageType
var _ protoreflect . MessageType = fastReflection_DID_messageType {}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_DID_messageType struct {}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
func ( x fastReflection_DID_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_DID )( nil )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_DID_messageType ) New () protoreflect . Message {
return new ( fastReflection_DID )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_DID_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_DID
2024-08-10 17:19:59 -04:00
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) Descriptor () protoreflect . MessageDescriptor {
return md_DID
2024-08-10 17:19:59 -04:00
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) Type () protoreflect . MessageType {
return _fastReflection_DID_messageType
2024-08-10 17:19:59 -04:00
}
// New returns a newly allocated and mutable empty message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) New () protoreflect . Message {
return new ( fastReflection_DID )
2024-08-10 17:19:59 -04:00
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) Interface () protoreflect . ProtoMessage {
return ( * DID )( x )
2024-08-10 17:19:59 -04:00
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
if x . Method != 0 {
value := protoreflect . ValueOfEnum (( protoreflect . EnumNumber )( x . Method ))
if ! f ( fd_DID_method , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if x . Network != "" {
value := protoreflect . ValueOfString ( x . Network )
if ! f ( fd_DID_network , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if x . Subject != "" {
value := protoreflect . ValueOfString ( x . Subject )
if ! f ( fd_DID_subject , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if x . Identifier != "" {
value := protoreflect . ValueOfString ( x . Identifier )
if ! f ( fd_DID_identifier , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if len ( x . Paths ) != 0 {
value := protoreflect . ValueOfList ( & _DID_5_list { list : & x . Paths })
if ! f ( fd_DID_paths , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) Has ( fd protoreflect . FieldDescriptor ) bool {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.DID.method" :
return x . Method != 0
case "did.v1.DID.network" :
return x . Network != ""
case "did.v1.DID.subject" :
return x . Subject != ""
case "did.v1.DID.identifier" :
return x . Identifier != ""
case "did.v1.DID.paths" :
return len ( x . Paths ) != 0
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.DID" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.DID does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) Clear ( fd protoreflect . FieldDescriptor ) {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.DID.method" :
x . Method = 0
case "did.v1.DID.network" :
x . Network = ""
case "did.v1.DID.subject" :
x . Subject = ""
case "did.v1.DID.identifier" :
x . Identifier = ""
case "did.v1.DID.paths" :
x . Paths = nil
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.DID" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.DID does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:19:59 -04:00
switch descriptor . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.DID.method" :
value := x . Method
return protoreflect . ValueOfEnum (( protoreflect . EnumNumber )( value ))
case "did.v1.DID.network" :
value := x . Network
2024-08-10 17:19:59 -04:00
return protoreflect . ValueOfString ( value )
2024-09-05 01:24:57 -04:00
case "did.v1.DID.subject" :
value := x . Subject
return protoreflect . ValueOfString ( value )
case "did.v1.DID.identifier" :
value := x . Identifier
return protoreflect . ValueOfString ( value )
case "did.v1.DID.paths" :
if len ( x . Paths ) == 0 {
return protoreflect . ValueOfList ( & _DID_5_list {})
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
listValue := & _DID_5_list { list : & x . Paths }
2024-08-10 17:19:59 -04:00
return protoreflect . ValueOfList ( listValue )
default :
if descriptor . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.DID" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.DID does not contain field %s" , descriptor . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.DID.method" :
x . Method = ( DIDNamespace )( value . Enum ())
case "did.v1.DID.network" :
x . Network = value . Interface ().( string )
case "did.v1.DID.subject" :
x . Subject = value . Interface ().( string )
case "did.v1.DID.identifier" :
x . Identifier = value . Interface ().( string )
case "did.v1.DID.paths" :
2024-08-10 17:19:59 -04:00
lv := value . List ()
2024-09-05 01:24:57 -04:00
clv := lv .( * _DID_5_list )
x . Paths = * clv . list
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.DID" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.DID does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.DID.paths" :
if x . Paths == nil {
x . Paths = [] string {}
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
value := & _DID_5_list { list : & x . Paths }
2024-08-10 17:19:59 -04:00
return protoreflect . ValueOfList ( value )
2024-09-05 01:24:57 -04:00
case "did.v1.DID.method" :
panic ( fmt . Errorf ( "field method of message did.v1.DID is not mutable" ))
case "did.v1.DID.network" :
panic ( fmt . Errorf ( "field network of message did.v1.DID is not mutable" ))
case "did.v1.DID.subject" :
panic ( fmt . Errorf ( "field subject of message did.v1.DID is not mutable" ))
case "did.v1.DID.identifier" :
panic ( fmt . Errorf ( "field identifier of message did.v1.DID is not mutable" ))
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.DID" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.DID does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.DID.method" :
return protoreflect . ValueOfEnum ( 0 )
case "did.v1.DID.network" :
2024-08-10 17:19:59 -04:00
return protoreflect . ValueOfString ( "" )
2024-09-05 01:24:57 -04:00
case "did.v1.DID.subject" :
return protoreflect . ValueOfString ( "" )
case "did.v1.DID.identifier" :
return protoreflect . ValueOfString ( "" )
case "did.v1.DID.paths" :
2024-08-10 17:19:59 -04:00
list := [] string {}
2024-09-05 01:24:57 -04:00
return protoreflect . ValueOfList ( & _DID_5_list { list : & list })
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.DID" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.DID does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
2024-08-10 17:19:59 -04:00
switch d . FullName () {
default :
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.DID" , d . FullName ()))
2024-08-10 17:19:59 -04:00
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) GetUnknown () protoreflect . RawFields {
2024-08-10 17:19:59 -04:00
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) SetUnknown ( fields protoreflect . RawFields ) {
2024-08-10 17:19:59 -04:00
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) IsValid () bool {
2024-08-10 17:19:59 -04:00
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_DID ) ProtoMethods () * protoiface . Methods {
2024-08-10 17:19:59 -04:00
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * DID )
2024-08-10 17:19:59 -04:00
if x == nil {
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
}
}
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
2024-09-05 01:24:57 -04:00
if x . Method != 0 {
n += 1 + runtime . Sov ( uint64 ( x . Method ))
}
l = len ( x . Network )
2024-08-10 17:19:59 -04:00
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
2024-09-05 01:24:57 -04:00
l = len ( x . Subject )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
l = len ( x . Identifier )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
if len ( x . Paths ) > 0 {
for _ , s := range x . Paths {
2024-08-10 17:19:59 -04:00
l = len ( s )
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
}
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * DID )
2024-08-10 17:19:59 -04:00
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
}
2024-09-05 01:24:57 -04:00
if len ( x . Paths ) > 0 {
for iNdEx := len ( x . Paths ) - 1 ; iNdEx >= 0 ; iNdEx -- {
i -= len ( x . Paths [ iNdEx ])
copy ( dAtA [ i :], x . Paths [ iNdEx ])
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Paths [ iNdEx ])))
2024-08-10 17:19:59 -04:00
i --
2024-09-05 01:24:57 -04:00
dAtA [ i ] = 0x2a
2024-08-10 17:19:59 -04:00
}
}
2024-09-05 01:24:57 -04:00
if len ( x . Identifier ) > 0 {
i -= len ( x . Identifier )
copy ( dAtA [ i :], x . Identifier )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Identifier )))
i --
dAtA [ i ] = 0x22
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
if len ( x . Subject ) > 0 {
i -= len ( x . Subject )
copy ( dAtA [ i :], x . Subject )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Subject )))
i --
dAtA [ i ] = 0x1a
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
if len ( x . Network ) > 0 {
i -= len ( x . Network )
copy ( dAtA [ i :], x . Network )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Network )))
i --
dAtA [ i ] = 0x12
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
if x . Method != 0 {
i = runtime . EncodeVarint ( dAtA , i , uint64 ( x . Method ))
2024-08-10 17:19:59 -04:00
i --
2024-09-05 01:24:57 -04:00
dAtA [ i ] = 0x8
2024-08-10 17:19:59 -04:00
}
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * DID )
2024-08-10 17:19:59 -04:00
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: DID: wiretype end group for non-group" )
2024-08-10 17:19:59 -04:00
}
if fieldNum <= 0 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: DID: illegal tag %d (wire type %d)" , fieldNum , wire )
2024-08-10 17:19:59 -04:00
}
switch fieldNum {
case 1 :
2024-09-05 01:24:57 -04:00
if wireType != 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Method" , wireType )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
x . Method = 0
2024-08-10 17:19:59 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-09-05 01:24:57 -04:00
x . Method |= DIDNamespace ( b & 0x7F ) << shift
2024-08-10 17:19:59 -04:00
if b < 0x80 {
break
}
}
case 2 :
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Network" , wireType )
2024-08-10 17:19:59 -04:00
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
x . Network = string ( dAtA [ iNdEx : postIndex ])
2024-08-10 17:19:59 -04:00
iNdEx = postIndex
2024-09-05 01:24:57 -04:00
case 3 :
2024-08-10 17:19:59 -04:00
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Subject" , wireType )
2024-08-10 17:19:59 -04:00
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
x . Subject = string ( dAtA [ iNdEx : postIndex ])
2024-08-10 17:19:59 -04:00
iNdEx = postIndex
2024-09-05 01:24:57 -04:00
case 4 :
2024-08-10 17:19:59 -04:00
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Identifier" , wireType )
2024-08-10 17:19:59 -04:00
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
x . Identifier = string ( dAtA [ iNdEx : postIndex ])
2024-08-10 17:19:59 -04:00
iNdEx = postIndex
2024-09-05 01:24:57 -04:00
case 5 :
2024-08-10 17:19:59 -04:00
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Paths" , wireType )
2024-08-10 17:19:59 -04:00
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
x . Paths = append ( x . Paths , string ( dAtA [ iNdEx : postIndex ]))
2024-08-10 17:19:59 -04:00
iNdEx = postIndex
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
}
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . List = ( * _Document_2_list )( nil )
2024-08-31 12:49:44 -04:00
2024-09-05 01:24:57 -04:00
type _Document_2_list struct {
list * [] * VerificationMethod
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_2_list ) Len () int {
if x . list == nil {
2024-08-31 12:49:44 -04:00
return 0
}
2024-09-05 01:24:57 -04:00
return len ( * x . list )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_2_list ) Get ( i int ) protoreflect . Value {
return protoreflect . ValueOfMessage (( * x . list )[ i ]. ProtoReflect ())
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_2_list ) Set ( i int , value protoreflect . Value ) {
valueUnwrapped := value . Message ()
concreteValue := valueUnwrapped . Interface ().( * VerificationMethod )
( * x . list )[ i ] = concreteValue
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_2_list ) Append ( value protoreflect . Value ) {
valueUnwrapped := value . Message ()
concreteValue := valueUnwrapped . Interface ().( * VerificationMethod )
* x . list = append ( * x . list , concreteValue )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_2_list ) AppendMutable () protoreflect . Value {
v := new ( VerificationMethod )
* x . list = append ( * x . list , v )
return protoreflect . ValueOfMessage ( v . ProtoReflect ())
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_2_list ) Truncate ( n int ) {
for i := n ; i < len ( * x . list ); i ++ {
( * x . list )[ i ] = nil
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
* x . list = ( * x . list )[: n ]
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_2_list ) NewElement () protoreflect . Value {
v := new ( VerificationMethod )
return protoreflect . ValueOfMessage ( v . ProtoReflect ())
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_2_list ) IsValid () bool {
return x . list != nil
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . List = ( * _Document_4_list )( nil )
2024-08-31 12:49:44 -04:00
2024-09-05 01:24:57 -04:00
type _Document_4_list struct {
list * [] string
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_4_list ) Len () int {
if x . list == nil {
2024-08-31 12:49:44 -04:00
return 0
}
2024-09-05 01:24:57 -04:00
return len ( * x . list )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_4_list ) Get ( i int ) protoreflect . Value {
return protoreflect . ValueOfString (( * x . list )[ i ])
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_4_list ) Set ( i int , value protoreflect . Value ) {
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
( * x . list )[ i ] = concreteValue
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_4_list ) Append ( value protoreflect . Value ) {
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
* x . list = append ( * x . list , concreteValue )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_4_list ) AppendMutable () protoreflect . Value {
panic ( fmt . Errorf ( "AppendMutable can not be called on message Document at list field Authentication as it is not of Message kind" ))
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_4_list ) Truncate ( n int ) {
* x . list = ( * x . list )[: n ]
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_4_list ) NewElement () protoreflect . Value {
v := ""
return protoreflect . ValueOfString ( v )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_4_list ) IsValid () bool {
return x . list != nil
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . List = ( * _Document_5_list )( nil )
type _Document_5_list struct {
list * [] string
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_5_list ) Len () int {
if x . list == nil {
return 0
}
return len ( * x . list )
}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
func ( x * _Document_5_list ) Get ( i int ) protoreflect . Value {
return protoreflect . ValueOfString (( * x . list )[ i ])
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_5_list ) Set ( i int , value protoreflect . Value ) {
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
( * x . list )[ i ] = concreteValue
}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
func ( x * _Document_5_list ) Append ( value protoreflect . Value ) {
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
* x . list = append ( * x . list , concreteValue )
}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
func ( x * _Document_5_list ) AppendMutable () protoreflect . Value {
panic ( fmt . Errorf ( "AppendMutable can not be called on message Document at list field AssertionMethod as it is not of Message kind" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_5_list ) Truncate ( n int ) {
* x . list = ( * x . list )[: n ]
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_5_list ) NewElement () protoreflect . Value {
v := ""
return protoreflect . ValueOfString ( v )
}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
func ( x * _Document_5_list ) IsValid () bool {
return x . list != nil
}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
var _ protoreflect . List = ( * _Document_7_list )( nil )
type _Document_7_list struct {
list * [] string
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_7_list ) Len () int {
if x . list == nil {
return 0
}
return len ( * x . list )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_7_list ) Get ( i int ) protoreflect . Value {
return protoreflect . ValueOfString (( * x . list )[ i ])
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_7_list ) Set ( i int , value protoreflect . Value ) {
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
( * x . list )[ i ] = concreteValue
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_7_list ) Append ( value protoreflect . Value ) {
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
* x . list = append ( * x . list , concreteValue )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_7_list ) AppendMutable () protoreflect . Value {
panic ( fmt . Errorf ( "AppendMutable can not be called on message Document at list field CapabilityDelegation as it is not of Message kind" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_7_list ) Truncate ( n int ) {
* x . list = ( * x . list )[: n ]
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_7_list ) NewElement () protoreflect . Value {
v := ""
return protoreflect . ValueOfString ( v )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_7_list ) IsValid () bool {
return x . list != nil
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . List = ( * _Document_8_list )( nil )
type _Document_8_list struct {
list * [] string
}
func ( x * _Document_8_list ) Len () int {
if x . list == nil {
return 0
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
return len ( * x . list )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _Document_8_list ) Get ( i int ) protoreflect . Value {
return protoreflect . ValueOfString (( * x . list )[ i ])
}
func ( x * _Document_8_list ) Set ( i int , value protoreflect . Value ) {
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
( * x . list )[ i ] = concreteValue
}
func ( x * _Document_8_list ) Append ( value protoreflect . Value ) {
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
* x . list = append ( * x . list , concreteValue )
}
func ( x * _Document_8_list ) AppendMutable () protoreflect . Value {
panic ( fmt . Errorf ( "AppendMutable can not be called on message Document at list field CapabilityInvocation as it is not of Message kind" ))
}
func ( x * _Document_8_list ) Truncate ( n int ) {
* x . list = ( * x . list )[: n ]
}
func ( x * _Document_8_list ) NewElement () protoreflect . Value {
v := ""
return protoreflect . ValueOfString ( v )
}
func ( x * _Document_8_list ) IsValid () bool {
return x . list != nil
}
var _ protoreflect . List = ( * _Document_9_list )( nil )
type _Document_9_list struct {
list * [] string
}
func ( x * _Document_9_list ) Len () int {
if x . list == nil {
return 0
}
return len ( * x . list )
}
func ( x * _Document_9_list ) Get ( i int ) protoreflect . Value {
return protoreflect . ValueOfString (( * x . list )[ i ])
}
func ( x * _Document_9_list ) Set ( i int , value protoreflect . Value ) {
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
( * x . list )[ i ] = concreteValue
}
func ( x * _Document_9_list ) Append ( value protoreflect . Value ) {
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
* x . list = append ( * x . list , concreteValue )
}
func ( x * _Document_9_list ) AppendMutable () protoreflect . Value {
panic ( fmt . Errorf ( "AppendMutable can not be called on message Document at list field Service as it is not of Message kind" ))
}
func ( x * _Document_9_list ) Truncate ( n int ) {
* x . list = ( * x . list )[: n ]
}
func ( x * _Document_9_list ) NewElement () protoreflect . Value {
v := ""
return protoreflect . ValueOfString ( v )
}
func ( x * _Document_9_list ) IsValid () bool {
return x . list != nil
}
var (
md_Document protoreflect . MessageDescriptor
fd_Document_id protoreflect . FieldDescriptor
fd_Document_verification_methods protoreflect . FieldDescriptor
fd_Document_authentication protoreflect . FieldDescriptor
fd_Document_assertion_method protoreflect . FieldDescriptor
fd_Document_capability_delegation protoreflect . FieldDescriptor
fd_Document_capability_invocation protoreflect . FieldDescriptor
fd_Document_service protoreflect . FieldDescriptor
)
func init () {
file_did_v1_models_proto_init ()
md_Document = File_did_v1_models_proto . Messages (). ByName ( "Document" )
fd_Document_id = md_Document . Fields (). ByName ( "id" )
fd_Document_verification_methods = md_Document . Fields (). ByName ( "verification_methods" )
fd_Document_authentication = md_Document . Fields (). ByName ( "authentication" )
fd_Document_assertion_method = md_Document . Fields (). ByName ( "assertion_method" )
fd_Document_capability_delegation = md_Document . Fields (). ByName ( "capability_delegation" )
fd_Document_capability_invocation = md_Document . Fields (). ByName ( "capability_invocation" )
fd_Document_service = md_Document . Fields (). ByName ( "service" )
}
var _ protoreflect . Message = ( * fastReflection_Document )( nil )
type fastReflection_Document Document
func ( x * Document ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_Document )( x )
}
func ( x * Document ) slowProtoReflect () protoreflect . Message {
mi := & file_did_v1_models_proto_msgTypes [ 3 ]
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
var _fastReflection_Document_messageType fastReflection_Document_messageType
var _ protoreflect . MessageType = fastReflection_Document_messageType {}
type fastReflection_Document_messageType struct {}
func ( x fastReflection_Document_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_Document )( nil )
}
func ( x fastReflection_Document_messageType ) New () protoreflect . Message {
return new ( fastReflection_Document )
}
func ( x fastReflection_Document_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_Document
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func ( x * fastReflection_Document ) Descriptor () protoreflect . MessageDescriptor {
return md_Document
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func ( x * fastReflection_Document ) Type () protoreflect . MessageType {
return _fastReflection_Document_messageType
}
// New returns a newly allocated and mutable empty message.
func ( x * fastReflection_Document ) New () protoreflect . Message {
return new ( fastReflection_Document )
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func ( x * fastReflection_Document ) Interface () protoreflect . ProtoMessage {
return ( * Document )( x )
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func ( x * fastReflection_Document ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
if x . Id != "" {
value := protoreflect . ValueOfString ( x . Id )
if ! f ( fd_Document_id , value ) {
return
}
}
if len ( x . VerificationMethods ) != 0 {
value := protoreflect . ValueOfList ( & _Document_2_list { list : & x . VerificationMethods })
if ! f ( fd_Document_verification_methods , value ) {
return
}
}
if len ( x . Authentication ) != 0 {
value := protoreflect . ValueOfList ( & _Document_4_list { list : & x . Authentication })
if ! f ( fd_Document_authentication , value ) {
return
}
}
if len ( x . AssertionMethod ) != 0 {
value := protoreflect . ValueOfList ( & _Document_5_list { list : & x . AssertionMethod })
if ! f ( fd_Document_assertion_method , value ) {
return
}
}
if len ( x . CapabilityDelegation ) != 0 {
value := protoreflect . ValueOfList ( & _Document_7_list { list : & x . CapabilityDelegation })
if ! f ( fd_Document_capability_delegation , value ) {
return
}
}
if len ( x . CapabilityInvocation ) != 0 {
value := protoreflect . ValueOfList ( & _Document_8_list { list : & x . CapabilityInvocation })
if ! f ( fd_Document_capability_invocation , value ) {
return
}
}
if len ( x . Service ) != 0 {
value := protoreflect . ValueOfList ( & _Document_9_list { list : & x . Service })
if ! f ( fd_Document_service , value ) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func ( x * fastReflection_Document ) Has ( fd protoreflect . FieldDescriptor ) bool {
switch fd . FullName () {
case "did.v1.Document.id" :
return x . Id != ""
case "did.v1.Document.verification_methods" :
return len ( x . VerificationMethods ) != 0
case "did.v1.Document.authentication" :
return len ( x . Authentication ) != 0
case "did.v1.Document.assertion_method" :
return len ( x . AssertionMethod ) != 0
case "did.v1.Document.capability_delegation" :
return len ( x . CapabilityDelegation ) != 0
case "did.v1.Document.capability_invocation" :
return len ( x . CapabilityInvocation ) != 0
case "did.v1.Document.service" :
return len ( x . Service ) != 0
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Document" ))
}
panic ( fmt . Errorf ( "message did.v1.Document does not contain field %s" , fd . FullName ()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Document ) Clear ( fd protoreflect . FieldDescriptor ) {
switch fd . FullName () {
case "did.v1.Document.id" :
x . Id = ""
case "did.v1.Document.verification_methods" :
x . VerificationMethods = nil
case "did.v1.Document.authentication" :
x . Authentication = nil
case "did.v1.Document.assertion_method" :
x . AssertionMethod = nil
case "did.v1.Document.capability_delegation" :
x . CapabilityDelegation = nil
case "did.v1.Document.capability_invocation" :
x . CapabilityInvocation = nil
case "did.v1.Document.service" :
x . Service = nil
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Document" ))
}
panic ( fmt . Errorf ( "message did.v1.Document does not contain field %s" , fd . FullName ()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func ( x * fastReflection_Document ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
switch descriptor . FullName () {
case "did.v1.Document.id" :
value := x . Id
return protoreflect . ValueOfString ( value )
case "did.v1.Document.verification_methods" :
if len ( x . VerificationMethods ) == 0 {
return protoreflect . ValueOfList ( & _Document_2_list {})
}
listValue := & _Document_2_list { list : & x . VerificationMethods }
return protoreflect . ValueOfList ( listValue )
case "did.v1.Document.authentication" :
if len ( x . Authentication ) == 0 {
return protoreflect . ValueOfList ( & _Document_4_list {})
}
listValue := & _Document_4_list { list : & x . Authentication }
return protoreflect . ValueOfList ( listValue )
case "did.v1.Document.assertion_method" :
if len ( x . AssertionMethod ) == 0 {
return protoreflect . ValueOfList ( & _Document_5_list {})
}
listValue := & _Document_5_list { list : & x . AssertionMethod }
return protoreflect . ValueOfList ( listValue )
case "did.v1.Document.capability_delegation" :
if len ( x . CapabilityDelegation ) == 0 {
return protoreflect . ValueOfList ( & _Document_7_list {})
}
listValue := & _Document_7_list { list : & x . CapabilityDelegation }
return protoreflect . ValueOfList ( listValue )
case "did.v1.Document.capability_invocation" :
if len ( x . CapabilityInvocation ) == 0 {
return protoreflect . ValueOfList ( & _Document_8_list {})
}
listValue := & _Document_8_list { list : & x . CapabilityInvocation }
return protoreflect . ValueOfList ( listValue )
case "did.v1.Document.service" :
if len ( x . Service ) == 0 {
return protoreflect . ValueOfList ( & _Document_9_list {})
}
listValue := & _Document_9_list { list : & x . Service }
return protoreflect . ValueOfList ( listValue )
default :
if descriptor . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Document" ))
}
panic ( fmt . Errorf ( "message did.v1.Document does not contain field %s" , descriptor . FullName ()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Document ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
switch fd . FullName () {
case "did.v1.Document.id" :
x . Id = value . Interface ().( string )
case "did.v1.Document.verification_methods" :
lv := value . List ()
clv := lv .( * _Document_2_list )
x . VerificationMethods = * clv . list
case "did.v1.Document.authentication" :
lv := value . List ()
clv := lv .( * _Document_4_list )
x . Authentication = * clv . list
case "did.v1.Document.assertion_method" :
lv := value . List ()
clv := lv .( * _Document_5_list )
x . AssertionMethod = * clv . list
case "did.v1.Document.capability_delegation" :
lv := value . List ()
clv := lv .( * _Document_7_list )
x . CapabilityDelegation = * clv . list
case "did.v1.Document.capability_invocation" :
lv := value . List ()
clv := lv .( * _Document_8_list )
x . CapabilityInvocation = * clv . list
case "did.v1.Document.service" :
lv := value . List ()
clv := lv .( * _Document_9_list )
x . Service = * clv . list
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Document" ))
}
panic ( fmt . Errorf ( "message did.v1.Document does not contain field %s" , fd . FullName ()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Document ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
switch fd . FullName () {
case "did.v1.Document.verification_methods" :
if x . VerificationMethods == nil {
x . VerificationMethods = [] * VerificationMethod {}
}
value := & _Document_2_list { list : & x . VerificationMethods }
return protoreflect . ValueOfList ( value )
case "did.v1.Document.authentication" :
if x . Authentication == nil {
x . Authentication = [] string {}
}
value := & _Document_4_list { list : & x . Authentication }
return protoreflect . ValueOfList ( value )
case "did.v1.Document.assertion_method" :
if x . AssertionMethod == nil {
x . AssertionMethod = [] string {}
}
value := & _Document_5_list { list : & x . AssertionMethod }
return protoreflect . ValueOfList ( value )
case "did.v1.Document.capability_delegation" :
if x . CapabilityDelegation == nil {
x . CapabilityDelegation = [] string {}
}
value := & _Document_7_list { list : & x . CapabilityDelegation }
return protoreflect . ValueOfList ( value )
case "did.v1.Document.capability_invocation" :
if x . CapabilityInvocation == nil {
x . CapabilityInvocation = [] string {}
}
value := & _Document_8_list { list : & x . CapabilityInvocation }
return protoreflect . ValueOfList ( value )
case "did.v1.Document.service" :
if x . Service == nil {
x . Service = [] string {}
}
value := & _Document_9_list { list : & x . Service }
return protoreflect . ValueOfList ( value )
case "did.v1.Document.id" :
panic ( fmt . Errorf ( "field id of message did.v1.Document is not mutable" ))
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Document" ))
}
panic ( fmt . Errorf ( "message did.v1.Document does not contain field %s" , fd . FullName ()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func ( x * fastReflection_Document ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
switch fd . FullName () {
case "did.v1.Document.id" :
return protoreflect . ValueOfString ( "" )
case "did.v1.Document.verification_methods" :
list := [] * VerificationMethod {}
return protoreflect . ValueOfList ( & _Document_2_list { list : & list })
case "did.v1.Document.authentication" :
list := [] string {}
return protoreflect . ValueOfList ( & _Document_4_list { list : & list })
case "did.v1.Document.assertion_method" :
list := [] string {}
return protoreflect . ValueOfList ( & _Document_5_list { list : & list })
case "did.v1.Document.capability_delegation" :
list := [] string {}
return protoreflect . ValueOfList ( & _Document_7_list { list : & list })
case "did.v1.Document.capability_invocation" :
list := [] string {}
return protoreflect . ValueOfList ( & _Document_8_list { list : & list })
case "did.v1.Document.service" :
list := [] string {}
return protoreflect . ValueOfList ( & _Document_9_list { list : & list })
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Document" ))
}
panic ( fmt . Errorf ( "message did.v1.Document does not contain field %s" , fd . FullName ()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func ( x * fastReflection_Document ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
switch d . FullName () {
default :
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.Document" , d . FullName ()))
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func ( x * fastReflection_Document ) GetUnknown () protoreflect . RawFields {
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Document ) SetUnknown ( fields protoreflect . RawFields ) {
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func ( x * fastReflection_Document ) IsValid () bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func ( x * fastReflection_Document ) ProtoMethods () * protoiface . Methods {
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
x := input . Message . Interface ().( * Document )
if x == nil {
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
}
}
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
l = len ( x . Id )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
if len ( x . VerificationMethods ) > 0 {
for _ , e := range x . VerificationMethods {
l = options . Size ( e )
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
}
if len ( x . Authentication ) > 0 {
for _ , s := range x . Authentication {
l = len ( s )
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
}
if len ( x . AssertionMethod ) > 0 {
for _ , s := range x . AssertionMethod {
l = len ( s )
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
}
if len ( x . CapabilityDelegation ) > 0 {
for _ , s := range x . CapabilityDelegation {
l = len ( s )
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
}
if len ( x . CapabilityInvocation ) > 0 {
for _ , s := range x . CapabilityInvocation {
l = len ( s )
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
}
if len ( x . Service ) > 0 {
for _ , s := range x . Service {
l = len ( s )
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
}
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
x := input . Message . Interface ().( * Document )
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
}
if len ( x . Service ) > 0 {
for iNdEx := len ( x . Service ) - 1 ; iNdEx >= 0 ; iNdEx -- {
i -= len ( x . Service [ iNdEx ])
copy ( dAtA [ i :], x . Service [ iNdEx ])
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Service [ iNdEx ])))
i --
dAtA [ i ] = 0x4a
}
}
if len ( x . CapabilityInvocation ) > 0 {
for iNdEx := len ( x . CapabilityInvocation ) - 1 ; iNdEx >= 0 ; iNdEx -- {
i -= len ( x . CapabilityInvocation [ iNdEx ])
copy ( dAtA [ i :], x . CapabilityInvocation [ iNdEx ])
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . CapabilityInvocation [ iNdEx ])))
i --
dAtA [ i ] = 0x42
}
}
if len ( x . CapabilityDelegation ) > 0 {
for iNdEx := len ( x . CapabilityDelegation ) - 1 ; iNdEx >= 0 ; iNdEx -- {
i -= len ( x . CapabilityDelegation [ iNdEx ])
copy ( dAtA [ i :], x . CapabilityDelegation [ iNdEx ])
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . CapabilityDelegation [ iNdEx ])))
i --
dAtA [ i ] = 0x3a
}
}
if len ( x . AssertionMethod ) > 0 {
for iNdEx := len ( x . AssertionMethod ) - 1 ; iNdEx >= 0 ; iNdEx -- {
i -= len ( x . AssertionMethod [ iNdEx ])
copy ( dAtA [ i :], x . AssertionMethod [ iNdEx ])
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . AssertionMethod [ iNdEx ])))
i --
dAtA [ i ] = 0x2a
}
}
if len ( x . Authentication ) > 0 {
for iNdEx := len ( x . Authentication ) - 1 ; iNdEx >= 0 ; iNdEx -- {
i -= len ( x . Authentication [ iNdEx ])
copy ( dAtA [ i :], x . Authentication [ iNdEx ])
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Authentication [ iNdEx ])))
i --
dAtA [ i ] = 0x22
}
}
if len ( x . VerificationMethods ) > 0 {
for iNdEx := len ( x . VerificationMethods ) - 1 ; iNdEx >= 0 ; iNdEx -- {
encoded , err := options . Marshal ( x . VerificationMethods [ iNdEx ])
if err != nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, err
}
i -= len ( encoded )
copy ( dAtA [ i :], encoded )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( encoded )))
i --
dAtA [ i ] = 0x12
}
}
if len ( x . Id ) > 0 {
i -= len ( x . Id )
copy ( dAtA [ i :], x . Id )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Id )))
i --
dAtA [ i ] = 0xa
}
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
x := input . Message . Interface ().( * Document )
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Document: wiretype end group for non-group" )
}
if fieldNum <= 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Document: illegal tag %d (wire type %d)" , fieldNum , wire )
}
switch fieldNum {
case 1 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Id" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Id = string ( dAtA [ iNdEx : postIndex ])
iNdEx = postIndex
case 2 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field VerificationMethods" , wireType )
}
var msglen int
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
msglen |= int ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . VerificationMethods = append ( x . VerificationMethods , & VerificationMethod {})
if err := options . Unmarshal ( dAtA [ iNdEx : postIndex ], x . VerificationMethods [ len ( x . VerificationMethods ) - 1 ]); err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
iNdEx = postIndex
case 4 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Authentication" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Authentication = append ( x . Authentication , string ( dAtA [ iNdEx : postIndex ]))
iNdEx = postIndex
case 5 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field AssertionMethod" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . AssertionMethod = append ( x . AssertionMethod , string ( dAtA [ iNdEx : postIndex ]))
iNdEx = postIndex
case 7 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field CapabilityDelegation" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . CapabilityDelegation = append ( x . CapabilityDelegation , string ( dAtA [ iNdEx : postIndex ]))
iNdEx = postIndex
case 8 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field CapabilityInvocation" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . CapabilityInvocation = append ( x . CapabilityInvocation , string ( dAtA [ iNdEx : postIndex ]))
iNdEx = postIndex
case 9 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Service" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Service = append ( x . Service , string ( dAtA [ iNdEx : postIndex ]))
iNdEx = postIndex
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
}
}
var _ protoreflect . Map = ( * _Metadata_2_map )( nil )
type _Metadata_2_map struct {
m * map [ string ] string
}
func ( x * _Metadata_2_map ) Len () int {
if x . m == nil {
return 0
}
return len ( * x . m )
}
func ( x * _Metadata_2_map ) Range ( f func ( protoreflect . MapKey , protoreflect . Value ) bool ) {
if x . m == nil {
return
}
for k , v := range * x . m {
mapKey := ( protoreflect . MapKey )( protoreflect . ValueOfString ( k ))
mapValue := protoreflect . ValueOfString ( v )
if ! f ( mapKey , mapValue ) {
break
}
}
}
func ( x * _Metadata_2_map ) Has ( key protoreflect . MapKey ) bool {
if x . m == nil {
return false
}
keyUnwrapped := key . String ()
concreteValue := keyUnwrapped
_ , ok := ( * x . m )[ concreteValue ]
return ok
}
func ( x * _Metadata_2_map ) Clear ( key protoreflect . MapKey ) {
if x . m == nil {
return
}
keyUnwrapped := key . String ()
concreteKey := keyUnwrapped
delete ( * x . m , concreteKey )
}
func ( x * _Metadata_2_map ) Get ( key protoreflect . MapKey ) protoreflect . Value {
if x . m == nil {
return protoreflect . Value {}
}
keyUnwrapped := key . String ()
concreteKey := keyUnwrapped
v , ok := ( * x . m )[ concreteKey ]
if ! ok {
return protoreflect . Value {}
}
return protoreflect . ValueOfString ( v )
}
func ( x * _Metadata_2_map ) Set ( key protoreflect . MapKey , value protoreflect . Value ) {
if ! key . IsValid () || ! value . IsValid () {
panic ( "invalid key or value provided" )
}
keyUnwrapped := key . String ()
concreteKey := keyUnwrapped
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
( * x . m )[ concreteKey ] = concreteValue
}
func ( x * _Metadata_2_map ) Mutable ( key protoreflect . MapKey ) protoreflect . Value {
panic ( "should not call Mutable on protoreflect.Map whose value is not of type protoreflect.Message" )
}
func ( x * _Metadata_2_map ) NewValue () protoreflect . Value {
v := ""
return protoreflect . ValueOfString ( v )
}
func ( x * _Metadata_2_map ) IsValid () bool {
return x . m != nil
}
var _ protoreflect . Map = ( * _Metadata_3_map )( nil )
type _Metadata_3_map struct {
m * map [ string ] * Property
}
func ( x * _Metadata_3_map ) Len () int {
if x . m == nil {
return 0
}
return len ( * x . m )
}
func ( x * _Metadata_3_map ) Range ( f func ( protoreflect . MapKey , protoreflect . Value ) bool ) {
if x . m == nil {
return
}
for k , v := range * x . m {
mapKey := ( protoreflect . MapKey )( protoreflect . ValueOfString ( k ))
mapValue := protoreflect . ValueOfMessage ( v . ProtoReflect ())
if ! f ( mapKey , mapValue ) {
break
}
}
}
func ( x * _Metadata_3_map ) Has ( key protoreflect . MapKey ) bool {
if x . m == nil {
return false
}
keyUnwrapped := key . String ()
concreteValue := keyUnwrapped
_ , ok := ( * x . m )[ concreteValue ]
return ok
}
func ( x * _Metadata_3_map ) Clear ( key protoreflect . MapKey ) {
if x . m == nil {
return
}
keyUnwrapped := key . String ()
concreteKey := keyUnwrapped
delete ( * x . m , concreteKey )
}
func ( x * _Metadata_3_map ) Get ( key protoreflect . MapKey ) protoreflect . Value {
if x . m == nil {
return protoreflect . Value {}
}
keyUnwrapped := key . String ()
concreteKey := keyUnwrapped
v , ok := ( * x . m )[ concreteKey ]
if ! ok {
return protoreflect . Value {}
}
return protoreflect . ValueOfMessage ( v . ProtoReflect ())
}
func ( x * _Metadata_3_map ) Set ( key protoreflect . MapKey , value protoreflect . Value ) {
if ! key . IsValid () || ! value . IsValid () {
panic ( "invalid key or value provided" )
}
keyUnwrapped := key . String ()
concreteKey := keyUnwrapped
valueUnwrapped := value . Message ()
concreteValue := valueUnwrapped . Interface ().( * Property )
( * x . m )[ concreteKey ] = concreteValue
}
func ( x * _Metadata_3_map ) Mutable ( key protoreflect . MapKey ) protoreflect . Value {
keyUnwrapped := key . String ()
concreteKey := keyUnwrapped
v , ok := ( * x . m )[ concreteKey ]
if ok {
return protoreflect . ValueOfMessage ( v . ProtoReflect ())
}
newValue := new ( Property )
( * x . m )[ concreteKey ] = newValue
return protoreflect . ValueOfMessage ( newValue . ProtoReflect ())
}
func ( x * _Metadata_3_map ) NewValue () protoreflect . Value {
v := new ( Property )
return protoreflect . ValueOfMessage ( v . ProtoReflect ())
}
func ( x * _Metadata_3_map ) IsValid () bool {
return x . m != nil
}
var (
md_Metadata protoreflect . MessageDescriptor
fd_Metadata_origin_uri protoreflect . FieldDescriptor
fd_Metadata_public protoreflect . FieldDescriptor
fd_Metadata_private protoreflect . FieldDescriptor
)
func init () {
file_did_v1_models_proto_init ()
md_Metadata = File_did_v1_models_proto . Messages (). ByName ( "Metadata" )
fd_Metadata_origin_uri = md_Metadata . Fields (). ByName ( "origin_uri" )
fd_Metadata_public = md_Metadata . Fields (). ByName ( "public" )
fd_Metadata_private = md_Metadata . Fields (). ByName ( "private" )
}
var _ protoreflect . Message = ( * fastReflection_Metadata )( nil )
type fastReflection_Metadata Metadata
func ( x * Metadata ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_Metadata )( x )
}
func ( x * Metadata ) slowProtoReflect () protoreflect . Message {
mi := & file_did_v1_models_proto_msgTypes [ 4 ]
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
var _fastReflection_Metadata_messageType fastReflection_Metadata_messageType
var _ protoreflect . MessageType = fastReflection_Metadata_messageType {}
type fastReflection_Metadata_messageType struct {}
func ( x fastReflection_Metadata_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_Metadata )( nil )
}
func ( x fastReflection_Metadata_messageType ) New () protoreflect . Message {
return new ( fastReflection_Metadata )
}
func ( x fastReflection_Metadata_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_Metadata
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func ( x * fastReflection_Metadata ) Descriptor () protoreflect . MessageDescriptor {
return md_Metadata
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func ( x * fastReflection_Metadata ) Type () protoreflect . MessageType {
return _fastReflection_Metadata_messageType
}
// New returns a newly allocated and mutable empty message.
func ( x * fastReflection_Metadata ) New () protoreflect . Message {
return new ( fastReflection_Metadata )
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func ( x * fastReflection_Metadata ) Interface () protoreflect . ProtoMessage {
return ( * Metadata )( x )
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func ( x * fastReflection_Metadata ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
if x . OriginUri != "" {
value := protoreflect . ValueOfString ( x . OriginUri )
if ! f ( fd_Metadata_origin_uri , value ) {
return
}
}
if len ( x . Public ) != 0 {
value := protoreflect . ValueOfMap ( & _Metadata_2_map { m : & x . Public })
if ! f ( fd_Metadata_public , value ) {
return
}
}
if len ( x . Private ) != 0 {
value := protoreflect . ValueOfMap ( & _Metadata_3_map { m : & x . Private })
if ! f ( fd_Metadata_private , value ) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func ( x * fastReflection_Metadata ) Has ( fd protoreflect . FieldDescriptor ) bool {
switch fd . FullName () {
case "did.v1.Metadata.origin_uri" :
return x . OriginUri != ""
case "did.v1.Metadata.public" :
return len ( x . Public ) != 0
case "did.v1.Metadata.private" :
return len ( x . Private ) != 0
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Metadata" ))
}
panic ( fmt . Errorf ( "message did.v1.Metadata does not contain field %s" , fd . FullName ()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Metadata ) Clear ( fd protoreflect . FieldDescriptor ) {
switch fd . FullName () {
case "did.v1.Metadata.origin_uri" :
x . OriginUri = ""
case "did.v1.Metadata.public" :
x . Public = nil
case "did.v1.Metadata.private" :
x . Private = nil
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Metadata" ))
}
panic ( fmt . Errorf ( "message did.v1.Metadata does not contain field %s" , fd . FullName ()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func ( x * fastReflection_Metadata ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
switch descriptor . FullName () {
case "did.v1.Metadata.origin_uri" :
value := x . OriginUri
return protoreflect . ValueOfString ( value )
case "did.v1.Metadata.public" :
if len ( x . Public ) == 0 {
return protoreflect . ValueOfMap ( & _Metadata_2_map {})
}
mapValue := & _Metadata_2_map { m : & x . Public }
return protoreflect . ValueOfMap ( mapValue )
case "did.v1.Metadata.private" :
if len ( x . Private ) == 0 {
return protoreflect . ValueOfMap ( & _Metadata_3_map {})
}
mapValue := & _Metadata_3_map { m : & x . Private }
return protoreflect . ValueOfMap ( mapValue )
default :
if descriptor . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Metadata" ))
}
panic ( fmt . Errorf ( "message did.v1.Metadata does not contain field %s" , descriptor . FullName ()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Metadata ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
switch fd . FullName () {
case "did.v1.Metadata.origin_uri" :
x . OriginUri = value . Interface ().( string )
case "did.v1.Metadata.public" :
mv := value . Map ()
cmv := mv .( * _Metadata_2_map )
x . Public = * cmv . m
case "did.v1.Metadata.private" :
mv := value . Map ()
cmv := mv .( * _Metadata_3_map )
x . Private = * cmv . m
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Metadata" ))
}
panic ( fmt . Errorf ( "message did.v1.Metadata does not contain field %s" , fd . FullName ()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Metadata ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
switch fd . FullName () {
case "did.v1.Metadata.public" :
if x . Public == nil {
x . Public = make ( map [ string ] string )
}
value := & _Metadata_2_map { m : & x . Public }
return protoreflect . ValueOfMap ( value )
case "did.v1.Metadata.private" :
if x . Private == nil {
x . Private = make ( map [ string ] * Property )
}
value := & _Metadata_3_map { m : & x . Private }
return protoreflect . ValueOfMap ( value )
case "did.v1.Metadata.origin_uri" :
panic ( fmt . Errorf ( "field origin_uri of message did.v1.Metadata is not mutable" ))
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Metadata" ))
}
panic ( fmt . Errorf ( "message did.v1.Metadata does not contain field %s" , fd . FullName ()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func ( x * fastReflection_Metadata ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
switch fd . FullName () {
case "did.v1.Metadata.origin_uri" :
return protoreflect . ValueOfString ( "" )
case "did.v1.Metadata.public" :
m := make ( map [ string ] string )
return protoreflect . ValueOfMap ( & _Metadata_2_map { m : & m })
case "did.v1.Metadata.private" :
m := make ( map [ string ] * Property )
return protoreflect . ValueOfMap ( & _Metadata_3_map { m : & m })
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Metadata" ))
}
panic ( fmt . Errorf ( "message did.v1.Metadata does not contain field %s" , fd . FullName ()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func ( x * fastReflection_Metadata ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
switch d . FullName () {
default :
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.Metadata" , d . FullName ()))
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func ( x * fastReflection_Metadata ) GetUnknown () protoreflect . RawFields {
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Metadata ) SetUnknown ( fields protoreflect . RawFields ) {
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func ( x * fastReflection_Metadata ) IsValid () bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func ( x * fastReflection_Metadata ) ProtoMethods () * protoiface . Methods {
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
x := input . Message . Interface ().( * Metadata )
if x == nil {
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
}
}
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
l = len ( x . OriginUri )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
if len ( x . Public ) > 0 {
SiZeMaP := func ( k string , v string ) {
mapEntrySize := 1 + len ( k ) + runtime . Sov ( uint64 ( len ( k ))) + 1 + len ( v ) + runtime . Sov ( uint64 ( len ( v )))
n += mapEntrySize + 1 + runtime . Sov ( uint64 ( mapEntrySize ))
}
if options . Deterministic {
sortme := make ([] string , 0 , len ( x . Public ))
for k := range x . Public {
sortme = append ( sortme , k )
}
sort . Strings ( sortme )
for _ , k := range sortme {
v := x . Public [ k ]
SiZeMaP ( k , v )
}
} else {
for k , v := range x . Public {
SiZeMaP ( k , v )
}
}
}
if len ( x . Private ) > 0 {
SiZeMaP := func ( k string , v * Property ) {
l := 0
if v != nil {
l = options . Size ( v )
}
l += 1 + runtime . Sov ( uint64 ( l ))
mapEntrySize := 1 + len ( k ) + runtime . Sov ( uint64 ( len ( k ))) + l
n += mapEntrySize + 1 + runtime . Sov ( uint64 ( mapEntrySize ))
}
if options . Deterministic {
sortme := make ([] string , 0 , len ( x . Private ))
for k := range x . Private {
sortme = append ( sortme , k )
}
sort . Strings ( sortme )
for _ , k := range sortme {
v := x . Private [ k ]
SiZeMaP ( k , v )
}
} else {
for k , v := range x . Private {
SiZeMaP ( k , v )
}
}
}
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
x := input . Message . Interface ().( * Metadata )
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
}
if len ( x . Private ) > 0 {
MaRsHaLmAp := func ( k string , v * Property ) ( protoiface . MarshalOutput , error ) {
baseI := i
encoded , err := options . Marshal ( v )
if err != nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, err
}
i -= len ( encoded )
copy ( dAtA [ i :], encoded )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( encoded )))
i --
dAtA [ i ] = 0x12
i -= len ( k )
copy ( dAtA [ i :], k )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( k )))
i --
dAtA [ i ] = 0xa
i = runtime . EncodeVarint ( dAtA , i , uint64 ( baseI - i ))
i --
dAtA [ i ] = 0x1a
return protoiface . MarshalOutput {}, nil
}
if options . Deterministic {
keysForPrivate := make ([] string , 0 , len ( x . Private ))
for k := range x . Private {
keysForPrivate = append ( keysForPrivate , string ( k ))
}
sort . Slice ( keysForPrivate , func ( i , j int ) bool {
return keysForPrivate [ i ] < keysForPrivate [ j ]
})
for iNdEx := len ( keysForPrivate ) - 1 ; iNdEx >= 0 ; iNdEx -- {
v := x . Private [ string ( keysForPrivate [ iNdEx ])]
out , err := MaRsHaLmAp ( keysForPrivate [ iNdEx ], v )
if err != nil {
return out , err
}
}
} else {
for k := range x . Private {
v := x . Private [ k ]
out , err := MaRsHaLmAp ( k , v )
if err != nil {
return out , err
}
}
}
}
if len ( x . Public ) > 0 {
MaRsHaLmAp := func ( k string , v string ) ( protoiface . MarshalOutput , error ) {
baseI := i
i -= len ( v )
copy ( dAtA [ i :], v )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( v )))
i --
dAtA [ i ] = 0x12
i -= len ( k )
copy ( dAtA [ i :], k )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( k )))
i --
dAtA [ i ] = 0xa
i = runtime . EncodeVarint ( dAtA , i , uint64 ( baseI - i ))
i --
dAtA [ i ] = 0x12
return protoiface . MarshalOutput {}, nil
}
if options . Deterministic {
keysForPublic := make ([] string , 0 , len ( x . Public ))
for k := range x . Public {
keysForPublic = append ( keysForPublic , string ( k ))
}
sort . Slice ( keysForPublic , func ( i , j int ) bool {
return keysForPublic [ i ] < keysForPublic [ j ]
})
for iNdEx := len ( keysForPublic ) - 1 ; iNdEx >= 0 ; iNdEx -- {
v := x . Public [ string ( keysForPublic [ iNdEx ])]
out , err := MaRsHaLmAp ( keysForPublic [ iNdEx ], v )
if err != nil {
return out , err
}
}
} else {
for k := range x . Public {
v := x . Public [ k ]
out , err := MaRsHaLmAp ( k , v )
if err != nil {
return out , err
}
}
}
}
if len ( x . OriginUri ) > 0 {
i -= len ( x . OriginUri )
copy ( dAtA [ i :], x . OriginUri )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . OriginUri )))
i --
dAtA [ i ] = 0xa
}
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
x := input . Message . Interface ().( * Metadata )
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Metadata: wiretype end group for non-group" )
}
if fieldNum <= 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Metadata: illegal tag %d (wire type %d)" , fieldNum , wire )
}
switch fieldNum {
case 1 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field OriginUri" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . OriginUri = string ( dAtA [ iNdEx : postIndex ])
iNdEx = postIndex
case 2 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Public" , wireType )
}
var msglen int
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
msglen |= int ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if x . Public == nil {
x . Public = make ( map [ string ] string )
}
var mapkey string
var mapvalue string
for iNdEx < postIndex {
entryPreIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
if fieldNum == 1 {
var stringLenmapkey uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLenmapkey |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLenmapkey := int ( stringLenmapkey )
if intStringLenmapkey < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postStringIndexmapkey := iNdEx + intStringLenmapkey
if postStringIndexmapkey < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postStringIndexmapkey > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
mapkey = string ( dAtA [ iNdEx : postStringIndexmapkey ])
iNdEx = postStringIndexmapkey
} else if fieldNum == 2 {
var stringLenmapvalue uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLenmapvalue |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLenmapvalue := int ( stringLenmapvalue )
if intStringLenmapvalue < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postStringIndexmapvalue := iNdEx + intStringLenmapvalue
if postStringIndexmapvalue < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postStringIndexmapvalue > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
mapvalue = string ( dAtA [ iNdEx : postStringIndexmapvalue ])
iNdEx = postStringIndexmapvalue
} else {
iNdEx = entryPreIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > postIndex {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
iNdEx += skippy
}
}
x . Public [ mapkey ] = mapvalue
iNdEx = postIndex
case 3 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Private" , wireType )
}
var msglen int
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
msglen |= int ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if x . Private == nil {
x . Private = make ( map [ string ] * Property )
}
var mapkey string
var mapvalue * Property
for iNdEx < postIndex {
entryPreIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
if fieldNum == 1 {
var stringLenmapkey uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLenmapkey |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLenmapkey := int ( stringLenmapkey )
if intStringLenmapkey < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postStringIndexmapkey := iNdEx + intStringLenmapkey
if postStringIndexmapkey < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postStringIndexmapkey > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
mapkey = string ( dAtA [ iNdEx : postStringIndexmapkey ])
iNdEx = postStringIndexmapkey
} else if fieldNum == 2 {
var mapmsglen int
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
mapmsglen |= int ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
if mapmsglen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postmsgIndex := iNdEx + mapmsglen
if postmsgIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postmsgIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
mapvalue = & Property {}
if err := options . Unmarshal ( dAtA [ iNdEx : postmsgIndex ], mapvalue ); err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
iNdEx = postmsgIndex
} else {
iNdEx = entryPreIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > postIndex {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
iNdEx += skippy
}
}
x . Private [ mapkey ] = mapvalue
iNdEx = postIndex
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
}
}
var _ protoreflect . List = ( * _Permissions_1_list )( nil )
type _Permissions_1_list struct {
list * [] DIDNamespace
}
func ( x * _Permissions_1_list ) Len () int {
if x . list == nil {
return 0
}
return len ( * x . list )
}
func ( x * _Permissions_1_list ) Get ( i int ) protoreflect . Value {
return protoreflect . ValueOfEnum (( protoreflect . EnumNumber )(( * x . list )[ i ]))
}
func ( x * _Permissions_1_list ) Set ( i int , value protoreflect . Value ) {
valueUnwrapped := value . Enum ()
concreteValue := ( DIDNamespace )( valueUnwrapped )
( * x . list )[ i ] = concreteValue
}
func ( x * _Permissions_1_list ) Append ( value protoreflect . Value ) {
valueUnwrapped := value . Enum ()
concreteValue := ( DIDNamespace )( valueUnwrapped )
* x . list = append ( * x . list , concreteValue )
}
func ( x * _Permissions_1_list ) AppendMutable () protoreflect . Value {
panic ( fmt . Errorf ( "AppendMutable can not be called on message Permissions at list field Grants as it is not of Message kind" ))
}
func ( x * _Permissions_1_list ) Truncate ( n int ) {
* x . list = ( * x . list )[: n ]
}
func ( x * _Permissions_1_list ) NewElement () protoreflect . Value {
v := 0
return protoreflect . ValueOfEnum (( protoreflect . EnumNumber )( v ))
}
func ( x * _Permissions_1_list ) IsValid () bool {
return x . list != nil
}
var _ protoreflect . List = ( * _Permissions_2_list )( nil )
type _Permissions_2_list struct {
list * [] PermissionScope
}
func ( x * _Permissions_2_list ) Len () int {
if x . list == nil {
return 0
}
return len ( * x . list )
}
func ( x * _Permissions_2_list ) Get ( i int ) protoreflect . Value {
return protoreflect . ValueOfEnum (( protoreflect . EnumNumber )(( * x . list )[ i ]))
}
func ( x * _Permissions_2_list ) Set ( i int , value protoreflect . Value ) {
valueUnwrapped := value . Enum ()
concreteValue := ( PermissionScope )( valueUnwrapped )
( * x . list )[ i ] = concreteValue
}
func ( x * _Permissions_2_list ) Append ( value protoreflect . Value ) {
valueUnwrapped := value . Enum ()
concreteValue := ( PermissionScope )( valueUnwrapped )
* x . list = append ( * x . list , concreteValue )
}
func ( x * _Permissions_2_list ) AppendMutable () protoreflect . Value {
panic ( fmt . Errorf ( "AppendMutable can not be called on message Permissions at list field Scopes as it is not of Message kind" ))
}
func ( x * _Permissions_2_list ) Truncate ( n int ) {
* x . list = ( * x . list )[: n ]
}
func ( x * _Permissions_2_list ) NewElement () protoreflect . Value {
v := 0
return protoreflect . ValueOfEnum (( protoreflect . EnumNumber )( v ))
}
func ( x * _Permissions_2_list ) IsValid () bool {
return x . list != nil
}
var (
md_Permissions protoreflect . MessageDescriptor
fd_Permissions_grants protoreflect . FieldDescriptor
fd_Permissions_scopes protoreflect . FieldDescriptor
)
func init () {
file_did_v1_models_proto_init ()
md_Permissions = File_did_v1_models_proto . Messages (). ByName ( "Permissions" )
fd_Permissions_grants = md_Permissions . Fields (). ByName ( "grants" )
fd_Permissions_scopes = md_Permissions . Fields (). ByName ( "scopes" )
}
var _ protoreflect . Message = ( * fastReflection_Permissions )( nil )
type fastReflection_Permissions Permissions
func ( x * Permissions ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_Permissions )( x )
}
func ( x * Permissions ) slowProtoReflect () protoreflect . Message {
mi := & file_did_v1_models_proto_msgTypes [ 5 ]
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
var _fastReflection_Permissions_messageType fastReflection_Permissions_messageType
var _ protoreflect . MessageType = fastReflection_Permissions_messageType {}
type fastReflection_Permissions_messageType struct {}
func ( x fastReflection_Permissions_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_Permissions )( nil )
}
func ( x fastReflection_Permissions_messageType ) New () protoreflect . Message {
return new ( fastReflection_Permissions )
}
func ( x fastReflection_Permissions_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_Permissions
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func ( x * fastReflection_Permissions ) Descriptor () protoreflect . MessageDescriptor {
return md_Permissions
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func ( x * fastReflection_Permissions ) Type () protoreflect . MessageType {
return _fastReflection_Permissions_messageType
}
// New returns a newly allocated and mutable empty message.
func ( x * fastReflection_Permissions ) New () protoreflect . Message {
return new ( fastReflection_Permissions )
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func ( x * fastReflection_Permissions ) Interface () protoreflect . ProtoMessage {
return ( * Permissions )( x )
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func ( x * fastReflection_Permissions ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
if len ( x . Grants ) != 0 {
value := protoreflect . ValueOfList ( & _Permissions_1_list { list : & x . Grants })
if ! f ( fd_Permissions_grants , value ) {
return
}
}
if len ( x . Scopes ) != 0 {
value := protoreflect . ValueOfList ( & _Permissions_2_list { list : & x . Scopes })
if ! f ( fd_Permissions_scopes , value ) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func ( x * fastReflection_Permissions ) Has ( fd protoreflect . FieldDescriptor ) bool {
switch fd . FullName () {
case "did.v1.Permissions.grants" :
return len ( x . Grants ) != 0
case "did.v1.Permissions.scopes" :
return len ( x . Scopes ) != 0
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Permissions" ))
}
panic ( fmt . Errorf ( "message did.v1.Permissions does not contain field %s" , fd . FullName ()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Permissions ) Clear ( fd protoreflect . FieldDescriptor ) {
switch fd . FullName () {
case "did.v1.Permissions.grants" :
x . Grants = nil
case "did.v1.Permissions.scopes" :
x . Scopes = nil
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Permissions" ))
}
panic ( fmt . Errorf ( "message did.v1.Permissions does not contain field %s" , fd . FullName ()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func ( x * fastReflection_Permissions ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
switch descriptor . FullName () {
case "did.v1.Permissions.grants" :
if len ( x . Grants ) == 0 {
return protoreflect . ValueOfList ( & _Permissions_1_list {})
}
listValue := & _Permissions_1_list { list : & x . Grants }
return protoreflect . ValueOfList ( listValue )
case "did.v1.Permissions.scopes" :
if len ( x . Scopes ) == 0 {
return protoreflect . ValueOfList ( & _Permissions_2_list {})
}
listValue := & _Permissions_2_list { list : & x . Scopes }
return protoreflect . ValueOfList ( listValue )
default :
if descriptor . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Permissions" ))
}
panic ( fmt . Errorf ( "message did.v1.Permissions does not contain field %s" , descriptor . FullName ()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Permissions ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
switch fd . FullName () {
case "did.v1.Permissions.grants" :
lv := value . List ()
clv := lv .( * _Permissions_1_list )
x . Grants = * clv . list
case "did.v1.Permissions.scopes" :
lv := value . List ()
clv := lv .( * _Permissions_2_list )
x . Scopes = * clv . list
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Permissions" ))
}
panic ( fmt . Errorf ( "message did.v1.Permissions does not contain field %s" , fd . FullName ()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Permissions ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
switch fd . FullName () {
case "did.v1.Permissions.grants" :
if x . Grants == nil {
x . Grants = [] DIDNamespace {}
}
value := & _Permissions_1_list { list : & x . Grants }
return protoreflect . ValueOfList ( value )
case "did.v1.Permissions.scopes" :
if x . Scopes == nil {
x . Scopes = [] PermissionScope {}
}
value := & _Permissions_2_list { list : & x . Scopes }
return protoreflect . ValueOfList ( value )
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Permissions" ))
}
panic ( fmt . Errorf ( "message did.v1.Permissions does not contain field %s" , fd . FullName ()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func ( x * fastReflection_Permissions ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
switch fd . FullName () {
case "did.v1.Permissions.grants" :
list := [] DIDNamespace {}
return protoreflect . ValueOfList ( & _Permissions_1_list { list : & list })
case "did.v1.Permissions.scopes" :
list := [] PermissionScope {}
return protoreflect . ValueOfList ( & _Permissions_2_list { list : & list })
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Permissions" ))
}
panic ( fmt . Errorf ( "message did.v1.Permissions does not contain field %s" , fd . FullName ()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func ( x * fastReflection_Permissions ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
switch d . FullName () {
default :
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.Permissions" , d . FullName ()))
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func ( x * fastReflection_Permissions ) GetUnknown () protoreflect . RawFields {
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Permissions ) SetUnknown ( fields protoreflect . RawFields ) {
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func ( x * fastReflection_Permissions ) IsValid () bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func ( x * fastReflection_Permissions ) ProtoMethods () * protoiface . Methods {
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
x := input . Message . Interface ().( * Permissions )
if x == nil {
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
}
}
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
if len ( x . Grants ) > 0 {
l = 0
for _ , e := range x . Grants {
l += runtime . Sov ( uint64 ( e ))
}
n += 1 + runtime . Sov ( uint64 ( l )) + l
}
if len ( x . Scopes ) > 0 {
l = 0
for _ , e := range x . Scopes {
l += runtime . Sov ( uint64 ( e ))
}
n += 1 + runtime . Sov ( uint64 ( l )) + l
}
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
x := input . Message . Interface ().( * Permissions )
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
}
if len ( x . Scopes ) > 0 {
var pksize2 int
for _ , num := range x . Scopes {
pksize2 += runtime . Sov ( uint64 ( num ))
}
i -= pksize2
j1 := i
for _ , num1 := range x . Scopes {
num := uint64 ( num1 )
for num >= 1 << 7 {
dAtA [ j1 ] = uint8 ( uint64 ( num ) & 0x7f | 0x80 )
num >>= 7
j1 ++
}
dAtA [ j1 ] = uint8 ( num )
j1 ++
}
i = runtime . EncodeVarint ( dAtA , i , uint64 ( pksize2 ))
i --
dAtA [ i ] = 0x12
}
if len ( x . Grants ) > 0 {
var pksize4 int
for _ , num := range x . Grants {
pksize4 += runtime . Sov ( uint64 ( num ))
}
i -= pksize4
j3 := i
for _ , num1 := range x . Grants {
num := uint64 ( num1 )
for num >= 1 << 7 {
dAtA [ j3 ] = uint8 ( uint64 ( num ) & 0x7f | 0x80 )
num >>= 7
j3 ++
}
dAtA [ j3 ] = uint8 ( num )
j3 ++
}
i = runtime . EncodeVarint ( dAtA , i , uint64 ( pksize4 ))
i --
dAtA [ i ] = 0xa
}
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
x := input . Message . Interface ().( * Permissions )
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Permissions: wiretype end group for non-group" )
}
if fieldNum <= 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Permissions: illegal tag %d (wire type %d)" , fieldNum , wire )
}
switch fieldNum {
case 1 :
if wireType == 0 {
var v DIDNamespace
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
v |= DIDNamespace ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
x . Grants = append ( x . Grants , v )
} else if wireType == 2 {
var packedLen int
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
packedLen |= int ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
if packedLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + packedLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
var elementCount int
if elementCount != 0 && len ( x . Grants ) == 0 {
x . Grants = make ([] DIDNamespace , 0 , elementCount )
}
for iNdEx < postIndex {
var v DIDNamespace
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
v |= DIDNamespace ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
x . Grants = append ( x . Grants , v )
}
} else {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Grants" , wireType )
}
case 2 :
if wireType == 0 {
var v PermissionScope
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
v |= PermissionScope ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
x . Scopes = append ( x . Scopes , v )
} else if wireType == 2 {
var packedLen int
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
packedLen |= int ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
if packedLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + packedLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
var elementCount int
if elementCount != 0 && len ( x . Scopes ) == 0 {
x . Scopes = make ([] PermissionScope , 0 , elementCount )
}
for iNdEx < postIndex {
var v PermissionScope
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
v |= PermissionScope ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
x . Scopes = append ( x . Scopes , v )
}
} else {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Scopes" , wireType )
}
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
}
}
var (
md_Profile protoreflect . MessageDescriptor
fd_Profile_id protoreflect . FieldDescriptor
fd_Profile_subject protoreflect . FieldDescriptor
fd_Profile_controller protoreflect . FieldDescriptor
fd_Profile_metadata protoreflect . FieldDescriptor
)
func init () {
file_did_v1_models_proto_init ()
md_Profile = File_did_v1_models_proto . Messages (). ByName ( "Profile" )
fd_Profile_id = md_Profile . Fields (). ByName ( "id" )
fd_Profile_subject = md_Profile . Fields (). ByName ( "subject" )
fd_Profile_controller = md_Profile . Fields (). ByName ( "controller" )
fd_Profile_metadata = md_Profile . Fields (). ByName ( "metadata" )
}
var _ protoreflect . Message = ( * fastReflection_Profile )( nil )
type fastReflection_Profile Profile
func ( x * Profile ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_Profile )( x )
}
func ( x * Profile ) slowProtoReflect () protoreflect . Message {
mi := & file_did_v1_models_proto_msgTypes [ 6 ]
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
var _fastReflection_Profile_messageType fastReflection_Profile_messageType
var _ protoreflect . MessageType = fastReflection_Profile_messageType {}
type fastReflection_Profile_messageType struct {}
func ( x fastReflection_Profile_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_Profile )( nil )
}
func ( x fastReflection_Profile_messageType ) New () protoreflect . Message {
return new ( fastReflection_Profile )
}
func ( x fastReflection_Profile_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_Profile
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func ( x * fastReflection_Profile ) Descriptor () protoreflect . MessageDescriptor {
return md_Profile
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func ( x * fastReflection_Profile ) Type () protoreflect . MessageType {
return _fastReflection_Profile_messageType
}
// New returns a newly allocated and mutable empty message.
func ( x * fastReflection_Profile ) New () protoreflect . Message {
return new ( fastReflection_Profile )
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func ( x * fastReflection_Profile ) Interface () protoreflect . ProtoMessage {
return ( * Profile )( x )
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func ( x * fastReflection_Profile ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
if x . Id != "" {
value := protoreflect . ValueOfString ( x . Id )
if ! f ( fd_Profile_id , value ) {
return
}
}
if x . Subject != "" {
value := protoreflect . ValueOfString ( x . Subject )
if ! f ( fd_Profile_subject , value ) {
return
}
}
if x . Controller != "" {
value := protoreflect . ValueOfString ( x . Controller )
if ! f ( fd_Profile_controller , value ) {
return
}
}
if x . Metadata != nil {
value := protoreflect . ValueOfMessage ( x . Metadata . ProtoReflect ())
if ! f ( fd_Profile_metadata , value ) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func ( x * fastReflection_Profile ) Has ( fd protoreflect . FieldDescriptor ) bool {
switch fd . FullName () {
case "did.v1.Profile.id" :
return x . Id != ""
case "did.v1.Profile.subject" :
return x . Subject != ""
case "did.v1.Profile.controller" :
return x . Controller != ""
case "did.v1.Profile.metadata" :
return x . Metadata != nil
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Profile" ))
}
panic ( fmt . Errorf ( "message did.v1.Profile does not contain field %s" , fd . FullName ()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Profile ) Clear ( fd protoreflect . FieldDescriptor ) {
switch fd . FullName () {
case "did.v1.Profile.id" :
x . Id = ""
case "did.v1.Profile.subject" :
x . Subject = ""
case "did.v1.Profile.controller" :
x . Controller = ""
case "did.v1.Profile.metadata" :
x . Metadata = nil
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Profile" ))
}
panic ( fmt . Errorf ( "message did.v1.Profile does not contain field %s" , fd . FullName ()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
2024-08-10 17:19:59 -04:00
// of the value; to obtain a mutable reference, use Mutable.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Profile ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:19:59 -04:00
switch descriptor . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Profile.id" :
value := x . Id
2024-08-10 17:19:59 -04:00
return protoreflect . ValueOfString ( value )
2024-09-05 01:24:57 -04:00
case "did.v1.Profile.subject" :
value := x . Subject
return protoreflect . ValueOfString ( value )
case "did.v1.Profile.controller" :
value := x . Controller
return protoreflect . ValueOfString ( value )
case "did.v1.Profile.metadata" :
value := x . Metadata
return protoreflect . ValueOfMessage ( value . ProtoReflect ())
default :
if descriptor . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Profile" ))
}
panic ( fmt . Errorf ( "message did.v1.Profile does not contain field %s" , descriptor . FullName ()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Profile ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
switch fd . FullName () {
case "did.v1.Profile.id" :
x . Id = value . Interface ().( string )
case "did.v1.Profile.subject" :
x . Subject = value . Interface ().( string )
case "did.v1.Profile.controller" :
x . Controller = value . Interface ().( string )
case "did.v1.Profile.metadata" :
x . Metadata = value . Message (). Interface ().( * Metadata )
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Profile" ))
}
panic ( fmt . Errorf ( "message did.v1.Profile does not contain field %s" , fd . FullName ()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Profile ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
switch fd . FullName () {
case "did.v1.Profile.metadata" :
if x . Metadata == nil {
x . Metadata = new ( Metadata )
}
return protoreflect . ValueOfMessage ( x . Metadata . ProtoReflect ())
case "did.v1.Profile.id" :
panic ( fmt . Errorf ( "field id of message did.v1.Profile is not mutable" ))
case "did.v1.Profile.subject" :
panic ( fmt . Errorf ( "field subject of message did.v1.Profile is not mutable" ))
case "did.v1.Profile.controller" :
panic ( fmt . Errorf ( "field controller of message did.v1.Profile is not mutable" ))
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Profile" ))
}
panic ( fmt . Errorf ( "message did.v1.Profile does not contain field %s" , fd . FullName ()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func ( x * fastReflection_Profile ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
switch fd . FullName () {
case "did.v1.Profile.id" :
return protoreflect . ValueOfString ( "" )
case "did.v1.Profile.subject" :
return protoreflect . ValueOfString ( "" )
case "did.v1.Profile.controller" :
return protoreflect . ValueOfString ( "" )
case "did.v1.Profile.metadata" :
m := new ( Metadata )
return protoreflect . ValueOfMessage ( m . ProtoReflect ())
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Profile" ))
}
panic ( fmt . Errorf ( "message did.v1.Profile does not contain field %s" , fd . FullName ()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func ( x * fastReflection_Profile ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
switch d . FullName () {
default :
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.Profile" , d . FullName ()))
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func ( x * fastReflection_Profile ) GetUnknown () protoreflect . RawFields {
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Profile ) SetUnknown ( fields protoreflect . RawFields ) {
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func ( x * fastReflection_Profile ) IsValid () bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func ( x * fastReflection_Profile ) ProtoMethods () * protoiface . Methods {
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
x := input . Message . Interface ().( * Profile )
if x == nil {
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
}
}
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
l = len ( x . Id )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
l = len ( x . Subject )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
l = len ( x . Controller )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
if x . Metadata != nil {
l = options . Size ( x . Metadata )
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
x := input . Message . Interface ().( * Profile )
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
}
if x . Metadata != nil {
encoded , err := options . Marshal ( x . Metadata )
if err != nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, err
}
i -= len ( encoded )
copy ( dAtA [ i :], encoded )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( encoded )))
i --
dAtA [ i ] = 0x22
}
if len ( x . Controller ) > 0 {
i -= len ( x . Controller )
copy ( dAtA [ i :], x . Controller )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Controller )))
i --
dAtA [ i ] = 0x1a
}
if len ( x . Subject ) > 0 {
i -= len ( x . Subject )
copy ( dAtA [ i :], x . Subject )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Subject )))
i --
dAtA [ i ] = 0x12
}
if len ( x . Id ) > 0 {
i -= len ( x . Id )
copy ( dAtA [ i :], x . Id )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Id )))
i --
dAtA [ i ] = 0xa
}
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
x := input . Message . Interface ().( * Profile )
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Profile: wiretype end group for non-group" )
}
if fieldNum <= 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Profile: illegal tag %d (wire type %d)" , fieldNum , wire )
}
switch fieldNum {
case 1 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Id" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Id = string ( dAtA [ iNdEx : postIndex ])
iNdEx = postIndex
case 2 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Subject" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Subject = string ( dAtA [ iNdEx : postIndex ])
iNdEx = postIndex
case 3 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Controller" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Controller = string ( dAtA [ iNdEx : postIndex ])
iNdEx = postIndex
case 4 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Metadata" , wireType )
}
var msglen int
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
msglen |= int ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if x . Metadata == nil {
x . Metadata = & Metadata {}
}
if err := options . Unmarshal ( dAtA [ iNdEx : postIndex ], x . Metadata ); err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
iNdEx = postIndex
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
}
iNdEx += skippy
}
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
}
}
var (
md_Property protoreflect . MessageDescriptor
fd_Property_accumulator protoreflect . FieldDescriptor
fd_Property_key protoreflect . FieldDescriptor
)
func init () {
file_did_v1_models_proto_init ()
md_Property = File_did_v1_models_proto . Messages (). ByName ( "Property" )
fd_Property_accumulator = md_Property . Fields (). ByName ( "accumulator" )
fd_Property_key = md_Property . Fields (). ByName ( "key" )
}
var _ protoreflect . Message = ( * fastReflection_Property )( nil )
type fastReflection_Property Property
func ( x * Property ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_Property )( x )
}
func ( x * Property ) slowProtoReflect () protoreflect . Message {
mi := & file_did_v1_models_proto_msgTypes [ 7 ]
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
var _fastReflection_Property_messageType fastReflection_Property_messageType
var _ protoreflect . MessageType = fastReflection_Property_messageType {}
type fastReflection_Property_messageType struct {}
func ( x fastReflection_Property_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_Property )( nil )
}
func ( x fastReflection_Property_messageType ) New () protoreflect . Message {
return new ( fastReflection_Property )
}
func ( x fastReflection_Property_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_Property
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func ( x * fastReflection_Property ) Descriptor () protoreflect . MessageDescriptor {
return md_Property
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func ( x * fastReflection_Property ) Type () protoreflect . MessageType {
return _fastReflection_Property_messageType
}
// New returns a newly allocated and mutable empty message.
func ( x * fastReflection_Property ) New () protoreflect . Message {
return new ( fastReflection_Property )
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func ( x * fastReflection_Property ) Interface () protoreflect . ProtoMessage {
return ( * Property )( x )
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func ( x * fastReflection_Property ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
if len ( x . Accumulator ) != 0 {
value := protoreflect . ValueOfBytes ( x . Accumulator )
if ! f ( fd_Property_accumulator , value ) {
return
}
}
if len ( x . Key ) != 0 {
value := protoreflect . ValueOfBytes ( x . Key )
if ! f ( fd_Property_key , value ) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func ( x * fastReflection_Property ) Has ( fd protoreflect . FieldDescriptor ) bool {
switch fd . FullName () {
case "did.v1.Property.accumulator" :
return len ( x . Accumulator ) != 0
case "did.v1.Property.key" :
return len ( x . Key ) != 0
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Property" ))
}
panic ( fmt . Errorf ( "message did.v1.Property does not contain field %s" , fd . FullName ()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Property ) Clear ( fd protoreflect . FieldDescriptor ) {
switch fd . FullName () {
case "did.v1.Property.accumulator" :
x . Accumulator = nil
case "did.v1.Property.key" :
x . Key = nil
default :
if fd . IsExtension () {
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Property" ))
}
panic ( fmt . Errorf ( "message did.v1.Property does not contain field %s" , fd . FullName ()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func ( x * fastReflection_Property ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
switch descriptor . FullName () {
case "did.v1.Property.accumulator" :
value := x . Accumulator
return protoreflect . ValueOfBytes ( value )
case "did.v1.Property.key" :
value := x . Key
return protoreflect . ValueOfBytes ( value )
2024-08-10 17:19:59 -04:00
default :
if descriptor . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Property" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Property does not contain field %s" , descriptor . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Property ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Property.accumulator" :
x . Accumulator = value . Bytes ()
case "did.v1.Property.key" :
x . Key = value . Bytes ()
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Property" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Property does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Property ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Property.accumulator" :
panic ( fmt . Errorf ( "field accumulator of message did.v1.Property is not mutable" ))
case "did.v1.Property.key" :
panic ( fmt . Errorf ( "field key of message did.v1.Property is not mutable" ))
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Property" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Property does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Property ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Property.accumulator" :
return protoreflect . ValueOfBytes ( nil )
case "did.v1.Property.key" :
return protoreflect . ValueOfBytes ( nil )
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Property" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Property does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Property ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
2024-08-10 17:19:59 -04:00
switch d . FullName () {
default :
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.Property" , d . FullName ()))
2024-08-10 17:19:59 -04:00
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Property ) GetUnknown () protoreflect . RawFields {
2024-08-10 17:19:59 -04:00
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Property ) SetUnknown ( fields protoreflect . RawFields ) {
2024-08-10 17:19:59 -04:00
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Property ) IsValid () bool {
2024-08-10 17:19:59 -04:00
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Property ) ProtoMethods () * protoiface . Methods {
2024-08-10 17:19:59 -04:00
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Property )
2024-08-10 17:19:59 -04:00
if x == nil {
2024-09-05 01:24:57 -04:00
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
2024-08-10 17:19:59 -04:00
}
}
2024-09-05 01:24:57 -04:00
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
l = len ( x . Accumulator )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
l = len ( x . Key )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
x := input . Message . Interface ().( * Property )
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
}
if len ( x . Key ) > 0 {
i -= len ( x . Key )
copy ( dAtA [ i :], x . Key )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Key )))
i --
dAtA [ i ] = 0x12
}
if len ( x . Accumulator ) > 0 {
i -= len ( x . Accumulator )
copy ( dAtA [ i :], x . Accumulator )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Accumulator )))
2024-08-10 17:19:59 -04:00
i --
dAtA [ i ] = 0xa
}
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Property )
2024-08-10 17:19:59 -04:00
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Property: wiretype end group for non-group" )
2024-08-10 17:19:59 -04:00
}
if fieldNum <= 0 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Property: illegal tag %d (wire type %d)" , fieldNum , wire )
2024-08-10 17:19:59 -04:00
}
switch fieldNum {
case 1 :
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Accumulator" , wireType )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
var byteLen int
2024-08-31 12:49:44 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-09-05 01:24:57 -04:00
byteLen |= int ( b & 0x7F ) << shift
2024-08-31 12:49:44 -04:00
if b < 0x80 {
break
}
}
2024-09-05 01:24:57 -04:00
if byteLen < 0 {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
2024-09-05 01:24:57 -04:00
postIndex := iNdEx + byteLen
2024-08-31 12:49:44 -04:00
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
x . Accumulator = append ( x . Accumulator [: 0 ], dAtA [ iNdEx : postIndex ] ... )
if x . Accumulator == nil {
x . Accumulator = [] byte {}
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
iNdEx = postIndex
2024-09-05 01:24:57 -04:00
case 2 :
2024-08-31 12:49:44 -04:00
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Key" , wireType )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
var byteLen int
2024-08-10 17:19:59 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
byteLen |= int ( b & 0x7F ) << shift
if b < 0x80 {
break
2024-08-31 12:49:44 -04:00
}
}
2024-09-05 01:24:57 -04:00
if byteLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + byteLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Key = append ( x . Key [: 0 ], dAtA [ iNdEx : postIndex ] ... )
if x . Key == nil {
x . Key = [] byte {}
}
2024-08-31 12:49:44 -04:00
iNdEx = postIndex
2024-08-10 17:19:59 -04:00
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
}
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . Map = ( * _PubKey_7_map )( nil )
2024-08-31 12:49:44 -04:00
2024-09-05 01:24:57 -04:00
type _PubKey_7_map struct {
m * map [ string ] string
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _PubKey_7_map ) Len () int {
if x . m == nil {
2024-08-31 12:49:44 -04:00
return 0
}
2024-09-05 01:24:57 -04:00
return len ( * x . m )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _PubKey_7_map ) Range ( f func ( protoreflect . MapKey , protoreflect . Value ) bool ) {
if x . m == nil {
return
}
for k , v := range * x . m {
mapKey := ( protoreflect . MapKey )( protoreflect . ValueOfString ( k ))
mapValue := protoreflect . ValueOfString ( v )
if ! f ( mapKey , mapValue ) {
break
}
2024-08-31 12:49:44 -04:00
}
}
2024-09-05 01:24:57 -04:00
func ( x * _PubKey_7_map ) Has ( key protoreflect . MapKey ) bool {
if x . m == nil {
return false
}
keyUnwrapped := key . String ()
concreteValue := keyUnwrapped
_ , ok := ( * x . m )[ concreteValue ]
return ok
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _PubKey_7_map ) Clear ( key protoreflect . MapKey ) {
if x . m == nil {
return
}
keyUnwrapped := key . String ()
concreteKey := keyUnwrapped
delete ( * x . m , concreteKey )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _PubKey_7_map ) Get ( key protoreflect . MapKey ) protoreflect . Value {
if x . m == nil {
return protoreflect . Value {}
}
keyUnwrapped := key . String ()
concreteKey := keyUnwrapped
v , ok := ( * x . m )[ concreteKey ]
if ! ok {
return protoreflect . Value {}
}
return protoreflect . ValueOfString ( v )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _PubKey_7_map ) Set ( key protoreflect . MapKey , value protoreflect . Value ) {
if ! key . IsValid () || ! value . IsValid () {
panic ( "invalid key or value provided" )
}
keyUnwrapped := key . String ()
concreteKey := keyUnwrapped
valueUnwrapped := value . String ()
concreteValue := valueUnwrapped
( * x . m )[ concreteKey ] = concreteValue
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _PubKey_7_map ) Mutable ( key protoreflect . MapKey ) protoreflect . Value {
panic ( "should not call Mutable on protoreflect.Map whose value is not of type protoreflect.Message" )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _PubKey_7_map ) NewValue () protoreflect . Value {
v := ""
return protoreflect . ValueOfString ( v )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * _PubKey_7_map ) IsValid () bool {
return x . m != nil
2024-08-31 12:49:44 -04:00
}
2024-08-10 17:19:59 -04:00
var (
2024-09-05 01:24:57 -04:00
md_PubKey protoreflect . MessageDescriptor
fd_PubKey_role protoreflect . FieldDescriptor
fd_PubKey_algorithm protoreflect . FieldDescriptor
fd_PubKey_encoding protoreflect . FieldDescriptor
fd_PubKey_raw protoreflect . FieldDescriptor
fd_PubKey_hex protoreflect . FieldDescriptor
fd_PubKey_multibase protoreflect . FieldDescriptor
fd_PubKey_jwk protoreflect . FieldDescriptor
2024-08-10 17:19:59 -04:00
)
func init () {
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_init ()
2024-09-05 01:24:57 -04:00
md_PubKey = File_did_v1_models_proto . Messages (). ByName ( "PubKey" )
fd_PubKey_role = md_PubKey . Fields (). ByName ( "role" )
fd_PubKey_algorithm = md_PubKey . Fields (). ByName ( "algorithm" )
fd_PubKey_encoding = md_PubKey . Fields (). ByName ( "encoding" )
fd_PubKey_raw = md_PubKey . Fields (). ByName ( "raw" )
fd_PubKey_hex = md_PubKey . Fields (). ByName ( "hex" )
fd_PubKey_multibase = md_PubKey . Fields (). ByName ( "multibase" )
fd_PubKey_jwk = md_PubKey . Fields (). ByName ( "jwk" )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . Message = ( * fastReflection_PubKey )( nil )
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_PubKey PubKey
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
func ( x * PubKey ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_PubKey )( x )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * PubKey ) slowProtoReflect () protoreflect . Message {
mi := & file_did_v1_models_proto_msgTypes [ 8 ]
2024-08-10 17:19:59 -04:00
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
2024-09-05 01:24:57 -04:00
var _fastReflection_PubKey_messageType fastReflection_PubKey_messageType
var _ protoreflect . MessageType = fastReflection_PubKey_messageType {}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_PubKey_messageType struct {}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
func ( x fastReflection_PubKey_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_PubKey )( nil )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_PubKey_messageType ) New () protoreflect . Message {
return new ( fastReflection_PubKey )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_PubKey_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_PubKey
2024-08-10 17:19:59 -04:00
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) Descriptor () protoreflect . MessageDescriptor {
return md_PubKey
2024-08-10 17:19:59 -04:00
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) Type () protoreflect . MessageType {
return _fastReflection_PubKey_messageType
2024-08-10 17:19:59 -04:00
}
// New returns a newly allocated and mutable empty message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) New () protoreflect . Message {
return new ( fastReflection_PubKey )
2024-08-10 17:19:59 -04:00
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) Interface () protoreflect . ProtoMessage {
return ( * PubKey )( x )
2024-08-10 17:19:59 -04:00
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
if x . Role != 0 {
value := protoreflect . ValueOfEnum (( protoreflect . EnumNumber )( x . Role ))
if ! f ( fd_PubKey_role , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if x . Algorithm != 0 {
value := protoreflect . ValueOfEnum (( protoreflect . EnumNumber )( x . Algorithm ))
if ! f ( fd_PubKey_algorithm , value ) {
return
}
}
if x . Encoding != 0 {
value := protoreflect . ValueOfEnum (( protoreflect . EnumNumber )( x . Encoding ))
if ! f ( fd_PubKey_encoding , value ) {
return
}
}
if len ( x . Raw ) != 0 {
value := protoreflect . ValueOfBytes ( x . Raw )
if ! f ( fd_PubKey_raw , value ) {
return
}
}
if x . Hex != "" {
value := protoreflect . ValueOfString ( x . Hex )
if ! f ( fd_PubKey_hex , value ) {
return
}
}
if x . Multibase != "" {
value := protoreflect . ValueOfString ( x . Multibase )
if ! f ( fd_PubKey_multibase , value ) {
return
}
}
if len ( x . Jwk ) != 0 {
value := protoreflect . ValueOfMap ( & _PubKey_7_map { m : & x . Jwk })
if ! f ( fd_PubKey_jwk , value ) {
2024-08-10 17:19:59 -04:00
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) Has ( fd protoreflect . FieldDescriptor ) bool {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.PubKey.role" :
return x . Role != 0
case "did.v1.PubKey.algorithm" :
return x . Algorithm != 0
case "did.v1.PubKey.encoding" :
return x . Encoding != 0
case "did.v1.PubKey.raw" :
return len ( x . Raw ) != 0
case "did.v1.PubKey.hex" :
return x . Hex != ""
case "did.v1.PubKey.multibase" :
return x . Multibase != ""
case "did.v1.PubKey.jwk" :
return len ( x . Jwk ) != 0
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.PubKey" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.PubKey does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) Clear ( fd protoreflect . FieldDescriptor ) {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.PubKey.role" :
x . Role = 0
case "did.v1.PubKey.algorithm" :
x . Algorithm = 0
case "did.v1.PubKey.encoding" :
x . Encoding = 0
case "did.v1.PubKey.raw" :
x . Raw = nil
case "did.v1.PubKey.hex" :
x . Hex = ""
case "did.v1.PubKey.multibase" :
x . Multibase = ""
case "did.v1.PubKey.jwk" :
x . Jwk = nil
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.PubKey" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.PubKey does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:19:59 -04:00
switch descriptor . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.PubKey.role" :
value := x . Role
return protoreflect . ValueOfEnum (( protoreflect . EnumNumber )( value ))
case "did.v1.PubKey.algorithm" :
value := x . Algorithm
return protoreflect . ValueOfEnum (( protoreflect . EnumNumber )( value ))
case "did.v1.PubKey.encoding" :
value := x . Encoding
return protoreflect . ValueOfEnum (( protoreflect . EnumNumber )( value ))
case "did.v1.PubKey.raw" :
value := x . Raw
return protoreflect . ValueOfBytes ( value )
case "did.v1.PubKey.hex" :
value := x . Hex
return protoreflect . ValueOfString ( value )
case "did.v1.PubKey.multibase" :
value := x . Multibase
return protoreflect . ValueOfString ( value )
case "did.v1.PubKey.jwk" :
if len ( x . Jwk ) == 0 {
return protoreflect . ValueOfMap ( & _PubKey_7_map {})
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
mapValue := & _PubKey_7_map { m : & x . Jwk }
return protoreflect . ValueOfMap ( mapValue )
2024-08-10 17:19:59 -04:00
default :
if descriptor . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.PubKey" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.PubKey does not contain field %s" , descriptor . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.PubKey.role" :
x . Role = ( KeyRole )( value . Enum ())
case "did.v1.PubKey.algorithm" :
x . Algorithm = ( KeyAlgorithm )( value . Enum ())
case "did.v1.PubKey.encoding" :
x . Encoding = ( KeyEncoding )( value . Enum ())
case "did.v1.PubKey.raw" :
x . Raw = value . Bytes ()
case "did.v1.PubKey.hex" :
x . Hex = value . Interface ().( string )
case "did.v1.PubKey.multibase" :
x . Multibase = value . Interface ().( string )
case "did.v1.PubKey.jwk" :
mv := value . Map ()
cmv := mv .( * _PubKey_7_map )
x . Jwk = * cmv . m
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.PubKey" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.PubKey does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.PubKey.jwk" :
if x . Jwk == nil {
x . Jwk = make ( map [ string ] string )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
value := & _PubKey_7_map { m : & x . Jwk }
return protoreflect . ValueOfMap ( value )
case "did.v1.PubKey.role" :
panic ( fmt . Errorf ( "field role of message did.v1.PubKey is not mutable" ))
case "did.v1.PubKey.algorithm" :
panic ( fmt . Errorf ( "field algorithm of message did.v1.PubKey is not mutable" ))
case "did.v1.PubKey.encoding" :
panic ( fmt . Errorf ( "field encoding of message did.v1.PubKey is not mutable" ))
case "did.v1.PubKey.raw" :
panic ( fmt . Errorf ( "field raw of message did.v1.PubKey is not mutable" ))
case "did.v1.PubKey.hex" :
panic ( fmt . Errorf ( "field hex of message did.v1.PubKey is not mutable" ))
case "did.v1.PubKey.multibase" :
panic ( fmt . Errorf ( "field multibase of message did.v1.PubKey is not mutable" ))
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.PubKey" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.PubKey does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:19:59 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.PubKey.role" :
return protoreflect . ValueOfEnum ( 0 )
case "did.v1.PubKey.algorithm" :
return protoreflect . ValueOfEnum ( 0 )
case "did.v1.PubKey.encoding" :
return protoreflect . ValueOfEnum ( 0 )
case "did.v1.PubKey.raw" :
return protoreflect . ValueOfBytes ( nil )
case "did.v1.PubKey.hex" :
return protoreflect . ValueOfString ( "" )
case "did.v1.PubKey.multibase" :
return protoreflect . ValueOfString ( "" )
case "did.v1.PubKey.jwk" :
m := make ( map [ string ] string )
return protoreflect . ValueOfMap ( & _PubKey_7_map { m : & m })
2024-08-10 17:19:59 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.PubKey" ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.PubKey does not contain field %s" , fd . FullName ()))
2024-08-10 17:19:59 -04:00
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
2024-08-10 17:19:59 -04:00
switch d . FullName () {
default :
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.PubKey" , d . FullName ()))
2024-08-10 17:19:59 -04:00
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) GetUnknown () protoreflect . RawFields {
2024-08-10 17:19:59 -04:00
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) SetUnknown ( fields protoreflect . RawFields ) {
2024-08-10 17:19:59 -04:00
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) IsValid () bool {
2024-08-10 17:19:59 -04:00
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_PubKey ) ProtoMethods () * protoiface . Methods {
2024-08-10 17:19:59 -04:00
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * PubKey )
2024-08-10 17:19:59 -04:00
if x == nil {
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
}
}
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
2024-09-05 01:24:57 -04:00
if x . Role != 0 {
n += 1 + runtime . Sov ( uint64 ( x . Role ))
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
if x . Algorithm != 0 {
n += 1 + runtime . Sov ( uint64 ( x . Algorithm ))
}
if x . Encoding != 0 {
n += 1 + runtime . Sov ( uint64 ( x . Encoding ))
}
l = len ( x . Raw )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
l = len ( x . Hex )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
l = len ( x . Multibase )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
if len ( x . Jwk ) > 0 {
SiZeMaP := func ( k string , v string ) {
mapEntrySize := 1 + len ( k ) + runtime . Sov ( uint64 ( len ( k ))) + 1 + len ( v ) + runtime . Sov ( uint64 ( len ( v )))
n += mapEntrySize + 1 + runtime . Sov ( uint64 ( mapEntrySize ))
}
if options . Deterministic {
sortme := make ([] string , 0 , len ( x . Jwk ))
for k := range x . Jwk {
sortme = append ( sortme , k )
}
sort . Strings ( sortme )
for _ , k := range sortme {
v := x . Jwk [ k ]
SiZeMaP ( k , v )
}
} else {
for k , v := range x . Jwk {
SiZeMaP ( k , v )
}
2024-08-31 12:49:44 -04:00
}
2024-08-10 17:19:59 -04:00
}
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
2024-09-05 01:24:57 -04:00
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
x := input . Message . Interface ().( * PubKey )
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
}
if len ( x . Jwk ) > 0 {
MaRsHaLmAp := func ( k string , v string ) ( protoiface . MarshalOutput , error ) {
baseI := i
i -= len ( v )
copy ( dAtA [ i :], v )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( v )))
i --
dAtA [ i ] = 0x12
i -= len ( k )
copy ( dAtA [ i :], k )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( k )))
i --
dAtA [ i ] = 0xa
i = runtime . EncodeVarint ( dAtA , i , uint64 ( baseI - i ))
i --
dAtA [ i ] = 0x3a
return protoiface . MarshalOutput {}, nil
}
if options . Deterministic {
keysForJwk := make ([] string , 0 , len ( x . Jwk ))
for k := range x . Jwk {
keysForJwk = append ( keysForJwk , string ( k ))
}
sort . Slice ( keysForJwk , func ( i , j int ) bool {
return keysForJwk [ i ] < keysForJwk [ j ]
})
for iNdEx := len ( keysForJwk ) - 1 ; iNdEx >= 0 ; iNdEx -- {
v := x . Jwk [ string ( keysForJwk [ iNdEx ])]
out , err := MaRsHaLmAp ( keysForJwk [ iNdEx ], v )
if err != nil {
return out , err
}
}
} else {
for k := range x . Jwk {
v := x . Jwk [ k ]
out , err := MaRsHaLmAp ( k , v )
if err != nil {
return out , err
}
}
}
}
if len ( x . Multibase ) > 0 {
i -= len ( x . Multibase )
copy ( dAtA [ i :], x . Multibase )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Multibase )))
i --
dAtA [ i ] = 0x32
}
if len ( x . Hex ) > 0 {
i -= len ( x . Hex )
copy ( dAtA [ i :], x . Hex )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Hex )))
i --
dAtA [ i ] = 0x2a
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
if len ( x . Raw ) > 0 {
i -= len ( x . Raw )
copy ( dAtA [ i :], x . Raw )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Raw )))
i --
dAtA [ i ] = 0x22
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
if x . Encoding != 0 {
i = runtime . EncodeVarint ( dAtA , i , uint64 ( x . Encoding ))
i --
dAtA [ i ] = 0x18
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
if x . Algorithm != 0 {
i = runtime . EncodeVarint ( dAtA , i , uint64 ( x . Algorithm ))
2024-08-10 17:19:59 -04:00
i --
2024-09-05 01:24:57 -04:00
dAtA [ i ] = 0x10
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
if x . Role != 0 {
i = runtime . EncodeVarint ( dAtA , i , uint64 ( x . Role ))
2024-08-10 17:19:59 -04:00
i --
2024-09-05 01:24:57 -04:00
dAtA [ i ] = 0x8
2024-08-10 17:19:59 -04:00
}
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * PubKey )
2024-08-10 17:19:59 -04:00
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
2024-09-05 01:24:57 -04:00
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: PubKey: wiretype end group for non-group" )
}
if fieldNum <= 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: PubKey: illegal tag %d (wire type %d)" , fieldNum , wire )
}
switch fieldNum {
case 1 :
if wireType != 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Role" , wireType )
}
x . Role = 0
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
x . Role |= KeyRole ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
case 2 :
if wireType != 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Algorithm" , wireType )
}
x . Algorithm = 0
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
x . Algorithm |= KeyAlgorithm ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
case 3 :
if wireType != 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Encoding" , wireType )
}
x . Encoding = 0
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
x . Encoding |= KeyEncoding ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
case 4 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Raw" , wireType )
}
var byteLen int
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
byteLen |= int ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
if byteLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + byteLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Raw = append ( x . Raw [: 0 ], dAtA [ iNdEx : postIndex ] ... )
if x . Raw == nil {
x . Raw = [] byte {}
}
iNdEx = postIndex
case 5 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Hex" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Hex = string ( dAtA [ iNdEx : postIndex ])
iNdEx = postIndex
case 6 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Multibase" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Multibase = string ( dAtA [ iNdEx : postIndex ])
iNdEx = postIndex
case 7 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Jwk" , wireType )
}
var msglen int
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
msglen |= int ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
2024-08-10 17:19:59 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
if x . Jwk == nil {
x . Jwk = make ( map [ string ] string )
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
var mapkey string
var mapvalue string
for iNdEx < postIndex {
entryPreIndex := iNdEx
var wire uint64
2024-08-31 12:49:44 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-09-05 01:24:57 -04:00
wire |= uint64 ( b & 0x7F ) << shift
2024-08-31 12:49:44 -04:00
if b < 0x80 {
break
}
}
2024-09-05 01:24:57 -04:00
fieldNum := int32 ( wire >> 3 )
if fieldNum == 1 {
var stringLenmapkey uint64
2024-08-31 12:49:44 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-09-05 01:24:57 -04:00
stringLenmapkey |= uint64 ( b & 0x7F ) << shift
2024-08-31 12:49:44 -04:00
if b < 0x80 {
break
}
}
2024-09-05 01:24:57 -04:00
intStringLenmapkey := int ( stringLenmapkey )
if intStringLenmapkey < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
postStringIndexmapkey := iNdEx + intStringLenmapkey
if postStringIndexmapkey < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
if postStringIndexmapkey > l {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
mapkey = string ( dAtA [ iNdEx : postStringIndexmapkey ])
iNdEx = postStringIndexmapkey
} else if fieldNum == 2 {
var stringLenmapvalue uint64
2024-08-31 12:49:44 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-09-05 01:24:57 -04:00
stringLenmapvalue |= uint64 ( b & 0x7F ) << shift
2024-08-31 12:49:44 -04:00
if b < 0x80 {
break
}
}
2024-09-05 01:24:57 -04:00
intStringLenmapvalue := int ( stringLenmapvalue )
if intStringLenmapvalue < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postStringIndexmapvalue := iNdEx + intStringLenmapvalue
if postStringIndexmapvalue < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postStringIndexmapvalue > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
mapvalue = string ( dAtA [ iNdEx : postStringIndexmapvalue ])
iNdEx = postStringIndexmapvalue
} else {
iNdEx = entryPreIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > postIndex {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
iNdEx += skippy
2024-08-31 12:49:44 -04:00
}
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
x . Jwk [ mapkey ] = mapvalue
iNdEx = postIndex
2024-08-10 17:19:59 -04:00
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
2024-09-05 01:24:57 -04:00
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
}
iNdEx += skippy
}
}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
2024-08-31 12:49:44 -04:00
}
2024-08-10 17:01:14 -04:00
}
var (
2024-09-05 01:24:57 -04:00
md_Service protoreflect . MessageDescriptor
fd_Service_id protoreflect . FieldDescriptor
fd_Service_controller protoreflect . FieldDescriptor
fd_Service_origin protoreflect . FieldDescriptor
fd_Service_permissions protoreflect . FieldDescriptor
fd_Service_openid protoreflect . FieldDescriptor
fd_Service_metadata protoreflect . FieldDescriptor
2024-08-10 17:01:14 -04:00
)
func init () {
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_init ()
2024-09-05 01:24:57 -04:00
md_Service = File_did_v1_models_proto . Messages (). ByName ( "Service" )
fd_Service_id = md_Service . Fields (). ByName ( "id" )
fd_Service_controller = md_Service . Fields (). ByName ( "controller" )
fd_Service_origin = md_Service . Fields (). ByName ( "origin" )
fd_Service_permissions = md_Service . Fields (). ByName ( "permissions" )
fd_Service_openid = md_Service . Fields (). ByName ( "openid" )
fd_Service_metadata = md_Service . Fields (). ByName ( "metadata" )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . Message = ( * fastReflection_Service )( nil )
2024-08-10 17:01:14 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_Service Service
2024-08-10 17:01:14 -04:00
2024-09-05 01:24:57 -04:00
func ( x * Service ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_Service )( x )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * Service ) slowProtoReflect () protoreflect . Message {
mi := & file_did_v1_models_proto_msgTypes [ 9 ]
2024-08-10 17:01:14 -04:00
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
2024-09-05 01:24:57 -04:00
var _fastReflection_Service_messageType fastReflection_Service_messageType
var _ protoreflect . MessageType = fastReflection_Service_messageType {}
2024-08-10 17:01:14 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_Service_messageType struct {}
2024-08-10 17:01:14 -04:00
2024-09-05 01:24:57 -04:00
func ( x fastReflection_Service_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_Service )( nil )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_Service_messageType ) New () protoreflect . Message {
return new ( fastReflection_Service )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_Service_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_Service
2024-08-10 17:01:14 -04:00
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) Descriptor () protoreflect . MessageDescriptor {
return md_Service
2024-08-10 17:01:14 -04:00
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) Type () protoreflect . MessageType {
return _fastReflection_Service_messageType
2024-08-10 17:01:14 -04:00
}
// New returns a newly allocated and mutable empty message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) New () protoreflect . Message {
return new ( fastReflection_Service )
2024-08-10 17:01:14 -04:00
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) Interface () protoreflect . ProtoMessage {
return ( * Service )( x )
2024-08-10 17:01:14 -04:00
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
2024-08-31 12:49:44 -04:00
if x . Id != "" {
value := protoreflect . ValueOfString ( x . Id )
2024-09-05 01:24:57 -04:00
if ! f ( fd_Service_id , value ) {
2024-08-10 17:01:14 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if x . Controller != "" {
value := protoreflect . ValueOfString ( x . Controller )
if ! f ( fd_Service_controller , value ) {
2024-08-31 12:49:44 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if x . Origin != "" {
value := protoreflect . ValueOfString ( x . Origin )
if ! f ( fd_Service_origin , value ) {
2024-08-10 17:01:14 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if x . Permissions != nil {
value := protoreflect . ValueOfMessage ( x . Permissions . ProtoReflect ())
if ! f ( fd_Service_permissions , value ) {
2024-08-10 17:01:14 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if x . Openid != nil {
value := protoreflect . ValueOfMessage ( x . Openid . ProtoReflect ())
if ! f ( fd_Service_openid , value ) {
2024-08-10 17:01:14 -04:00
return
}
}
2024-08-31 12:49:44 -04:00
if x . Metadata != nil {
value := protoreflect . ValueOfMessage ( x . Metadata . ProtoReflect ())
2024-09-05 01:24:57 -04:00
if ! f ( fd_Service_metadata , value ) {
2024-08-10 17:01:14 -04:00
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) Has ( fd protoreflect . FieldDescriptor ) bool {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Service.id" :
2024-08-31 12:49:44 -04:00
return x . Id != ""
2024-09-05 01:24:57 -04:00
case "did.v1.Service.controller" :
2024-08-31 12:49:44 -04:00
return x . Controller != ""
2024-09-05 01:24:57 -04:00
case "did.v1.Service.origin" :
return x . Origin != ""
case "did.v1.Service.permissions" :
return x . Permissions != nil
case "did.v1.Service.openid" :
return x . Openid != nil
case "did.v1.Service.metadata" :
2024-08-31 12:49:44 -04:00
return x . Metadata != nil
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Service" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Service does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) Clear ( fd protoreflect . FieldDescriptor ) {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Service.id" :
2024-08-31 12:49:44 -04:00
x . Id = ""
2024-09-05 01:24:57 -04:00
case "did.v1.Service.controller" :
2024-08-31 12:49:44 -04:00
x . Controller = ""
2024-09-05 01:24:57 -04:00
case "did.v1.Service.origin" :
x . Origin = ""
case "did.v1.Service.permissions" :
x . Permissions = nil
case "did.v1.Service.openid" :
x . Openid = nil
case "did.v1.Service.metadata" :
2024-08-31 12:49:44 -04:00
x . Metadata = nil
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Service" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Service does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:01:14 -04:00
switch descriptor . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Service.id" :
2024-08-31 12:49:44 -04:00
value := x . Id
return protoreflect . ValueOfString ( value )
2024-09-05 01:24:57 -04:00
case "did.v1.Service.controller" :
2024-08-31 12:49:44 -04:00
value := x . Controller
2024-08-10 17:01:14 -04:00
return protoreflect . ValueOfString ( value )
2024-09-05 01:24:57 -04:00
case "did.v1.Service.origin" :
value := x . Origin
return protoreflect . ValueOfString ( value )
case "did.v1.Service.permissions" :
value := x . Permissions
return protoreflect . ValueOfMessage ( value . ProtoReflect ())
case "did.v1.Service.openid" :
value := x . Openid
return protoreflect . ValueOfMessage ( value . ProtoReflect ())
case "did.v1.Service.metadata" :
2024-08-31 12:49:44 -04:00
value := x . Metadata
return protoreflect . ValueOfMessage ( value . ProtoReflect ())
2024-08-10 17:01:14 -04:00
default :
if descriptor . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Service" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Service does not contain field %s" , descriptor . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Service.id" :
2024-08-31 12:49:44 -04:00
x . Id = value . Interface ().( string )
2024-09-05 01:24:57 -04:00
case "did.v1.Service.controller" :
2024-08-31 12:49:44 -04:00
x . Controller = value . Interface ().( string )
2024-09-05 01:24:57 -04:00
case "did.v1.Service.origin" :
x . Origin = value . Interface ().( string )
case "did.v1.Service.permissions" :
x . Permissions = value . Message (). Interface ().( * Permissions )
case "did.v1.Service.openid" :
x . Openid = value . Message (). Interface ().( * OpenIDConfig )
case "did.v1.Service.metadata" :
2024-08-31 12:49:44 -04:00
x . Metadata = value . Message (). Interface ().( * Metadata )
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Service" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Service does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Service.permissions" :
if x . Permissions == nil {
x . Permissions = new ( Permissions )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
return protoreflect . ValueOfMessage ( x . Permissions . ProtoReflect ())
case "did.v1.Service.openid" :
if x . Openid == nil {
x . Openid = new ( OpenIDConfig )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
return protoreflect . ValueOfMessage ( x . Openid . ProtoReflect ())
case "did.v1.Service.metadata" :
2024-08-31 12:49:44 -04:00
if x . Metadata == nil {
x . Metadata = new ( Metadata )
}
return protoreflect . ValueOfMessage ( x . Metadata . ProtoReflect ())
2024-09-05 01:24:57 -04:00
case "did.v1.Service.id" :
panic ( fmt . Errorf ( "field id of message did.v1.Service is not mutable" ))
case "did.v1.Service.controller" :
panic ( fmt . Errorf ( "field controller of message did.v1.Service is not mutable" ))
case "did.v1.Service.origin" :
panic ( fmt . Errorf ( "field origin of message did.v1.Service is not mutable" ))
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Service" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Service does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Service.id" :
2024-08-10 17:01:14 -04:00
return protoreflect . ValueOfString ( "" )
2024-09-05 01:24:57 -04:00
case "did.v1.Service.controller" :
2024-08-31 12:49:44 -04:00
return protoreflect . ValueOfString ( "" )
2024-09-05 01:24:57 -04:00
case "did.v1.Service.origin" :
2024-08-31 12:49:44 -04:00
return protoreflect . ValueOfString ( "" )
2024-09-05 01:24:57 -04:00
case "did.v1.Service.permissions" :
m := new ( Permissions )
return protoreflect . ValueOfMessage ( m . ProtoReflect ())
case "did.v1.Service.openid" :
m := new ( OpenIDConfig )
return protoreflect . ValueOfMessage ( m . ProtoReflect ())
case "did.v1.Service.metadata" :
2024-08-31 12:49:44 -04:00
m := new ( Metadata )
return protoreflect . ValueOfMessage ( m . ProtoReflect ())
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Service" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Service does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
2024-08-10 17:01:14 -04:00
switch d . FullName () {
default :
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.Service" , d . FullName ()))
2024-08-10 17:01:14 -04:00
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) GetUnknown () protoreflect . RawFields {
2024-08-10 17:01:14 -04:00
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) SetUnknown ( fields protoreflect . RawFields ) {
2024-08-10 17:01:14 -04:00
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) IsValid () bool {
2024-08-10 17:01:14 -04:00
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Service ) ProtoMethods () * protoiface . Methods {
2024-08-10 17:01:14 -04:00
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Service )
2024-08-10 17:01:14 -04:00
if x == nil {
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
}
}
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
2024-08-31 12:49:44 -04:00
l = len ( x . Id )
2024-08-10 17:01:14 -04:00
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
2024-09-05 01:24:57 -04:00
l = len ( x . Controller )
2024-08-31 12:49:44 -04:00
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
2024-09-05 01:24:57 -04:00
l = len ( x . Origin )
2024-08-31 12:49:44 -04:00
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
2024-09-05 01:24:57 -04:00
if x . Permissions != nil {
l = options . Size ( x . Permissions )
n += 1 + l + runtime . Sov ( uint64 ( l ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
if x . Openid != nil {
l = options . Size ( x . Openid )
n += 1 + l + runtime . Sov ( uint64 ( l ))
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
if x . Metadata != nil {
l = options . Size ( x . Metadata )
n += 1 + l + runtime . Sov ( uint64 ( l ))
2024-08-10 17:01:14 -04:00
}
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Service )
2024-08-10 17:01:14 -04:00
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
}
2024-08-31 12:49:44 -04:00
if x . Metadata != nil {
encoded , err := options . Marshal ( x . Metadata )
if err != nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, err
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
i -= len ( encoded )
copy ( dAtA [ i :], encoded )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( encoded )))
2024-08-10 17:19:59 -04:00
i --
2024-08-31 12:49:44 -04:00
dAtA [ i ] = 0x32
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
if x . Openid != nil {
encoded , err := options . Marshal ( x . Openid )
if err != nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, err
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
i -= len ( encoded )
copy ( dAtA [ i :], encoded )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( encoded )))
i --
dAtA [ i ] = 0x2a
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
if x . Permissions != nil {
encoded , err := options . Marshal ( x . Permissions )
if err != nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, err
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
i -= len ( encoded )
copy ( dAtA [ i :], encoded )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( encoded )))
i --
dAtA [ i ] = 0x22
}
if len ( x . Origin ) > 0 {
i -= len ( x . Origin )
copy ( dAtA [ i :], x . Origin )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Origin )))
i --
dAtA [ i ] = 0x1a
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
if len ( x . Controller ) > 0 {
i -= len ( x . Controller )
copy ( dAtA [ i :], x . Controller )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Controller )))
i --
dAtA [ i ] = 0x12
}
if len ( x . Id ) > 0 {
i -= len ( x . Id )
copy ( dAtA [ i :], x . Id )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Id )))
2024-08-10 17:01:14 -04:00
i --
dAtA [ i ] = 0xa
}
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Service )
2024-08-10 17:01:14 -04:00
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Service: wiretype end group for non-group" )
2024-08-10 17:01:14 -04:00
}
if fieldNum <= 0 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Service: illegal tag %d (wire type %d)" , fieldNum , wire )
2024-08-10 17:01:14 -04:00
}
switch fieldNum {
case 1 :
if wireType != 2 {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Id" , wireType )
2024-08-10 17:01:14 -04:00
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-08-31 12:49:44 -04:00
x . Id = string ( dAtA [ iNdEx : postIndex ])
2024-08-10 17:01:14 -04:00
iNdEx = postIndex
case 2 :
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Controller" , wireType )
2024-08-31 12:49:44 -04:00
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
x . Controller = string ( dAtA [ iNdEx : postIndex ])
2024-08-31 12:49:44 -04:00
iNdEx = postIndex
case 3 :
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Origin" , wireType )
2024-08-10 17:01:14 -04:00
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-08-31 12:49:44 -04:00
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
x . Origin = string ( dAtA [ iNdEx : postIndex ])
2024-08-31 12:49:44 -04:00
iNdEx = postIndex
case 4 :
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Permissions" , wireType )
2024-08-31 12:49:44 -04:00
}
var msglen int
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
msglen |= int ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
if x . Permissions == nil {
x . Permissions = & Permissions {}
}
if err := options . Unmarshal ( dAtA [ iNdEx : postIndex ], x . Permissions ); err != nil {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
iNdEx = postIndex
case 5 :
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Openid" , wireType )
2024-08-31 12:49:44 -04:00
}
var msglen int
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
msglen |= int ( b & 0x7F ) << shift
2024-08-10 17:01:14 -04:00
if b < 0x80 {
break
}
}
2024-08-31 12:49:44 -04:00
if msglen < 0 {
2024-08-10 17:01:14 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
2024-08-31 12:49:44 -04:00
postIndex := iNdEx + msglen
2024-08-10 17:01:14 -04:00
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
if x . Openid == nil {
x . Openid = & OpenIDConfig {}
}
if err := options . Unmarshal ( dAtA [ iNdEx : postIndex ], x . Openid ); err != nil {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
2024-08-10 17:01:14 -04:00
iNdEx = postIndex
2024-08-31 12:49:44 -04:00
case 6 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Metadata" , wireType )
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
var msglen int
2024-08-10 17:01:14 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-08-31 12:49:44 -04:00
msglen |= int ( b & 0x7F ) << shift
2024-08-10 17:01:14 -04:00
if b < 0x80 {
break
}
}
2024-08-31 12:49:44 -04:00
if msglen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
if postIndex > l {
2024-08-10 17:01:14 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-08-31 12:49:44 -04:00
if x . Metadata == nil {
x . Metadata = & Metadata {}
}
if err := options . Unmarshal ( dAtA [ iNdEx : postIndex ], x . Metadata ); err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
iNdEx = postIndex
2024-08-10 17:01:14 -04:00
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
}
}
var (
2024-09-05 01:24:57 -04:00
md_Token protoreflect . MessageDescriptor
fd_Token_id protoreflect . FieldDescriptor
fd_Token_controller protoreflect . FieldDescriptor
fd_Token_macron protoreflect . FieldDescriptor
2024-08-10 17:01:14 -04:00
)
func init () {
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_init ()
2024-09-05 01:24:57 -04:00
md_Token = File_did_v1_models_proto . Messages (). ByName ( "Token" )
fd_Token_id = md_Token . Fields (). ByName ( "id" )
fd_Token_controller = md_Token . Fields (). ByName ( "controller" )
fd_Token_macron = md_Token . Fields (). ByName ( "macron" )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . Message = ( * fastReflection_Token )( nil )
2024-08-10 17:01:14 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_Token Token
2024-08-10 17:01:14 -04:00
2024-09-05 01:24:57 -04:00
func ( x * Token ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_Token )( x )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * Token ) slowProtoReflect () protoreflect . Message {
mi := & file_did_v1_models_proto_msgTypes [ 10 ]
2024-08-10 17:01:14 -04:00
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
2024-09-05 01:24:57 -04:00
var _fastReflection_Token_messageType fastReflection_Token_messageType
var _ protoreflect . MessageType = fastReflection_Token_messageType {}
2024-08-10 17:01:14 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_Token_messageType struct {}
2024-08-10 17:01:14 -04:00
2024-09-05 01:24:57 -04:00
func ( x fastReflection_Token_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_Token )( nil )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_Token_messageType ) New () protoreflect . Message {
return new ( fastReflection_Token )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_Token_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_Token
2024-08-10 17:01:14 -04:00
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) Descriptor () protoreflect . MessageDescriptor {
return md_Token
2024-08-10 17:01:14 -04:00
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) Type () protoreflect . MessageType {
return _fastReflection_Token_messageType
2024-08-10 17:01:14 -04:00
}
// New returns a newly allocated and mutable empty message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) New () protoreflect . Message {
return new ( fastReflection_Token )
2024-08-10 17:01:14 -04:00
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) Interface () protoreflect . ProtoMessage {
return ( * Token )( x )
2024-08-10 17:01:14 -04:00
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
if x . Id != "" {
value := protoreflect . ValueOfString ( x . Id )
if ! f ( fd_Token_id , value ) {
return
}
}
if x . Controller != "" {
value := protoreflect . ValueOfString ( x . Controller )
if ! f ( fd_Token_controller , value ) {
2024-08-10 17:01:14 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if len ( x . Macron ) != 0 {
value := protoreflect . ValueOfBytes ( x . Macron )
if ! f ( fd_Token_macron , value ) {
2024-08-10 17:01:14 -04:00
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) Has ( fd protoreflect . FieldDescriptor ) bool {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Token.id" :
return x . Id != ""
case "did.v1.Token.controller" :
return x . Controller != ""
case "did.v1.Token.macron" :
return len ( x . Macron ) != 0
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Token" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Token does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) Clear ( fd protoreflect . FieldDescriptor ) {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Token.id" :
x . Id = ""
case "did.v1.Token.controller" :
x . Controller = ""
case "did.v1.Token.macron" :
x . Macron = nil
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Token" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Token does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:01:14 -04:00
switch descriptor . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Token.id" :
value := x . Id
return protoreflect . ValueOfString ( value )
case "did.v1.Token.controller" :
value := x . Controller
return protoreflect . ValueOfString ( value )
case "did.v1.Token.macron" :
value := x . Macron
2024-08-31 12:49:44 -04:00
return protoreflect . ValueOfBytes ( value )
2024-08-10 17:01:14 -04:00
default :
if descriptor . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Token" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Token does not contain field %s" , descriptor . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Token.id" :
x . Id = value . Interface ().( string )
case "did.v1.Token.controller" :
x . Controller = value . Interface ().( string )
case "did.v1.Token.macron" :
x . Macron = value . Bytes ()
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Token" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Token does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Token.id" :
panic ( fmt . Errorf ( "field id of message did.v1.Token is not mutable" ))
case "did.v1.Token.controller" :
panic ( fmt . Errorf ( "field controller of message did.v1.Token is not mutable" ))
case "did.v1.Token.macron" :
panic ( fmt . Errorf ( "field macron of message did.v1.Token is not mutable" ))
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Token" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Token does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Token.id" :
return protoreflect . ValueOfString ( "" )
case "did.v1.Token.controller" :
return protoreflect . ValueOfString ( "" )
case "did.v1.Token.macron" :
2024-08-31 12:49:44 -04:00
return protoreflect . ValueOfBytes ( nil )
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Token" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Token does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
2024-08-10 17:01:14 -04:00
switch d . FullName () {
default :
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.Token" , d . FullName ()))
2024-08-10 17:01:14 -04:00
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) GetUnknown () protoreflect . RawFields {
2024-08-10 17:01:14 -04:00
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) SetUnknown ( fields protoreflect . RawFields ) {
2024-08-10 17:01:14 -04:00
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) IsValid () bool {
2024-08-10 17:01:14 -04:00
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Token ) ProtoMethods () * protoiface . Methods {
2024-08-10 17:01:14 -04:00
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Token )
2024-08-10 17:01:14 -04:00
if x == nil {
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
}
}
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
2024-09-05 01:24:57 -04:00
l = len ( x . Id )
2024-08-10 17:01:14 -04:00
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
2024-09-05 01:24:57 -04:00
l = len ( x . Controller )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
l = len ( x . Macron )
2024-08-10 17:01:14 -04:00
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Token )
2024-08-10 17:01:14 -04:00
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
if len ( x . Macron ) > 0 {
i -= len ( x . Macron )
copy ( dAtA [ i :], x . Macron )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Macron )))
i --
dAtA [ i ] = 0x1a
}
if len ( x . Controller ) > 0 {
i -= len ( x . Controller )
copy ( dAtA [ i :], x . Controller )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Controller )))
2024-08-10 17:01:14 -04:00
i --
dAtA [ i ] = 0x12
}
2024-09-05 01:24:57 -04:00
if len ( x . Id ) > 0 {
i -= len ( x . Id )
copy ( dAtA [ i :], x . Id )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Id )))
2024-08-10 17:01:14 -04:00
i --
dAtA [ i ] = 0xa
}
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Token )
2024-08-10 17:01:14 -04:00
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Token: wiretype end group for non-group" )
2024-08-10 17:01:14 -04:00
}
if fieldNum <= 0 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Token: illegal tag %d (wire type %d)" , fieldNum , wire )
2024-08-10 17:01:14 -04:00
}
switch fieldNum {
case 1 :
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Id" , wireType )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
var stringLen uint64
2024-08-10 17:01:14 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-09-05 01:24:57 -04:00
stringLen |= uint64 ( b & 0x7F ) << shift
2024-08-10 17:01:14 -04:00
if b < 0x80 {
break
}
}
2024-09-05 01:24:57 -04:00
intStringLen := int ( stringLen )
if intStringLen < 0 {
2024-08-10 17:01:14 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
2024-09-05 01:24:57 -04:00
postIndex := iNdEx + intStringLen
2024-08-10 17:01:14 -04:00
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
x . Id = string ( dAtA [ iNdEx : postIndex ])
2024-08-10 17:01:14 -04:00
iNdEx = postIndex
2024-08-31 12:49:44 -04:00
case 2 :
2024-08-10 17:01:14 -04:00
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Controller" , wireType )
}
var stringLen uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
stringLen |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Controller = string ( dAtA [ iNdEx : postIndex ])
iNdEx = postIndex
case 3 :
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Macron" , wireType )
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
var byteLen int
2024-08-10 17:01:14 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-08-31 12:49:44 -04:00
byteLen |= int ( b & 0x7F ) << shift
2024-08-10 17:01:14 -04:00
if b < 0x80 {
break
}
}
2024-08-31 12:49:44 -04:00
if byteLen < 0 {
2024-08-10 17:01:14 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
2024-08-31 12:49:44 -04:00
postIndex := iNdEx + byteLen
2024-08-10 17:01:14 -04:00
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
x . Macron = append ( x . Macron [: 0 ], dAtA [ iNdEx : postIndex ] ... )
if x . Macron == nil {
x . Macron = [] byte {}
2024-08-10 17:01:14 -04:00
}
iNdEx = postIndex
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
}
}
var (
2024-09-05 01:24:57 -04:00
md_VerificationMethod protoreflect . MessageDescriptor
fd_VerificationMethod_id protoreflect . FieldDescriptor
fd_VerificationMethod_controller protoreflect . FieldDescriptor
fd_VerificationMethod_method protoreflect . FieldDescriptor
fd_VerificationMethod_public_key protoreflect . FieldDescriptor
fd_VerificationMethod_service protoreflect . FieldDescriptor
2024-08-10 17:01:14 -04:00
)
func init () {
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_init ()
2024-09-05 01:24:57 -04:00
md_VerificationMethod = File_did_v1_models_proto . Messages (). ByName ( "VerificationMethod" )
fd_VerificationMethod_id = md_VerificationMethod . Fields (). ByName ( "id" )
fd_VerificationMethod_controller = md_VerificationMethod . Fields (). ByName ( "controller" )
fd_VerificationMethod_method = md_VerificationMethod . Fields (). ByName ( "method" )
fd_VerificationMethod_public_key = md_VerificationMethod . Fields (). ByName ( "public_key" )
fd_VerificationMethod_service = md_VerificationMethod . Fields (). ByName ( "service" )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . Message = ( * fastReflection_VerificationMethod )( nil )
2024-08-10 17:01:14 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_VerificationMethod VerificationMethod
2024-08-10 17:01:14 -04:00
2024-09-05 01:24:57 -04:00
func ( x * VerificationMethod ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_VerificationMethod )( x )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * VerificationMethod ) slowProtoReflect () protoreflect . Message {
mi := & file_did_v1_models_proto_msgTypes [ 11 ]
2024-08-10 17:01:14 -04:00
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
2024-09-05 01:24:57 -04:00
var _fastReflection_VerificationMethod_messageType fastReflection_VerificationMethod_messageType
var _ protoreflect . MessageType = fastReflection_VerificationMethod_messageType {}
2024-08-10 17:01:14 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_VerificationMethod_messageType struct {}
2024-08-10 17:01:14 -04:00
2024-09-05 01:24:57 -04:00
func ( x fastReflection_VerificationMethod_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_VerificationMethod )( nil )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_VerificationMethod_messageType ) New () protoreflect . Message {
return new ( fastReflection_VerificationMethod )
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_VerificationMethod_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_VerificationMethod
2024-08-10 17:01:14 -04:00
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) Descriptor () protoreflect . MessageDescriptor {
return md_VerificationMethod
2024-08-10 17:01:14 -04:00
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) Type () protoreflect . MessageType {
return _fastReflection_VerificationMethod_messageType
2024-08-10 17:01:14 -04:00
}
// New returns a newly allocated and mutable empty message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) New () protoreflect . Message {
return new ( fastReflection_VerificationMethod )
2024-08-10 17:01:14 -04:00
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) Interface () protoreflect . ProtoMessage {
return ( * VerificationMethod )( x )
2024-08-10 17:01:14 -04:00
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
if x . Id != "" {
value := protoreflect . ValueOfString ( x . Id )
if ! f ( fd_VerificationMethod_id , value ) {
2024-08-10 17:01:14 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if x . Controller != "" {
value := protoreflect . ValueOfString ( x . Controller )
if ! f ( fd_VerificationMethod_controller , value ) {
2024-08-10 17:01:14 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if x . Method != 0 {
value := protoreflect . ValueOfEnum (( protoreflect . EnumNumber )( x . Method ))
if ! f ( fd_VerificationMethod_method , value ) {
2024-08-10 17:01:14 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if x . PublicKey != nil {
value := protoreflect . ValueOfMessage ( x . PublicKey . ProtoReflect ())
if ! f ( fd_VerificationMethod_public_key , value ) {
2024-08-31 12:49:44 -04:00
return
}
}
2024-09-05 01:24:57 -04:00
if x . Service != nil {
value := protoreflect . ValueOfMessage ( x . Service . ProtoReflect ())
if ! f ( fd_VerificationMethod_service , value ) {
2024-08-10 17:01:14 -04:00
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) Has ( fd protoreflect . FieldDescriptor ) bool {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.VerificationMethod.id" :
return x . Id != ""
case "did.v1.VerificationMethod.controller" :
return x . Controller != ""
case "did.v1.VerificationMethod.method" :
return x . Method != 0
case "did.v1.VerificationMethod.public_key" :
return x . PublicKey != nil
case "did.v1.VerificationMethod.service" :
return x . Service != nil
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.VerificationMethod" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.VerificationMethod does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) Clear ( fd protoreflect . FieldDescriptor ) {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.VerificationMethod.id" :
x . Id = ""
case "did.v1.VerificationMethod.controller" :
x . Controller = ""
case "did.v1.VerificationMethod.method" :
x . Method = 0
case "did.v1.VerificationMethod.public_key" :
x . PublicKey = nil
case "did.v1.VerificationMethod.service" :
x . Service = nil
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.VerificationMethod" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.VerificationMethod does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:01:14 -04:00
switch descriptor . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.VerificationMethod.id" :
value := x . Id
2024-08-10 17:01:14 -04:00
return protoreflect . ValueOfString ( value )
2024-09-05 01:24:57 -04:00
case "did.v1.VerificationMethod.controller" :
value := x . Controller
return protoreflect . ValueOfString ( value )
case "did.v1.VerificationMethod.method" :
value := x . Method
return protoreflect . ValueOfEnum (( protoreflect . EnumNumber )( value ))
case "did.v1.VerificationMethod.public_key" :
value := x . PublicKey
return protoreflect . ValueOfMessage ( value . ProtoReflect ())
case "did.v1.VerificationMethod.service" :
value := x . Service
return protoreflect . ValueOfMessage ( value . ProtoReflect ())
2024-08-10 17:01:14 -04:00
default :
if descriptor . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.VerificationMethod" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.VerificationMethod does not contain field %s" , descriptor . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.VerificationMethod.id" :
x . Id = value . Interface ().( string )
case "did.v1.VerificationMethod.controller" :
x . Controller = value . Interface ().( string )
case "did.v1.VerificationMethod.method" :
x . Method = ( DIDNamespace )( value . Enum ())
case "did.v1.VerificationMethod.public_key" :
x . PublicKey = value . Message (). Interface ().( * PubKey )
case "did.v1.VerificationMethod.service" :
x . Service = value . Message (). Interface ().( * Service )
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.VerificationMethod" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.VerificationMethod does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.VerificationMethod.public_key" :
if x . PublicKey == nil {
x . PublicKey = new ( PubKey )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
return protoreflect . ValueOfMessage ( x . PublicKey . ProtoReflect ())
case "did.v1.VerificationMethod.service" :
if x . Service == nil {
x . Service = new ( Service )
}
return protoreflect . ValueOfMessage ( x . Service . ProtoReflect ())
case "did.v1.VerificationMethod.id" :
panic ( fmt . Errorf ( "field id of message did.v1.VerificationMethod is not mutable" ))
case "did.v1.VerificationMethod.controller" :
panic ( fmt . Errorf ( "field controller of message did.v1.VerificationMethod is not mutable" ))
case "did.v1.VerificationMethod.method" :
panic ( fmt . Errorf ( "field method of message did.v1.VerificationMethod is not mutable" ))
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.VerificationMethod" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.VerificationMethod does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-08-10 17:01:14 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.VerificationMethod.id" :
2024-08-10 17:01:14 -04:00
return protoreflect . ValueOfString ( "" )
2024-09-05 01:24:57 -04:00
case "did.v1.VerificationMethod.controller" :
return protoreflect . ValueOfString ( "" )
case "did.v1.VerificationMethod.method" :
return protoreflect . ValueOfEnum ( 0 )
case "did.v1.VerificationMethod.public_key" :
m := new ( PubKey )
return protoreflect . ValueOfMessage ( m . ProtoReflect ())
case "did.v1.VerificationMethod.service" :
m := new ( Service )
return protoreflect . ValueOfMessage ( m . ProtoReflect ())
2024-08-10 17:01:14 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.VerificationMethod" ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.VerificationMethod does not contain field %s" , fd . FullName ()))
2024-08-10 17:01:14 -04:00
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
2024-08-10 17:01:14 -04:00
switch d . FullName () {
default :
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.VerificationMethod" , d . FullName ()))
2024-08-10 17:01:14 -04:00
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) GetUnknown () protoreflect . RawFields {
2024-08-10 17:01:14 -04:00
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) SetUnknown ( fields protoreflect . RawFields ) {
2024-08-10 17:01:14 -04:00
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) IsValid () bool {
2024-08-10 17:01:14 -04:00
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_VerificationMethod ) ProtoMethods () * protoiface . Methods {
2024-08-10 17:01:14 -04:00
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * VerificationMethod )
2024-08-10 17:01:14 -04:00
if x == nil {
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
}
}
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
2024-09-05 01:24:57 -04:00
l = len ( x . Id )
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
l = len ( x . Controller )
2024-08-10 17:01:14 -04:00
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
2024-09-05 01:24:57 -04:00
if x . Method != 0 {
n += 1 + runtime . Sov ( uint64 ( x . Method ))
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
if x . PublicKey != nil {
l = options . Size ( x . PublicKey )
2024-08-10 17:01:14 -04:00
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
2024-09-05 01:24:57 -04:00
if x . Service != nil {
l = options . Size ( x . Service )
n += 1 + l + runtime . Sov ( uint64 ( l ))
2024-08-31 12:49:44 -04:00
}
2024-08-10 17:01:14 -04:00
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * VerificationMethod )
2024-08-10 17:01:14 -04:00
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
}
2024-09-05 01:24:57 -04:00
if x . Service != nil {
encoded , err := options . Marshal ( x . Service )
if err != nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, err
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
i -= len ( encoded )
copy ( dAtA [ i :], encoded )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( encoded )))
i --
dAtA [ i ] = 0x3a
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
if x . PublicKey != nil {
encoded , err := options . Marshal ( x . PublicKey )
if err != nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, err
}
i -= len ( encoded )
copy ( dAtA [ i :], encoded )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( encoded )))
2024-08-10 17:01:14 -04:00
i --
2024-09-05 01:24:57 -04:00
dAtA [ i ] = 0x22
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
if x . Method != 0 {
i = runtime . EncodeVarint ( dAtA , i , uint64 ( x . Method ))
2024-08-10 17:01:14 -04:00
i --
2024-08-31 12:49:44 -04:00
dAtA [ i ] = 0x18
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
if len ( x . Controller ) > 0 {
i -= len ( x . Controller )
copy ( dAtA [ i :], x . Controller )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Controller )))
2024-08-10 17:01:14 -04:00
i --
dAtA [ i ] = 0x12
}
2024-09-05 01:24:57 -04:00
if len ( x . Id ) > 0 {
i -= len ( x . Id )
copy ( dAtA [ i :], x . Id )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Id )))
2024-08-10 17:01:14 -04:00
i --
2024-09-05 01:24:57 -04:00
dAtA [ i ] = 0xa
2024-08-10 17:01:14 -04:00
}
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * VerificationMethod )
2024-08-10 17:01:14 -04:00
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
2024-07-05 22:20:13 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-08-10 17:01:14 -04:00
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
2024-07-05 22:20:13 -04:00
}
2024-08-10 17:01:14 -04:00
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: VerificationMethod: wiretype end group for non-group" )
2024-08-10 17:01:14 -04:00
}
if fieldNum <= 0 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: VerificationMethod: illegal tag %d (wire type %d)" , fieldNum , wire )
2024-08-10 17:01:14 -04:00
}
switch fieldNum {
case 1 :
2024-09-05 01:24:57 -04:00
if wireType != 2 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Id" , wireType )
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
var stringLen uint64
2024-07-05 22:20:13 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-09-05 01:24:57 -04:00
stringLen |= uint64 ( b & 0x7F ) << shift
2024-07-05 22:20:13 -04:00
if b < 0x80 {
break
}
}
2024-09-05 01:24:57 -04:00
intStringLen := int ( stringLen )
if intStringLen < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
x . Id = string ( dAtA [ iNdEx : postIndex ])
iNdEx = postIndex
2024-08-10 17:01:14 -04:00
case 2 :
2024-07-05 22:20:13 -04:00
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Controller" , wireType )
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
var stringLen uint64
2024-07-05 22:20:13 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-09-05 01:24:57 -04:00
stringLen |= uint64 ( b & 0x7F ) << shift
2024-07-05 22:20:13 -04:00
if b < 0x80 {
break
}
}
2024-09-05 01:24:57 -04:00
intStringLen := int ( stringLen )
if intStringLen < 0 {
2024-07-05 22:20:13 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
2024-09-05 01:24:57 -04:00
postIndex := iNdEx + intStringLen
2024-07-05 22:20:13 -04:00
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
x . Controller = string ( dAtA [ iNdEx : postIndex ])
2024-07-05 22:20:13 -04:00
iNdEx = postIndex
2024-08-10 17:01:14 -04:00
case 3 :
2024-08-31 12:49:44 -04:00
if wireType != 0 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Method" , wireType )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
x . Method = 0
2024-08-31 12:49:44 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-09-05 01:24:57 -04:00
x . Method |= DIDNamespace ( b & 0x7F ) << shift
2024-08-31 12:49:44 -04:00
if b < 0x80 {
break
}
}
2024-09-05 01:24:57 -04:00
case 4 :
2024-07-05 22:20:13 -04:00
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field PublicKey" , wireType )
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
var msglen int
2024-07-05 22:20:13 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-09-05 01:24:57 -04:00
msglen |= int ( b & 0x7F ) << shift
2024-07-05 22:20:13 -04:00
if b < 0x80 {
break
}
}
2024-09-05 01:24:57 -04:00
if msglen < 0 {
2024-07-05 22:20:13 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
2024-09-05 01:24:57 -04:00
postIndex := iNdEx + msglen
2024-07-05 22:20:13 -04:00
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
if x . PublicKey == nil {
x . PublicKey = & PubKey {}
}
if err := options . Unmarshal ( dAtA [ iNdEx : postIndex ], x . PublicKey ); err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
2024-07-05 22:20:13 -04:00
iNdEx = postIndex
2024-09-05 01:24:57 -04:00
case 7 :
2024-07-05 22:20:13 -04:00
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Service" , wireType )
2024-07-05 22:20:13 -04:00
}
2024-08-31 12:49:44 -04:00
var msglen int
2024-07-05 22:20:13 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-08-31 12:49:44 -04:00
msglen |= int ( b & 0x7F ) << shift
2024-07-05 22:20:13 -04:00
if b < 0x80 {
break
}
}
2024-08-31 12:49:44 -04:00
if msglen < 0 {
2024-07-05 22:20:13 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
2024-08-31 12:49:44 -04:00
postIndex := iNdEx + msglen
2024-07-05 22:20:13 -04:00
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
if x . Service == nil {
x . Service = & Service {}
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
if err := options . Unmarshal ( dAtA [ iNdEx : postIndex ], x . Service ); err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
2024-08-31 12:49:44 -04:00
}
2024-07-05 22:20:13 -04:00
iNdEx = postIndex
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
}
}
var (
2024-09-05 01:24:57 -04:00
md_Witness protoreflect . MessageDescriptor
fd_Witness_witness protoreflect . FieldDescriptor
2024-07-05 22:20:13 -04:00
)
func init () {
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_init ()
2024-09-05 01:24:57 -04:00
md_Witness = File_did_v1_models_proto . Messages (). ByName ( "Witness" )
fd_Witness_witness = md_Witness . Fields (). ByName ( "witness" )
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
var _ protoreflect . Message = ( * fastReflection_Witness )( nil )
2024-07-05 22:20:13 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_Witness Witness
2024-07-05 22:20:13 -04:00
2024-09-05 01:24:57 -04:00
func ( x * Witness ) ProtoReflect () protoreflect . Message {
return ( * fastReflection_Witness )( x )
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * Witness ) slowProtoReflect () protoreflect . Message {
mi := & file_did_v1_models_proto_msgTypes [ 12 ]
2024-07-05 22:20:13 -04:00
if protoimpl . UnsafeEnabled && x != nil {
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
if ms . LoadMessageInfo () == nil {
ms . StoreMessageInfo ( mi )
}
return ms
}
return mi . MessageOf ( x )
}
2024-09-05 01:24:57 -04:00
var _fastReflection_Witness_messageType fastReflection_Witness_messageType
var _ protoreflect . MessageType = fastReflection_Witness_messageType {}
2024-07-05 22:20:13 -04:00
2024-09-05 01:24:57 -04:00
type fastReflection_Witness_messageType struct {}
2024-07-05 22:20:13 -04:00
2024-09-05 01:24:57 -04:00
func ( x fastReflection_Witness_messageType ) Zero () protoreflect . Message {
return ( * fastReflection_Witness )( nil )
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_Witness_messageType ) New () protoreflect . Message {
return new ( fastReflection_Witness )
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x fastReflection_Witness_messageType ) Descriptor () protoreflect . MessageDescriptor {
return md_Witness
2024-07-05 22:20:13 -04:00
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) Descriptor () protoreflect . MessageDescriptor {
return md_Witness
2024-07-05 22:20:13 -04:00
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) Type () protoreflect . MessageType {
return _fastReflection_Witness_messageType
2024-07-05 22:20:13 -04:00
}
// New returns a newly allocated and mutable empty message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) New () protoreflect . Message {
return new ( fastReflection_Witness )
2024-07-05 22:20:13 -04:00
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) Interface () protoreflect . ProtoMessage {
return ( * Witness )( x )
2024-07-05 22:20:13 -04:00
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) Range ( f func ( protoreflect . FieldDescriptor , protoreflect . Value ) bool ) {
if len ( x . Witness ) != 0 {
value := protoreflect . ValueOfBytes ( x . Witness )
if ! f ( fd_Witness_witness , value ) {
2024-07-05 22:20:13 -04:00
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) Has ( fd protoreflect . FieldDescriptor ) bool {
2024-07-05 22:20:13 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Witness.witness" :
return len ( x . Witness ) != 0
2024-07-05 22:20:13 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Witness" ))
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Witness does not contain field %s" , fd . FullName ()))
2024-07-05 22:20:13 -04:00
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) Clear ( fd protoreflect . FieldDescriptor ) {
2024-07-05 22:20:13 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Witness.witness" :
x . Witness = nil
2024-07-05 22:20:13 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Witness" ))
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Witness does not contain field %s" , fd . FullName ()))
2024-07-05 22:20:13 -04:00
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) Get ( descriptor protoreflect . FieldDescriptor ) protoreflect . Value {
2024-07-05 22:20:13 -04:00
switch descriptor . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Witness.witness" :
value := x . Witness
return protoreflect . ValueOfBytes ( value )
2024-07-05 22:20:13 -04:00
default :
if descriptor . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Witness" ))
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Witness does not contain field %s" , descriptor . FullName ()))
2024-07-05 22:20:13 -04:00
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
2024-09-05 01:24:57 -04:00
//
// Set is a mutating operation and unsafe for concurrent use.
func ( x * fastReflection_Witness ) Set ( fd protoreflect . FieldDescriptor , value protoreflect . Value ) {
switch fd . FullName () {
case "did.v1.Witness.witness" :
x . Witness = value . Bytes ()
2024-07-05 22:20:13 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Witness" ))
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Witness does not contain field %s" , fd . FullName ()))
2024-07-05 22:20:13 -04:00
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) Mutable ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-07-05 22:20:13 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Witness.witness" :
panic ( fmt . Errorf ( "field witness of message did.v1.Witness is not mutable" ))
2024-07-05 22:20:13 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Witness" ))
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Witness does not contain field %s" , fd . FullName ()))
2024-07-05 22:20:13 -04:00
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) NewField ( fd protoreflect . FieldDescriptor ) protoreflect . Value {
2024-07-05 22:20:13 -04:00
switch fd . FullName () {
2024-09-05 01:24:57 -04:00
case "did.v1.Witness.witness" :
return protoreflect . ValueOfBytes ( nil )
2024-07-05 22:20:13 -04:00
default :
if fd . IsExtension () {
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "proto3 declared messages do not support extensions: did.v1.Witness" ))
2024-07-05 22:20:13 -04:00
}
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "message did.v1.Witness does not contain field %s" , fd . FullName ()))
2024-07-05 22:20:13 -04:00
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) WhichOneof ( d protoreflect . OneofDescriptor ) protoreflect . FieldDescriptor {
2024-07-05 22:20:13 -04:00
switch d . FullName () {
default :
2024-09-05 01:24:57 -04:00
panic ( fmt . Errorf ( "%s is not a oneof field in did.v1.Witness" , d . FullName ()))
2024-07-05 22:20:13 -04:00
}
panic ( "unreachable" )
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) GetUnknown () protoreflect . RawFields {
2024-07-05 22:20:13 -04:00
return x . unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) SetUnknown ( fields protoreflect . RawFields ) {
2024-07-05 22:20:13 -04:00
x . unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) IsValid () bool {
2024-07-05 22:20:13 -04:00
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
2024-09-05 01:24:57 -04:00
func ( x * fastReflection_Witness ) ProtoMethods () * protoiface . Methods {
2024-07-05 22:20:13 -04:00
size := func ( input protoiface . SizeInput ) protoiface . SizeOutput {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Witness )
2024-07-05 22:20:13 -04:00
if x == nil {
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : 0 ,
}
}
options := runtime . SizeInputToOptions ( input )
_ = options
var n int
var l int
_ = l
2024-09-05 01:24:57 -04:00
l = len ( x . Witness )
2024-07-05 22:20:13 -04:00
if l > 0 {
n += 1 + l + runtime . Sov ( uint64 ( l ))
}
if x . unknownFields != nil {
n += len ( x . unknownFields )
}
return protoiface . SizeOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Size : n ,
}
}
marshal := func ( input protoiface . MarshalInput ) ( protoiface . MarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Witness )
2024-07-05 22:20:13 -04:00
if x == nil {
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
options := runtime . MarshalInputToOptions ( input )
_ = options
size := options . Size ( x )
dAtA := make ([] byte , size )
i := len ( dAtA )
_ = i
var l int
_ = l
if x . unknownFields != nil {
i -= len ( x . unknownFields )
copy ( dAtA [ i :], x . unknownFields )
}
2024-09-05 01:24:57 -04:00
if len ( x . Witness ) > 0 {
i -= len ( x . Witness )
copy ( dAtA [ i :], x . Witness )
i = runtime . EncodeVarint ( dAtA , i , uint64 ( len ( x . Witness )))
2024-07-05 22:20:13 -04:00
i --
dAtA [ i ] = 0xa
}
if input . Buf != nil {
input . Buf = append ( input . Buf , dAtA ... )
} else {
input . Buf = dAtA
}
return protoiface . MarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Buf : input . Buf ,
}, nil
}
unmarshal := func ( input protoiface . UnmarshalInput ) ( protoiface . UnmarshalOutput , error ) {
2024-09-05 01:24:57 -04:00
x := input . Message . Interface ().( * Witness )
2024-07-05 22:20:13 -04:00
if x == nil {
return protoiface . UnmarshalOutput {
NoUnkeyedLiterals : input . NoUnkeyedLiterals ,
Flags : input . Flags ,
}, nil
}
options := runtime . UnmarshalInputToOptions ( input )
_ = options
dAtA := input . Buf
l := len ( dAtA )
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
}
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
wire |= uint64 ( b & 0x7F ) << shift
if b < 0x80 {
break
}
}
fieldNum := int32 ( wire >> 3 )
wireType := int ( wire & 0x7 )
if wireType == 4 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Witness: wiretype end group for non-group" )
2024-07-05 22:20:13 -04:00
}
if fieldNum <= 0 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: Witness: illegal tag %d (wire type %d)" , fieldNum , wire )
2024-07-05 22:20:13 -04:00
}
switch fieldNum {
case 1 :
if wireType != 2 {
2024-09-05 01:24:57 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, fmt . Errorf ( "proto: wrong wireType = %d for field Witness" , wireType )
2024-08-31 12:49:44 -04:00
}
2024-09-05 01:24:57 -04:00
var byteLen int
2024-08-31 12:49:44 -04:00
for shift := uint ( 0 ); ; shift += 7 {
if shift >= 64 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrIntOverflow
2024-07-06 03:02:45 -04:00
}
2024-08-31 12:49:44 -04:00
if iNdEx >= l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
b := dAtA [ iNdEx ]
iNdEx ++
2024-09-05 01:24:57 -04:00
byteLen |= int ( b & 0x7F ) << shift
2024-08-31 12:49:44 -04:00
if b < 0x80 {
break
}
}
2024-09-05 01:24:57 -04:00
if byteLen < 0 {
2024-08-31 12:49:44 -04:00
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
2024-09-05 01:24:57 -04:00
postIndex := iNdEx + byteLen
2024-08-31 12:49:44 -04:00
if postIndex < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if postIndex > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
2024-09-05 01:24:57 -04:00
x . Witness = append ( x . Witness [: 0 ], dAtA [ iNdEx : postIndex ] ... )
if x . Witness == nil {
x . Witness = [] byte {}
2024-07-05 22:20:13 -04:00
}
iNdEx = postIndex
default :
iNdEx = preIndex
skippy , err := runtime . Skip ( dAtA [ iNdEx :])
if err != nil {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, err
}
if ( skippy < 0 ) || ( iNdEx + skippy ) < 0 {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, runtime . ErrInvalidLength
}
if ( iNdEx + skippy ) > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
if ! options . DiscardUnknown {
x . unknownFields = append ( x . unknownFields , dAtA [ iNdEx : iNdEx + skippy ] ... )
}
iNdEx += skippy
}
}
2024-08-10 17:19:59 -04:00
if iNdEx > l {
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, io . ErrUnexpectedEOF
}
return protoiface . UnmarshalOutput { NoUnkeyedLiterals : input . NoUnkeyedLiterals , Flags : input . Flags }, nil
}
return & protoiface . Methods {
NoUnkeyedLiterals : struct {}{},
Flags : protoiface . SupportMarshalDeterministic | protoiface . SupportUnmarshalDiscardUnknown ,
Size : size ,
Marshal : marshal ,
Unmarshal : unmarshal ,
Merge : nil ,
CheckInitialized : nil ,
}
}
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.27.0
// protoc (unknown)
2024-08-31 12:49:44 -04:00
// source: did/v1/models.proto
2024-08-10 17:19:59 -04:00
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl . EnforceVersion ( 20 - protoimpl . MinVersion )
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl . EnforceVersion ( protoimpl . MaxVersion - 20 )
)
2024-09-05 01:24:57 -04:00
// Accumulator defines a BLS accumulator
type Accumulator struct {
2024-08-10 17:19:59 -04:00
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
2024-09-05 01:24:57 -04:00
Accumulator [] byte `protobuf:"bytes,1,opt,name=accumulator,proto3" json:"accumulator,omitempty"`
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * Accumulator ) Reset () {
* x = Accumulator {}
2024-08-10 17:19:59 -04:00
if protoimpl . UnsafeEnabled {
2024-08-31 12:49:44 -04:00
mi := & file_did_v1_models_proto_msgTypes [ 0 ]
2024-08-10 17:19:59 -04:00
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
2024-07-05 22:20:13 -04:00
}
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * Accumulator ) String () string {
2024-08-10 17:19:59 -04:00
return protoimpl . X . MessageStringOf ( x )
}
2024-09-05 01:24:57 -04:00
func ( * Accumulator ) ProtoMessage () {}
2024-08-10 17:19:59 -04:00
2024-09-05 01:24:57 -04:00
// Deprecated: Use Accumulator.ProtoReflect.Descriptor instead.
func ( * Accumulator ) Descriptor () ([] byte , [] int ) {
2024-08-31 12:49:44 -04:00
return file_did_v1_models_proto_rawDescGZIP (), [] int { 0 }
2024-08-10 17:19:59 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * Accumulator ) GetAccumulator () [] byte {
2024-08-10 17:19:59 -04:00
if x != nil {
2024-09-05 01:24:57 -04:00
return x . Accumulator
2024-08-10 17:19:59 -04:00
}
return nil
}
2024-07-05 22:20:13 -04:00
2024-08-10 17:01:14 -04:00
// Credential defines a WebAuthn credential
type Credential struct {
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
2024-08-31 12:49:44 -04:00
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
CredentialType string `protobuf:"bytes,2,opt,name=credential_type,json=credentialType,proto3" json:"credential_type,omitempty"`
CredentialId [] byte `protobuf:"bytes,3,opt,name=credential_id,json=credentialId,proto3" json:"credential_id,omitempty"`
Transport [] string `protobuf:"bytes,4,rep,name=transport,proto3" json:"transport,omitempty"`
Subject string `protobuf:"bytes,6,opt,name=subject,proto3" json:"subject,omitempty"`
Controller string `protobuf:"bytes,7,opt,name=controller,proto3" json:"controller,omitempty"`
2024-08-10 17:01:14 -04:00
}
func ( x * Credential ) Reset () {
* x = Credential {}
if protoimpl . UnsafeEnabled {
2024-08-31 12:49:44 -04:00
mi := & file_did_v1_models_proto_msgTypes [ 1 ]
2024-08-10 17:01:14 -04:00
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
}
}
func ( x * Credential ) String () string {
return protoimpl . X . MessageStringOf ( x )
}
func ( * Credential ) ProtoMessage () {}
// Deprecated: Use Credential.ProtoReflect.Descriptor instead.
func ( * Credential ) Descriptor () ([] byte , [] int ) {
2024-08-31 12:49:44 -04:00
return file_did_v1_models_proto_rawDescGZIP (), [] int { 1 }
2024-08-10 17:01:14 -04:00
}
func ( x * Credential ) GetId () string {
if x != nil {
return x . Id
}
return ""
}
2024-09-05 01:24:57 -04:00
func ( x * Credential ) GetCredentialType () string {
if x != nil {
return x . CredentialType
}
return ""
}
func ( x * Credential ) GetCredentialId () [] byte {
if x != nil {
return x . CredentialId
}
return nil
}
func ( x * Credential ) GetTransport () [] string {
if x != nil {
return x . Transport
}
return nil
}
func ( x * Credential ) GetSubject () string {
if x != nil {
return x . Subject
}
return ""
}
func ( x * Credential ) GetController () string {
if x != nil {
return x . Controller
}
return ""
}
// DID defines a parsed DID string
type DID struct {
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
Method DIDNamespace `protobuf:"varint,1,opt,name=method,proto3,enum=did.v1.DIDNamespace" json:"method,omitempty"`
Network string `protobuf:"bytes,2,opt,name=network,proto3" json:"network,omitempty"`
Subject string `protobuf:"bytes,3,opt,name=subject,proto3" json:"subject,omitempty"`
Identifier string `protobuf:"bytes,4,opt,name=identifier,proto3" json:"identifier,omitempty"`
Paths [] string `protobuf:"bytes,5,rep,name=paths,proto3" json:"paths,omitempty"`
}
func ( x * DID ) Reset () {
* x = DID {}
if protoimpl . UnsafeEnabled {
mi := & file_did_v1_models_proto_msgTypes [ 2 ]
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
}
}
func ( x * DID ) String () string {
return protoimpl . X . MessageStringOf ( x )
}
func ( * DID ) ProtoMessage () {}
// Deprecated: Use DID.ProtoReflect.Descriptor instead.
func ( * DID ) Descriptor () ([] byte , [] int ) {
return file_did_v1_models_proto_rawDescGZIP (), [] int { 2 }
}
func ( x * DID ) GetMethod () DIDNamespace {
2024-08-10 17:01:14 -04:00
if x != nil {
2024-09-05 01:24:57 -04:00
return x . Method
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
return DIDNamespace_DID_NAMESPACE_UNSPECIFIED
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * DID ) GetNetwork () string {
2024-08-10 17:01:14 -04:00
if x != nil {
2024-09-05 01:24:57 -04:00
return x . Network
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
return ""
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * DID ) GetSubject () string {
2024-08-10 17:01:14 -04:00
if x != nil {
2024-09-05 01:24:57 -04:00
return x . Subject
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
return ""
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * DID ) GetIdentifier () string {
2024-08-10 17:01:14 -04:00
if x != nil {
2024-09-05 01:24:57 -04:00
return x . Identifier
2024-08-10 17:01:14 -04:00
}
return ""
}
2024-09-05 01:24:57 -04:00
func ( x * DID ) GetPaths () [] string {
2024-08-10 17:01:14 -04:00
if x != nil {
2024-09-05 01:24:57 -04:00
return x . Paths
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
return nil
2024-08-10 17:01:14 -04:00
}
// Document defines a DID document
type Document struct {
2024-07-05 22:20:13 -04:00
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
VerificationMethods [] * VerificationMethod `protobuf:"bytes,2,rep,name=verification_methods,json=verificationMethods,proto3" json:"verification_methods,omitempty"`
Authentication [] string `protobuf:"bytes,4,rep,name=authentication,proto3" json:"authentication,omitempty"`
AssertionMethod [] string `protobuf:"bytes,5,rep,name=assertion_method,json=assertionMethod,proto3" json:"assertion_method,omitempty"`
CapabilityDelegation [] string `protobuf:"bytes,7,rep,name=capability_delegation,json=capabilityDelegation,proto3" json:"capability_delegation,omitempty"`
CapabilityInvocation [] string `protobuf:"bytes,8,rep,name=capability_invocation,json=capabilityInvocation,proto3" json:"capability_invocation,omitempty"`
2024-09-05 01:24:57 -04:00
Service [] string `protobuf:"bytes,9,rep,name=service,proto3" json:"service,omitempty"`
2024-07-05 22:20:13 -04:00
}
2024-08-10 17:01:14 -04:00
func ( x * Document ) Reset () {
* x = Document {}
2024-07-05 22:20:13 -04:00
if protoimpl . UnsafeEnabled {
2024-09-05 01:24:57 -04:00
mi := & file_did_v1_models_proto_msgTypes [ 3 ]
2024-07-05 22:20:13 -04:00
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
}
}
2024-08-10 17:01:14 -04:00
func ( x * Document ) String () string {
2024-07-05 22:20:13 -04:00
return protoimpl . X . MessageStringOf ( x )
}
2024-08-10 17:01:14 -04:00
func ( * Document ) ProtoMessage () {}
2024-07-05 22:20:13 -04:00
2024-08-10 17:01:14 -04:00
// Deprecated: Use Document.ProtoReflect.Descriptor instead.
func ( * Document ) Descriptor () ([] byte , [] int ) {
2024-09-05 01:24:57 -04:00
return file_did_v1_models_proto_rawDescGZIP (), [] int { 3 }
2024-07-05 22:20:13 -04:00
}
2024-08-10 17:01:14 -04:00
func ( x * Document ) GetId () string {
2024-07-05 22:20:13 -04:00
if x != nil {
return x . Id
}
return ""
}
2024-08-10 17:01:14 -04:00
func ( x * Document ) GetVerificationMethods () [] * VerificationMethod {
2024-07-05 22:20:13 -04:00
if x != nil {
return x . VerificationMethods
}
return nil
}
2024-08-10 17:01:14 -04:00
func ( x * Document ) GetAuthentication () [] string {
2024-07-05 22:20:13 -04:00
if x != nil {
return x . Authentication
}
return nil
}
2024-08-10 17:01:14 -04:00
func ( x * Document ) GetAssertionMethod () [] string {
2024-07-05 22:20:13 -04:00
if x != nil {
return x . AssertionMethod
}
return nil
}
2024-08-10 17:01:14 -04:00
func ( x * Document ) GetCapabilityDelegation () [] string {
2024-07-05 22:20:13 -04:00
if x != nil {
return x . CapabilityDelegation
}
return nil
}
2024-08-10 17:01:14 -04:00
func ( x * Document ) GetCapabilityInvocation () [] string {
2024-07-05 22:20:13 -04:00
if x != nil {
return x . CapabilityInvocation
}
return nil
}
2024-09-05 01:24:57 -04:00
func ( x * Document ) GetService () [] string {
if x != nil {
return x . Service
}
return nil
}
2024-08-31 12:49:44 -04:00
// Metadata defines additional information provided to a did
type Metadata struct {
2024-08-10 17:19:59 -04:00
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
2024-08-31 12:49:44 -04:00
OriginUri string `protobuf:"bytes,1,opt,name=origin_uri,json=originUri,proto3" json:"origin_uri,omitempty"`
Public map [ string ] string `protobuf:"bytes,2,rep,name=public,proto3" json:"public,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
Private map [ string ] * Property `protobuf:"bytes,3,rep,name=private,proto3" json:"private,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * Metadata ) Reset () {
* x = Metadata {}
2024-08-10 17:19:59 -04:00
if protoimpl . UnsafeEnabled {
2024-09-05 01:24:57 -04:00
mi := & file_did_v1_models_proto_msgTypes [ 4 ]
2024-08-10 17:19:59 -04:00
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
}
}
2024-08-31 12:49:44 -04:00
func ( x * Metadata ) String () string {
2024-08-10 17:19:59 -04:00
return protoimpl . X . MessageStringOf ( x )
}
2024-08-31 12:49:44 -04:00
func ( * Metadata ) ProtoMessage () {}
2024-08-10 17:19:59 -04:00
2024-08-31 12:49:44 -04:00
// Deprecated: Use Metadata.ProtoReflect.Descriptor instead.
func ( * Metadata ) Descriptor () ([] byte , [] int ) {
2024-09-05 01:24:57 -04:00
return file_did_v1_models_proto_rawDescGZIP (), [] int { 4 }
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * Metadata ) GetOriginUri () string {
2024-08-10 17:19:59 -04:00
if x != nil {
2024-08-31 12:49:44 -04:00
return x . OriginUri
2024-08-10 17:19:59 -04:00
}
return ""
}
2024-08-31 12:49:44 -04:00
func ( x * Metadata ) GetPublic () map [ string ] string {
if x != nil {
return x . Public
}
return nil
}
func ( x * Metadata ) GetPrivate () map [ string ] * Property {
2024-08-10 17:19:59 -04:00
if x != nil {
2024-08-31 12:49:44 -04:00
return x . Private
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
return nil
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
// Permissions contains a list of grants and access control rules for
// a Service.
type Permissions struct {
2024-08-10 17:19:59 -04:00
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
2024-08-31 12:49:44 -04:00
Grants [] DIDNamespace `protobuf:"varint,1,rep,packed,name=grants,proto3,enum=did.v1.DIDNamespace" json:"grants,omitempty"`
Scopes [] PermissionScope `protobuf:"varint,2,rep,packed,name=scopes,proto3,enum=did.v1.PermissionScope" json:"scopes,omitempty"`
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * Permissions ) Reset () {
* x = Permissions {}
2024-08-10 17:19:59 -04:00
if protoimpl . UnsafeEnabled {
2024-09-05 01:24:57 -04:00
mi := & file_did_v1_models_proto_msgTypes [ 5 ]
2024-08-10 17:19:59 -04:00
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
}
}
2024-08-31 12:49:44 -04:00
func ( x * Permissions ) String () string {
2024-08-10 17:19:59 -04:00
return protoimpl . X . MessageStringOf ( x )
}
2024-08-31 12:49:44 -04:00
func ( * Permissions ) ProtoMessage () {}
2024-08-10 17:19:59 -04:00
2024-08-31 12:49:44 -04:00
// Deprecated: Use Permissions.ProtoReflect.Descriptor instead.
func ( * Permissions ) Descriptor () ([] byte , [] int ) {
2024-09-05 01:24:57 -04:00
return file_did_v1_models_proto_rawDescGZIP (), [] int { 5 }
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * Permissions ) GetGrants () [] DIDNamespace {
2024-08-10 17:19:59 -04:00
if x != nil {
2024-08-31 12:49:44 -04:00
return x . Grants
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
return nil
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * Permissions ) GetScopes () [] PermissionScope {
2024-08-10 17:19:59 -04:00
if x != nil {
2024-08-31 12:49:44 -04:00
return x . Scopes
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
return nil
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
// Profile defines an associated public identity for a did subject
type Profile struct {
2024-08-10 17:19:59 -04:00
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
2024-09-05 01:24:57 -04:00
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
Subject string `protobuf:"bytes,2,opt,name=subject,proto3" json:"subject,omitempty"`
Controller string `protobuf:"bytes,3,opt,name=controller,proto3" json:"controller,omitempty"`
Metadata * Metadata `protobuf:"bytes,4,opt,name=metadata,proto3" json:"metadata,omitempty"`
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * Profile ) Reset () {
* x = Profile {}
2024-08-10 17:19:59 -04:00
if protoimpl . UnsafeEnabled {
2024-09-05 01:24:57 -04:00
mi := & file_did_v1_models_proto_msgTypes [ 6 ]
2024-08-10 17:19:59 -04:00
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
}
}
2024-08-31 12:49:44 -04:00
func ( x * Profile ) String () string {
2024-08-10 17:19:59 -04:00
return protoimpl . X . MessageStringOf ( x )
}
2024-08-31 12:49:44 -04:00
func ( * Profile ) ProtoMessage () {}
2024-08-10 17:19:59 -04:00
2024-08-31 12:49:44 -04:00
// Deprecated: Use Profile.ProtoReflect.Descriptor instead.
func ( * Profile ) Descriptor () ([] byte , [] int ) {
2024-09-05 01:24:57 -04:00
return file_did_v1_models_proto_rawDescGZIP (), [] int { 6 }
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * Profile ) GetId () string {
2024-08-10 17:19:59 -04:00
if x != nil {
2024-08-31 12:49:44 -04:00
return x . Id
2024-08-10 17:19:59 -04:00
}
return ""
}
2024-08-31 12:49:44 -04:00
func ( x * Profile ) GetSubject () string {
2024-08-10 17:19:59 -04:00
if x != nil {
2024-08-31 12:49:44 -04:00
return x . Subject
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
return ""
}
func ( x * Profile ) GetController () string {
if x != nil {
return x . Controller
}
return ""
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * Profile ) GetMetadata () * Metadata {
2024-08-10 17:19:59 -04:00
if x != nil {
2024-08-31 12:49:44 -04:00
return x . Metadata
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
return nil
2024-08-10 17:19:59 -04:00
}
2024-08-31 12:49:44 -04:00
// Property defines a Zero-Knowledge accumulator which can be used to
// anonymously prove a given value to a DID subject
type Property struct {
2024-08-10 17:01:14 -04:00
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
2024-08-31 12:49:44 -04:00
Accumulator [] byte `protobuf:"bytes,1,opt,name=accumulator,proto3" json:"accumulator,omitempty"`
Key [] byte `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"`
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * Property ) Reset () {
* x = Property {}
2024-08-10 17:01:14 -04:00
if protoimpl . UnsafeEnabled {
2024-09-05 01:24:57 -04:00
mi := & file_did_v1_models_proto_msgTypes [ 7 ]
2024-08-10 17:01:14 -04:00
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
}
}
2024-08-31 12:49:44 -04:00
func ( x * Property ) String () string {
2024-08-10 17:01:14 -04:00
return protoimpl . X . MessageStringOf ( x )
}
2024-08-31 12:49:44 -04:00
func ( * Property ) ProtoMessage () {}
2024-08-10 17:01:14 -04:00
2024-08-31 12:49:44 -04:00
// Deprecated: Use Property.ProtoReflect.Descriptor instead.
func ( * Property ) Descriptor () ([] byte , [] int ) {
2024-09-05 01:24:57 -04:00
return file_did_v1_models_proto_rawDescGZIP (), [] int { 7 }
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * Property ) GetAccumulator () [] byte {
2024-08-10 17:01:14 -04:00
if x != nil {
2024-08-31 12:49:44 -04:00
return x . Accumulator
2024-08-10 17:01:14 -04:00
}
return nil
}
2024-08-31 12:49:44 -04:00
func ( x * Property ) GetKey () [] byte {
2024-08-10 17:01:14 -04:00
if x != nil {
2024-08-31 12:49:44 -04:00
return x . Key
2024-08-10 17:01:14 -04:00
}
return nil
}
// PubKey defines a public key for a did
type PubKey struct {
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
2024-09-05 01:24:57 -04:00
Role KeyRole `protobuf:"varint,1,opt,name=role,proto3,enum=did.v1.KeyRole" json:"role,omitempty"`
Algorithm KeyAlgorithm `protobuf:"varint,2,opt,name=algorithm,proto3,enum=did.v1.KeyAlgorithm" json:"algorithm,omitempty"`
Encoding KeyEncoding `protobuf:"varint,3,opt,name=encoding,proto3,enum=did.v1.KeyEncoding" json:"encoding,omitempty"`
Raw [] byte `protobuf:"bytes,4,opt,name=raw,proto3" json:"raw,omitempty"`
Hex string `protobuf:"bytes,5,opt,name=hex,proto3" json:"hex,omitempty"`
Multibase string `protobuf:"bytes,6,opt,name=multibase,proto3" json:"multibase,omitempty"`
Jwk map [ string ] string `protobuf:"bytes,7,rep,name=jwk,proto3" json:"jwk,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
2024-08-10 17:01:14 -04:00
}
func ( x * PubKey ) Reset () {
* x = PubKey {}
if protoimpl . UnsafeEnabled {
2024-09-05 01:24:57 -04:00
mi := & file_did_v1_models_proto_msgTypes [ 8 ]
2024-08-10 17:01:14 -04:00
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
}
}
func ( x * PubKey ) String () string {
return protoimpl . X . MessageStringOf ( x )
}
func ( * PubKey ) ProtoMessage () {}
// Deprecated: Use PubKey.ProtoReflect.Descriptor instead.
func ( * PubKey ) Descriptor () ([] byte , [] int ) {
2024-09-05 01:24:57 -04:00
return file_did_v1_models_proto_rawDescGZIP (), [] int { 8 }
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * PubKey ) GetRole () KeyRole {
2024-08-10 17:01:14 -04:00
if x != nil {
2024-09-05 01:24:57 -04:00
return x . Role
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
return KeyRole_KEY_ROLE_UNSPECIFIED
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
func ( x * PubKey ) GetAlgorithm () KeyAlgorithm {
2024-08-10 17:01:14 -04:00
if x != nil {
2024-09-05 01:24:57 -04:00
return x . Algorithm
}
return KeyAlgorithm_KEY_ALGORITHM_UNSPECIFIED
}
func ( x * PubKey ) GetEncoding () KeyEncoding {
if x != nil {
return x . Encoding
}
return KeyEncoding_KEY_ENCODING_UNSPECIFIED
}
func ( x * PubKey ) GetRaw () [] byte {
if x != nil {
return x . Raw
2024-08-10 17:01:14 -04:00
}
return nil
}
2024-09-05 01:24:57 -04:00
func ( x * PubKey ) GetHex () string {
2024-08-10 17:01:14 -04:00
if x != nil {
2024-09-05 01:24:57 -04:00
return x . Hex
2024-08-10 17:01:14 -04:00
}
2024-09-05 01:24:57 -04:00
return ""
2024-08-10 17:01:14 -04:00
}
2024-08-31 12:49:44 -04:00
func ( x * PubKey ) GetMultibase () string {
2024-08-10 17:01:14 -04:00
if x != nil {
2024-08-31 12:49:44 -04:00
return x . Multibase
2024-08-10 17:01:14 -04:00
}
return ""
}
2024-09-05 01:24:57 -04:00
func ( x * PubKey ) GetJwk () map [ string ] string {
if x != nil {
return x . Jwk
}
return nil
}
// Service defines a Decentralized Service on the Sonr Blockchain
type Service struct {
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
Controller string `protobuf:"bytes,2,opt,name=controller,proto3" json:"controller,omitempty"`
Origin string `protobuf:"bytes,3,opt,name=origin,proto3" json:"origin,omitempty"`
Permissions * Permissions `protobuf:"bytes,4,opt,name=permissions,proto3" json:"permissions,omitempty"`
Openid * OpenIDConfig `protobuf:"bytes,5,opt,name=openid,proto3" json:"openid,omitempty"`
Metadata * Metadata `protobuf:"bytes,6,opt,name=metadata,proto3" json:"metadata,omitempty"`
}
func ( x * Service ) Reset () {
* x = Service {}
if protoimpl . UnsafeEnabled {
mi := & file_did_v1_models_proto_msgTypes [ 9 ]
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
}
}
func ( x * Service ) String () string {
return protoimpl . X . MessageStringOf ( x )
}
func ( * Service ) ProtoMessage () {}
// Deprecated: Use Service.ProtoReflect.Descriptor instead.
func ( * Service ) Descriptor () ([] byte , [] int ) {
return file_did_v1_models_proto_rawDescGZIP (), [] int { 9 }
}
func ( x * Service ) GetId () string {
if x != nil {
return x . Id
}
return ""
}
func ( x * Service ) GetController () string {
if x != nil {
return x . Controller
}
return ""
}
func ( x * Service ) GetOrigin () string {
if x != nil {
return x . Origin
}
return ""
}
func ( x * Service ) GetPermissions () * Permissions {
if x != nil {
return x . Permissions
}
return nil
}
func ( x * Service ) GetOpenid () * OpenIDConfig {
if x != nil {
return x . Openid
}
return nil
}
func ( x * Service ) GetMetadata () * Metadata {
if x != nil {
return x . Metadata
}
return nil
}
// Token defines a macron token
type Token struct {
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
Controller string `protobuf:"bytes,2,opt,name=controller,proto3" json:"controller,omitempty"`
Macron [] byte `protobuf:"bytes,3,opt,name=macron,proto3" json:"macron,omitempty"`
}
func ( x * Token ) Reset () {
* x = Token {}
if protoimpl . UnsafeEnabled {
mi := & file_did_v1_models_proto_msgTypes [ 10 ]
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
}
}
func ( x * Token ) String () string {
return protoimpl . X . MessageStringOf ( x )
}
func ( * Token ) ProtoMessage () {}
// Deprecated: Use Token.ProtoReflect.Descriptor instead.
func ( * Token ) Descriptor () ([] byte , [] int ) {
return file_did_v1_models_proto_rawDescGZIP (), [] int { 10 }
}
func ( x * Token ) GetId () string {
if x != nil {
return x . Id
}
return ""
}
func ( x * Token ) GetController () string {
if x != nil {
return x . Controller
}
return ""
}
func ( x * Token ) GetMacron () [] byte {
2024-08-31 12:49:44 -04:00
if x != nil {
2024-09-05 01:24:57 -04:00
return x . Macron
2024-08-31 12:49:44 -04:00
}
return nil
}
2024-07-05 22:20:13 -04:00
// VerificationMethod defines a verification method
type VerificationMethod struct {
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
2024-09-05 01:24:57 -04:00
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
Controller string `protobuf:"bytes,2,opt,name=controller,proto3" json:"controller,omitempty"`
Method DIDNamespace `protobuf:"varint,3,opt,name=method,proto3,enum=did.v1.DIDNamespace" json:"method,omitempty"`
PublicKey * PubKey `protobuf:"bytes,4,opt,name=public_key,json=publicKey,proto3" json:"public_key,omitempty"`
Service * Service `protobuf:"bytes,7,opt,name=service,proto3" json:"service,omitempty"`
2024-07-05 22:20:13 -04:00
}
func ( x * VerificationMethod ) Reset () {
* x = VerificationMethod {}
if protoimpl . UnsafeEnabled {
2024-09-05 01:24:57 -04:00
mi := & file_did_v1_models_proto_msgTypes [ 11 ]
2024-07-05 22:20:13 -04:00
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
}
}
func ( x * VerificationMethod ) String () string {
return protoimpl . X . MessageStringOf ( x )
}
func ( * VerificationMethod ) ProtoMessage () {}
// Deprecated: Use VerificationMethod.ProtoReflect.Descriptor instead.
func ( * VerificationMethod ) Descriptor () ([] byte , [] int ) {
2024-09-05 01:24:57 -04:00
return file_did_v1_models_proto_rawDescGZIP (), [] int { 11 }
2024-07-05 22:20:13 -04:00
}
func ( x * VerificationMethod ) GetId () string {
if x != nil {
return x . Id
}
return ""
}
func ( x * VerificationMethod ) GetController () string {
if x != nil {
return x . Controller
}
return ""
}
2024-09-05 01:24:57 -04:00
func ( x * VerificationMethod ) GetMethod () DIDNamespace {
if x != nil {
return x . Method
}
return DIDNamespace_DID_NAMESPACE_UNSPECIFIED
}
2024-08-31 12:49:44 -04:00
func ( x * VerificationMethod ) GetPublicKey () * PubKey {
2024-07-05 22:20:13 -04:00
if x != nil {
2024-08-31 12:49:44 -04:00
return x . PublicKey
2024-07-05 22:20:13 -04:00
}
return nil
}
2024-09-05 01:24:57 -04:00
func ( x * VerificationMethod ) GetService () * Service {
if x != nil {
return x . Service
}
return nil
}
// Witness defines a BLS witness
type Witness struct {
state protoimpl . MessageState
sizeCache protoimpl . SizeCache
unknownFields protoimpl . UnknownFields
Witness [] byte `protobuf:"bytes,1,opt,name=witness,proto3" json:"witness,omitempty"`
}
func ( x * Witness ) Reset () {
* x = Witness {}
if protoimpl . UnsafeEnabled {
mi := & file_did_v1_models_proto_msgTypes [ 12 ]
ms := protoimpl . X . MessageStateOf ( protoimpl . Pointer ( x ))
ms . StoreMessageInfo ( mi )
}
}
func ( x * Witness ) String () string {
return protoimpl . X . MessageStringOf ( x )
}
func ( * Witness ) ProtoMessage () {}
// Deprecated: Use Witness.ProtoReflect.Descriptor instead.
func ( * Witness ) Descriptor () ([] byte , [] int ) {
return file_did_v1_models_proto_rawDescGZIP (), [] int { 12 }
}
func ( x * Witness ) GetWitness () [] byte {
if x != nil {
return x . Witness
}
return nil
}
2024-08-31 12:49:44 -04:00
var File_did_v1_models_proto protoreflect . FileDescriptor
var file_did_v1_models_proto_rawDesc = [] byte {
0x0a , 0x13 , 0x64 , 0x69 , 0x64 , 0x2f , 0x76 , 0x31 , 0x2f , 0x6d , 0x6f , 0x64 , 0x65 , 0x6c , 0x73 , 0x2e ,
2024-09-05 01:24:57 -04:00
0x70 , 0x72 , 0x6f , 0x74 , 0x6f , 0x12 , 0x06 , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x1a , 0x16 , 0x64 ,
0x69 , 0x64 , 0x2f , 0x76 , 0x31 , 0x2f , 0x63 , 0x6f , 0x6e , 0x73 , 0x74 , 0x61 , 0x6e , 0x74 , 0x73 , 0x2e ,
0x70 , 0x72 , 0x6f , 0x74 , 0x6f , 0x1a , 0x14 , 0x64 , 0x69 , 0x64 , 0x2f , 0x76 , 0x31 , 0x2f , 0x67 , 0x65 ,
0x6e , 0x65 , 0x73 , 0x69 , 0x73 , 0x2e , 0x70 , 0x72 , 0x6f , 0x74 , 0x6f , 0x1a , 0x14 , 0x67 , 0x6f , 0x67 ,
0x6f , 0x70 , 0x72 , 0x6f , 0x74 , 0x6f , 0x2f , 0x67 , 0x6f , 0x67 , 0x6f , 0x2e , 0x70 , 0x72 , 0x6f , 0x74 ,
0x6f , 0x22 , 0x2f , 0x0a , 0x0b , 0x41 , 0x63 , 0x63 , 0x75 , 0x6d , 0x75 , 0x6c , 0x61 , 0x74 , 0x6f , 0x72 ,
0x12 , 0x20 , 0x0a , 0x0b , 0x61 , 0x63 , 0x63 , 0x75 , 0x6d , 0x75 , 0x6c , 0x61 , 0x74 , 0x6f , 0x72 , 0x18 ,
0x01 , 0x20 , 0x01 , 0x28 , 0x0c , 0x52 , 0x0b , 0x61 , 0x63 , 0x63 , 0x75 , 0x6d , 0x75 , 0x6c , 0x61 , 0x74 ,
0x6f , 0x72 , 0x22 , 0xc2 , 0x01 , 0x0a , 0x0a , 0x43 , 0x72 , 0x65 , 0x64 , 0x65 , 0x6e , 0x74 , 0x69 , 0x61 ,
0x6c , 0x12 , 0x0e , 0x0a , 0x02 , 0x69 , 0x64 , 0x18 , 0x01 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x02 , 0x69 ,
0x64 , 0x12 , 0x27 , 0x0a , 0x0f , 0x63 , 0x72 , 0x65 , 0x64 , 0x65 , 0x6e , 0x74 , 0x69 , 0x61 , 0x6c , 0x5f ,
0x74 , 0x79 , 0x70 , 0x65 , 0x18 , 0x02 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x0e , 0x63 , 0x72 , 0x65 , 0x64 ,
0x65 , 0x6e , 0x74 , 0x69 , 0x61 , 0x6c , 0x54 , 0x79 , 0x70 , 0x65 , 0x12 , 0x23 , 0x0a , 0x0d , 0x63 , 0x72 ,
0x65 , 0x64 , 0x65 , 0x6e , 0x74 , 0x69 , 0x61 , 0x6c , 0x5f , 0x69 , 0x64 , 0x18 , 0x03 , 0x20 , 0x01 , 0x28 ,
0x0c , 0x52 , 0x0c , 0x63 , 0x72 , 0x65 , 0x64 , 0x65 , 0x6e , 0x74 , 0x69 , 0x61 , 0x6c , 0x49 , 0x64 , 0x12 ,
0x1c , 0x0a , 0x09 , 0x74 , 0x72 , 0x61 , 0x6e , 0x73 , 0x70 , 0x6f , 0x72 , 0x74 , 0x18 , 0x04 , 0x20 , 0x03 ,
0x28 , 0x09 , 0x52 , 0x09 , 0x74 , 0x72 , 0x61 , 0x6e , 0x73 , 0x70 , 0x6f , 0x72 , 0x74 , 0x12 , 0x18 , 0x0a ,
0x07 , 0x73 , 0x75 , 0x62 , 0x6a , 0x65 , 0x63 , 0x74 , 0x18 , 0x06 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x07 ,
0x73 , 0x75 , 0x62 , 0x6a , 0x65 , 0x63 , 0x74 , 0x12 , 0x1e , 0x0a , 0x0a , 0x63 , 0x6f , 0x6e , 0x74 , 0x72 ,
0x6f , 0x6c , 0x6c , 0x65 , 0x72 , 0x18 , 0x07 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x0a , 0x63 , 0x6f , 0x6e ,
0x74 , 0x72 , 0x6f , 0x6c , 0x6c , 0x65 , 0x72 , 0x22 , 0x9d , 0x01 , 0x0a , 0x03 , 0x44 , 0x49 , 0x44 , 0x12 ,
0x2c , 0x0a , 0x06 , 0x6d , 0x65 , 0x74 , 0x68 , 0x6f , 0x64 , 0x18 , 0x01 , 0x20 , 0x01 , 0x28 , 0x0e , 0x32 ,
0x14 , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x44 , 0x49 , 0x44 , 0x4e , 0x61 , 0x6d , 0x65 ,
0x73 , 0x70 , 0x61 , 0x63 , 0x65 , 0x52 , 0x06 , 0x6d , 0x65 , 0x74 , 0x68 , 0x6f , 0x64 , 0x12 , 0x18 , 0x0a ,
0x07 , 0x6e , 0x65 , 0x74 , 0x77 , 0x6f , 0x72 , 0x6b , 0x18 , 0x02 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x07 ,
0x6e , 0x65 , 0x74 , 0x77 , 0x6f , 0x72 , 0x6b , 0x12 , 0x18 , 0x0a , 0x07 , 0x73 , 0x75 , 0x62 , 0x6a , 0x65 ,
0x63 , 0x74 , 0x18 , 0x03 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x07 , 0x73 , 0x75 , 0x62 , 0x6a , 0x65 , 0x63 ,
0x74 , 0x12 , 0x1e , 0x0a , 0x0a , 0x69 , 0x64 , 0x65 , 0x6e , 0x74 , 0x69 , 0x66 , 0x69 , 0x65 , 0x72 , 0x18 ,
0x04 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x0a , 0x69 , 0x64 , 0x65 , 0x6e , 0x74 , 0x69 , 0x66 , 0x69 , 0x65 ,
0x72 , 0x12 , 0x14 , 0x0a , 0x05 , 0x70 , 0x61 , 0x74 , 0x68 , 0x73 , 0x18 , 0x05 , 0x20 , 0x03 , 0x28 , 0x09 ,
0x52 , 0x05 , 0x70 , 0x61 , 0x74 , 0x68 , 0x73 , 0x22 , 0xc0 , 0x02 , 0x0a , 0x08 , 0x44 , 0x6f , 0x63 , 0x75 ,
0x6d , 0x65 , 0x6e , 0x74 , 0x12 , 0x0e , 0x0a , 0x02 , 0x69 , 0x64 , 0x18 , 0x01 , 0x20 , 0x01 , 0x28 , 0x09 ,
0x52 , 0x02 , 0x69 , 0x64 , 0x12 , 0x4d , 0x0a , 0x14 , 0x76 , 0x65 , 0x72 , 0x69 , 0x66 , 0x69 , 0x63 , 0x61 ,
0x74 , 0x69 , 0x6f , 0x6e , 0x5f , 0x6d , 0x65 , 0x74 , 0x68 , 0x6f , 0x64 , 0x73 , 0x18 , 0x02 , 0x20 , 0x03 ,
0x28 , 0x0b , 0x32 , 0x1a , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x56 , 0x65 , 0x72 , 0x69 ,
0x66 , 0x69 , 0x63 , 0x61 , 0x74 , 0x69 , 0x6f , 0x6e , 0x4d , 0x65 , 0x74 , 0x68 , 0x6f , 0x64 , 0x52 , 0x13 ,
0x76 , 0x65 , 0x72 , 0x69 , 0x66 , 0x69 , 0x63 , 0x61 , 0x74 , 0x69 , 0x6f , 0x6e , 0x4d , 0x65 , 0x74 , 0x68 ,
0x6f , 0x64 , 0x73 , 0x12 , 0x26 , 0x0a , 0x0e , 0x61 , 0x75 , 0x74 , 0x68 , 0x65 , 0x6e , 0x74 , 0x69 , 0x63 ,
0x61 , 0x74 , 0x69 , 0x6f , 0x6e , 0x18 , 0x04 , 0x20 , 0x03 , 0x28 , 0x09 , 0x52 , 0x0e , 0x61 , 0x75 , 0x74 ,
0x68 , 0x65 , 0x6e , 0x74 , 0x69 , 0x63 , 0x61 , 0x74 , 0x69 , 0x6f , 0x6e , 0x12 , 0x29 , 0x0a , 0x10 , 0x61 ,
0x73 , 0x73 , 0x65 , 0x72 , 0x74 , 0x69 , 0x6f , 0x6e , 0x5f , 0x6d , 0x65 , 0x74 , 0x68 , 0x6f , 0x64 , 0x18 ,
0x05 , 0x20 , 0x03 , 0x28 , 0x09 , 0x52 , 0x0f , 0x61 , 0x73 , 0x73 , 0x65 , 0x72 , 0x74 , 0x69 , 0x6f , 0x6e ,
0x4d , 0x65 , 0x74 , 0x68 , 0x6f , 0x64 , 0x12 , 0x33 , 0x0a , 0x15 , 0x63 , 0x61 , 0x70 , 0x61 , 0x62 , 0x69 ,
0x6c , 0x69 , 0x74 , 0x79 , 0x5f , 0x64 , 0x65 , 0x6c , 0x65 , 0x67 , 0x61 , 0x74 , 0x69 , 0x6f , 0x6e , 0x18 ,
0x07 , 0x20 , 0x03 , 0x28 , 0x09 , 0x52 , 0x14 , 0x63 , 0x61 , 0x70 , 0x61 , 0x62 , 0x69 , 0x6c , 0x69 , 0x74 ,
0x79 , 0x44 , 0x65 , 0x6c , 0x65 , 0x67 , 0x61 , 0x74 , 0x69 , 0x6f , 0x6e , 0x12 , 0x33 , 0x0a , 0x15 , 0x63 ,
0x61 , 0x70 , 0x61 , 0x62 , 0x69 , 0x6c , 0x69 , 0x74 , 0x79 , 0x5f , 0x69 , 0x6e , 0x76 , 0x6f , 0x63 , 0x61 ,
0x74 , 0x69 , 0x6f , 0x6e , 0x18 , 0x08 , 0x20 , 0x03 , 0x28 , 0x09 , 0x52 , 0x14 , 0x63 , 0x61 , 0x70 , 0x61 ,
0x62 , 0x69 , 0x6c , 0x69 , 0x74 , 0x79 , 0x49 , 0x6e , 0x76 , 0x6f , 0x63 , 0x61 , 0x74 , 0x69 , 0x6f , 0x6e ,
0x12 , 0x18 , 0x0a , 0x07 , 0x73 , 0x65 , 0x72 , 0x76 , 0x69 , 0x63 , 0x65 , 0x18 , 0x09 , 0x20 , 0x03 , 0x28 ,
0x09 , 0x52 , 0x07 , 0x73 , 0x65 , 0x72 , 0x76 , 0x69 , 0x63 , 0x65 , 0x22 , 0xa1 , 0x02 , 0x0a , 0x08 , 0x4d ,
0x65 , 0x74 , 0x61 , 0x64 , 0x61 , 0x74 , 0x61 , 0x12 , 0x1d , 0x0a , 0x0a , 0x6f , 0x72 , 0x69 , 0x67 , 0x69 ,
0x6e , 0x5f , 0x75 , 0x72 , 0x69 , 0x18 , 0x01 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x09 , 0x6f , 0x72 , 0x69 ,
0x67 , 0x69 , 0x6e , 0x55 , 0x72 , 0x69 , 0x12 , 0x34 , 0x0a , 0x06 , 0x70 , 0x75 , 0x62 , 0x6c , 0x69 , 0x63 ,
0x18 , 0x02 , 0x20 , 0x03 , 0x28 , 0x0b , 0x32 , 0x1c , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e ,
0x4d , 0x65 , 0x74 , 0x61 , 0x64 , 0x61 , 0x74 , 0x61 , 0x2e , 0x50 , 0x75 , 0x62 , 0x6c , 0x69 , 0x63 , 0x45 ,
0x6e , 0x74 , 0x72 , 0x79 , 0x52 , 0x06 , 0x70 , 0x75 , 0x62 , 0x6c , 0x69 , 0x63 , 0x12 , 0x37 , 0x0a , 0x07 ,
0x70 , 0x72 , 0x69 , 0x76 , 0x61 , 0x74 , 0x65 , 0x18 , 0x03 , 0x20 , 0x03 , 0x28 , 0x0b , 0x32 , 0x1d , 0x2e ,
0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x4d , 0x65 , 0x74 , 0x61 , 0x64 , 0x61 , 0x74 , 0x61 , 0x2e ,
0x50 , 0x72 , 0x69 , 0x76 , 0x61 , 0x74 , 0x65 , 0x45 , 0x6e , 0x74 , 0x72 , 0x79 , 0x52 , 0x07 , 0x70 , 0x72 ,
0x69 , 0x76 , 0x61 , 0x74 , 0x65 , 0x1a , 0x39 , 0x0a , 0x0b , 0x50 , 0x75 , 0x62 , 0x6c , 0x69 , 0x63 , 0x45 ,
0x6e , 0x74 , 0x72 , 0x79 , 0x12 , 0x10 , 0x0a , 0x03 , 0x6b , 0x65 , 0x79 , 0x18 , 0x01 , 0x20 , 0x01 , 0x28 ,
0x09 , 0x52 , 0x03 , 0x6b , 0x65 , 0x79 , 0x12 , 0x14 , 0x0a , 0x05 , 0x76 , 0x61 , 0x6c , 0x75 , 0x65 , 0x18 ,
0x02 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x05 , 0x76 , 0x61 , 0x6c , 0x75 , 0x65 , 0x3a , 0x02 , 0x38 , 0x01 ,
0x1a , 0x4c , 0x0a , 0x0c , 0x50 , 0x72 , 0x69 , 0x76 , 0x61 , 0x74 , 0x65 , 0x45 , 0x6e , 0x74 , 0x72 , 0x79 ,
0x12 , 0x10 , 0x0a , 0x03 , 0x6b , 0x65 , 0x79 , 0x18 , 0x01 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x03 , 0x6b ,
0x65 , 0x79 , 0x12 , 0x26 , 0x0a , 0x05 , 0x76 , 0x61 , 0x6c , 0x75 , 0x65 , 0x18 , 0x02 , 0x20 , 0x01 , 0x28 ,
0x0b , 0x32 , 0x10 , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x50 , 0x72 , 0x6f , 0x70 , 0x65 ,
0x72 , 0x74 , 0x79 , 0x52 , 0x05 , 0x76 , 0x61 , 0x6c , 0x75 , 0x65 , 0x3a , 0x02 , 0x38 , 0x01 , 0x22 , 0x6c ,
0x0a , 0x0b , 0x50 , 0x65 , 0x72 , 0x6d , 0x69 , 0x73 , 0x73 , 0x69 , 0x6f , 0x6e , 0x73 , 0x12 , 0x2c , 0x0a ,
0x06 , 0x67 , 0x72 , 0x61 , 0x6e , 0x74 , 0x73 , 0x18 , 0x01 , 0x20 , 0x03 , 0x28 , 0x0e , 0x32 , 0x14 , 0x2e ,
0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x44 , 0x49 , 0x44 , 0x4e , 0x61 , 0x6d , 0x65 , 0x73 , 0x70 ,
0x61 , 0x63 , 0x65 , 0x52 , 0x06 , 0x67 , 0x72 , 0x61 , 0x6e , 0x74 , 0x73 , 0x12 , 0x2f , 0x0a , 0x06 , 0x73 ,
0x63 , 0x6f , 0x70 , 0x65 , 0x73 , 0x18 , 0x02 , 0x20 , 0x03 , 0x28 , 0x0e , 0x32 , 0x17 , 0x2e , 0x64 , 0x69 ,
0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x50 , 0x65 , 0x72 , 0x6d , 0x69 , 0x73 , 0x73 , 0x69 , 0x6f , 0x6e , 0x53 ,
0x63 , 0x6f , 0x70 , 0x65 , 0x52 , 0x06 , 0x73 , 0x63 , 0x6f , 0x70 , 0x65 , 0x73 , 0x22 , 0x81 , 0x01 , 0x0a ,
0x07 , 0x50 , 0x72 , 0x6f , 0x66 , 0x69 , 0x6c , 0x65 , 0x12 , 0x0e , 0x0a , 0x02 , 0x69 , 0x64 , 0x18 , 0x01 ,
0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x02 , 0x69 , 0x64 , 0x12 , 0x18 , 0x0a , 0x07 , 0x73 , 0x75 , 0x62 , 0x6a ,
0x65 , 0x63 , 0x74 , 0x18 , 0x02 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x07 , 0x73 , 0x75 , 0x62 , 0x6a , 0x65 ,
0x63 , 0x74 , 0x12 , 0x1e , 0x0a , 0x0a , 0x63 , 0x6f , 0x6e , 0x74 , 0x72 , 0x6f , 0x6c , 0x6c , 0x65 , 0x72 ,
0x18 , 0x03 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x0a , 0x63 , 0x6f , 0x6e , 0x74 , 0x72 , 0x6f , 0x6c , 0x6c ,
0x65 , 0x72 , 0x12 , 0x2c , 0x0a , 0x08 , 0x6d , 0x65 , 0x74 , 0x61 , 0x64 , 0x61 , 0x74 , 0x61 , 0x18 , 0x04 ,
0x20 , 0x01 , 0x28 , 0x0b , 0x32 , 0x10 , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x4d , 0x65 ,
0x74 , 0x61 , 0x64 , 0x61 , 0x74 , 0x61 , 0x52 , 0x08 , 0x6d , 0x65 , 0x74 , 0x61 , 0x64 , 0x61 , 0x74 , 0x61 ,
0x22 , 0x3e , 0x0a , 0x08 , 0x50 , 0x72 , 0x6f , 0x70 , 0x65 , 0x72 , 0x74 , 0x79 , 0x12 , 0x20 , 0x0a , 0x0b ,
0x61 , 0x63 , 0x63 , 0x75 , 0x6d , 0x75 , 0x6c , 0x61 , 0x74 , 0x6f , 0x72 , 0x18 , 0x01 , 0x20 , 0x01 , 0x28 ,
0x0c , 0x52 , 0x0b , 0x61 , 0x63 , 0x63 , 0x75 , 0x6d , 0x75 , 0x6c , 0x61 , 0x74 , 0x6f , 0x72 , 0x12 , 0x10 ,
0x0a , 0x03 , 0x6b , 0x65 , 0x79 , 0x18 , 0x02 , 0x20 , 0x01 , 0x28 , 0x0c , 0x52 , 0x03 , 0x6b , 0x65 , 0x79 ,
0x22 , 0xb7 , 0x02 , 0x0a , 0x06 , 0x50 , 0x75 , 0x62 , 0x4b , 0x65 , 0x79 , 0x12 , 0x23 , 0x0a , 0x04 , 0x72 ,
0x6f , 0x6c , 0x65 , 0x18 , 0x01 , 0x20 , 0x01 , 0x28 , 0x0e , 0x32 , 0x0f , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e ,
0x76 , 0x31 , 0x2e , 0x4b , 0x65 , 0x79 , 0x52 , 0x6f , 0x6c , 0x65 , 0x52 , 0x04 , 0x72 , 0x6f , 0x6c , 0x65 ,
0x12 , 0x32 , 0x0a , 0x09 , 0x61 , 0x6c , 0x67 , 0x6f , 0x72 , 0x69 , 0x74 , 0x68 , 0x6d , 0x18 , 0x02 , 0x20 ,
0x01 , 0x28 , 0x0e , 0x32 , 0x14 , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x4b , 0x65 , 0x79 ,
0x41 , 0x6c , 0x67 , 0x6f , 0x72 , 0x69 , 0x74 , 0x68 , 0x6d , 0x52 , 0x09 , 0x61 , 0x6c , 0x67 , 0x6f , 0x72 ,
0x69 , 0x74 , 0x68 , 0x6d , 0x12 , 0x2f , 0x0a , 0x08 , 0x65 , 0x6e , 0x63 , 0x6f , 0x64 , 0x69 , 0x6e , 0x67 ,
0x18 , 0x03 , 0x20 , 0x01 , 0x28 , 0x0e , 0x32 , 0x13 , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e ,
0x4b , 0x65 , 0x79 , 0x45 , 0x6e , 0x63 , 0x6f , 0x64 , 0x69 , 0x6e , 0x67 , 0x52 , 0x08 , 0x65 , 0x6e , 0x63 ,
0x6f , 0x64 , 0x69 , 0x6e , 0x67 , 0x12 , 0x10 , 0x0a , 0x03 , 0x72 , 0x61 , 0x77 , 0x18 , 0x04 , 0x20 , 0x01 ,
0x28 , 0x0c , 0x52 , 0x03 , 0x72 , 0x61 , 0x77 , 0x12 , 0x10 , 0x0a , 0x03 , 0x68 , 0x65 , 0x78 , 0x18 , 0x05 ,
0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x03 , 0x68 , 0x65 , 0x78 , 0x12 , 0x1c , 0x0a , 0x09 , 0x6d , 0x75 , 0x6c ,
0x74 , 0x69 , 0x62 , 0x61 , 0x73 , 0x65 , 0x18 , 0x06 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x09 , 0x6d , 0x75 ,
0x6c , 0x74 , 0x69 , 0x62 , 0x61 , 0x73 , 0x65 , 0x12 , 0x29 , 0x0a , 0x03 , 0x6a , 0x77 , 0x6b , 0x18 , 0x07 ,
0x20 , 0x03 , 0x28 , 0x0b , 0x32 , 0x17 , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x50 , 0x75 ,
0x62 , 0x4b , 0x65 , 0x79 , 0x2e , 0x4a , 0x77 , 0x6b , 0x45 , 0x6e , 0x74 , 0x72 , 0x79 , 0x52 , 0x03 , 0x6a ,
0x77 , 0x6b , 0x1a , 0x36 , 0x0a , 0x08 , 0x4a , 0x77 , 0x6b , 0x45 , 0x6e , 0x74 , 0x72 , 0x79 , 0x12 , 0x10 ,
0x0a , 0x03 , 0x6b , 0x65 , 0x79 , 0x18 , 0x01 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x03 , 0x6b , 0x65 , 0x79 ,
0x12 , 0x14 , 0x0a , 0x05 , 0x76 , 0x61 , 0x6c , 0x75 , 0x65 , 0x18 , 0x02 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 ,
0x05 , 0x76 , 0x61 , 0x6c , 0x75 , 0x65 , 0x3a , 0x02 , 0x38 , 0x01 , 0x22 , 0xe4 , 0x01 , 0x0a , 0x07 , 0x53 ,
0x65 , 0x72 , 0x76 , 0x69 , 0x63 , 0x65 , 0x12 , 0x0e , 0x0a , 0x02 , 0x69 , 0x64 , 0x18 , 0x01 , 0x20 , 0x01 ,
0x28 , 0x09 , 0x52 , 0x02 , 0x69 , 0x64 , 0x12 , 0x1e , 0x0a , 0x0a , 0x63 , 0x6f , 0x6e , 0x74 , 0x72 , 0x6f ,
0x6c , 0x6c , 0x65 , 0x72 , 0x18 , 0x02 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x0a , 0x63 , 0x6f , 0x6e , 0x74 ,
0x72 , 0x6f , 0x6c , 0x6c , 0x65 , 0x72 , 0x12 , 0x16 , 0x0a , 0x06 , 0x6f , 0x72 , 0x69 , 0x67 , 0x69 , 0x6e ,
0x18 , 0x03 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x06 , 0x6f , 0x72 , 0x69 , 0x67 , 0x69 , 0x6e , 0x12 , 0x35 ,
0x0a , 0x0b , 0x70 , 0x65 , 0x72 , 0x6d , 0x69 , 0x73 , 0x73 , 0x69 , 0x6f , 0x6e , 0x73 , 0x18 , 0x04 , 0x20 ,
0x01 , 0x28 , 0x0b , 0x32 , 0x13 , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x50 , 0x65 , 0x72 ,
0x6d , 0x69 , 0x73 , 0x73 , 0x69 , 0x6f , 0x6e , 0x73 , 0x52 , 0x0b , 0x70 , 0x65 , 0x72 , 0x6d , 0x69 , 0x73 ,
0x73 , 0x69 , 0x6f , 0x6e , 0x73 , 0x12 , 0x2c , 0x0a , 0x06 , 0x6f , 0x70 , 0x65 , 0x6e , 0x69 , 0x64 , 0x18 ,
0x05 , 0x20 , 0x01 , 0x28 , 0x0b , 0x32 , 0x14 , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x4f ,
0x70 , 0x65 , 0x6e , 0x49 , 0x44 , 0x43 , 0x6f , 0x6e , 0x66 , 0x69 , 0x67 , 0x52 , 0x06 , 0x6f , 0x70 , 0x65 ,
0x6e , 0x69 , 0x64 , 0x12 , 0x2c , 0x0a , 0x08 , 0x6d , 0x65 , 0x74 , 0x61 , 0x64 , 0x61 , 0x74 , 0x61 , 0x18 ,
0x06 , 0x20 , 0x01 , 0x28 , 0x0b , 0x32 , 0x10 , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x4d ,
0x65 , 0x74 , 0x61 , 0x64 , 0x61 , 0x74 , 0x61 , 0x52 , 0x08 , 0x6d , 0x65 , 0x74 , 0x61 , 0x64 , 0x61 , 0x74 ,
0x61 , 0x22 , 0x4f , 0x0a , 0x05 , 0x54 , 0x6f , 0x6b , 0x65 , 0x6e , 0x12 , 0x0e , 0x0a , 0x02 , 0x69 , 0x64 ,
0x18 , 0x01 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x02 , 0x69 , 0x64 , 0x12 , 0x1e , 0x0a , 0x0a , 0x63 , 0x6f ,
0x6e , 0x74 , 0x72 , 0x6f , 0x6c , 0x6c , 0x65 , 0x72 , 0x18 , 0x02 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x0a ,
0x63 , 0x6f , 0x6e , 0x74 , 0x72 , 0x6f , 0x6c , 0x6c , 0x65 , 0x72 , 0x12 , 0x16 , 0x0a , 0x06 , 0x6d , 0x61 ,
0x63 , 0x72 , 0x6f , 0x6e , 0x18 , 0x03 , 0x20 , 0x01 , 0x28 , 0x0c , 0x52 , 0x06 , 0x6d , 0x61 , 0x63 , 0x72 ,
0x6f , 0x6e , 0x22 , 0xcc , 0x01 , 0x0a , 0x12 , 0x56 , 0x65 , 0x72 , 0x69 , 0x66 , 0x69 , 0x63 , 0x61 , 0x74 ,
0x69 , 0x6f , 0x6e , 0x4d , 0x65 , 0x74 , 0x68 , 0x6f , 0x64 , 0x12 , 0x0e , 0x0a , 0x02 , 0x69 , 0x64 , 0x18 ,
0x01 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x02 , 0x69 , 0x64 , 0x12 , 0x1e , 0x0a , 0x0a , 0x63 , 0x6f , 0x6e ,
0x74 , 0x72 , 0x6f , 0x6c , 0x6c , 0x65 , 0x72 , 0x18 , 0x02 , 0x20 , 0x01 , 0x28 , 0x09 , 0x52 , 0x0a , 0x63 ,
0x6f , 0x6e , 0x74 , 0x72 , 0x6f , 0x6c , 0x6c , 0x65 , 0x72 , 0x12 , 0x2c , 0x0a , 0x06 , 0x6d , 0x65 , 0x74 ,
0x68 , 0x6f , 0x64 , 0x18 , 0x03 , 0x20 , 0x01 , 0x28 , 0x0e , 0x32 , 0x14 , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e ,
0x76 , 0x31 , 0x2e , 0x44 , 0x49 , 0x44 , 0x4e , 0x61 , 0x6d , 0x65 , 0x73 , 0x70 , 0x61 , 0x63 , 0x65 , 0x52 ,
0x06 , 0x6d , 0x65 , 0x74 , 0x68 , 0x6f , 0x64 , 0x12 , 0x2d , 0x0a , 0x0a , 0x70 , 0x75 , 0x62 , 0x6c , 0x69 ,
0x63 , 0x5f , 0x6b , 0x65 , 0x79 , 0x18 , 0x04 , 0x20 , 0x01 , 0x28 , 0x0b , 0x32 , 0x0e , 0x2e , 0x64 , 0x69 ,
0x64 , 0x2e , 0x76 , 0x31 , 0x2e , 0x50 , 0x75 , 0x62 , 0x4b , 0x65 , 0x79 , 0x52 , 0x09 , 0x70 , 0x75 , 0x62 ,
0x6c , 0x69 , 0x63 , 0x4b , 0x65 , 0x79 , 0x12 , 0x29 , 0x0a , 0x07 , 0x73 , 0x65 , 0x72 , 0x76 , 0x69 , 0x63 ,
0x65 , 0x18 , 0x07 , 0x20 , 0x01 , 0x28 , 0x0b , 0x32 , 0x0f , 0x2e , 0x64 , 0x69 , 0x64 , 0x2e , 0x76 , 0x31 ,
0x2e , 0x53 , 0x65 , 0x72 , 0x76 , 0x69 , 0x63 , 0x65 , 0x52 , 0x07 , 0x73 , 0x65 , 0x72 , 0x76 , 0x69 , 0x63 ,
0x65 , 0x22 , 0x23 , 0x0a , 0x07 , 0x57 , 0x69 , 0x74 , 0x6e , 0x65 , 0x73 , 0x73 , 0x12 , 0x18 , 0x0a , 0x07 ,
0x77 , 0x69 , 0x74 , 0x6e , 0x65 , 0x73 , 0x73 , 0x18 , 0x01 , 0x20 , 0x01 , 0x28 , 0x0c , 0x52 , 0x07 , 0x77 ,
0x69 , 0x74 , 0x6e , 0x65 , 0x73 , 0x73 , 0x42 , 0x7b , 0x0a , 0x0a , 0x63 , 0x6f , 0x6d , 0x2e , 0x64 , 0x69 ,
0x64 , 0x2e , 0x76 , 0x31 , 0x42 , 0x0b , 0x4d , 0x6f , 0x64 , 0x65 , 0x6c , 0x73 , 0x50 , 0x72 , 0x6f , 0x74 ,
0x6f , 0x50 , 0x01 , 0x5a , 0x27 , 0x67 , 0x69 , 0x74 , 0x68 , 0x75 , 0x62 , 0x2e , 0x63 , 0x6f , 0x6d , 0x2f ,
0x6f , 0x6e , 0x73 , 0x6f , 0x6e , 0x72 , 0x2f , 0x73 , 0x6f , 0x6e , 0x72 , 0x2f , 0x61 , 0x70 , 0x69 , 0x2f ,
0x64 , 0x69 , 0x64 , 0x2f , 0x76 , 0x31 , 0x3b , 0x64 , 0x69 , 0x64 , 0x76 , 0x31 , 0xa2 , 0x02 , 0x03 , 0x44 ,
0x58 , 0x58 , 0xaa , 0x02 , 0x06 , 0x44 , 0x69 , 0x64 , 0x2e , 0x56 , 0x31 , 0xca , 0x02 , 0x06 , 0x44 , 0x69 ,
0x64 , 0x5c , 0x56 , 0x31 , 0xe2 , 0x02 , 0x12 , 0x44 , 0x69 , 0x64 , 0x5c , 0x56 , 0x31 , 0x5c , 0x47 , 0x50 ,
0x42 , 0x4d , 0x65 , 0x74 , 0x61 , 0x64 , 0x61 , 0x74 , 0x61 , 0xea , 0x02 , 0x07 , 0x44 , 0x69 , 0x64 , 0x3a ,
0x3a , 0x56 , 0x31 , 0x62 , 0x06 , 0x70 , 0x72 , 0x6f , 0x74 , 0x6f , 0x33 ,
2024-07-05 22:20:13 -04:00
}
var (
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_rawDescOnce sync . Once
file_did_v1_models_proto_rawDescData = file_did_v1_models_proto_rawDesc
2024-07-05 22:20:13 -04:00
)
2024-08-31 12:49:44 -04:00
func file_did_v1_models_proto_rawDescGZIP () [] byte {
file_did_v1_models_proto_rawDescOnce . Do ( func () {
file_did_v1_models_proto_rawDescData = protoimpl . X . CompressGZIP ( file_did_v1_models_proto_rawDescData )
2024-07-05 22:20:13 -04:00
})
2024-08-31 12:49:44 -04:00
return file_did_v1_models_proto_rawDescData
}
2024-09-05 01:24:57 -04:00
var file_did_v1_models_proto_msgTypes = make ([] protoimpl . MessageInfo , 16 )
2024-08-31 12:49:44 -04:00
var file_did_v1_models_proto_goTypes = [] interface {}{
2024-09-05 01:24:57 -04:00
( * Accumulator )( nil ), // 0: did.v1.Accumulator
2024-08-31 12:49:44 -04:00
( * Credential )( nil ), // 1: did.v1.Credential
2024-09-05 01:24:57 -04:00
( * DID )( nil ), // 2: did.v1.DID
( * Document )( nil ), // 3: did.v1.Document
( * Metadata )( nil ), // 4: did.v1.Metadata
( * Permissions )( nil ), // 5: did.v1.Permissions
( * Profile )( nil ), // 6: did.v1.Profile
( * Property )( nil ), // 7: did.v1.Property
( * PubKey )( nil ), // 8: did.v1.PubKey
( * Service )( nil ), // 9: did.v1.Service
( * Token )( nil ), // 10: did.v1.Token
( * VerificationMethod )( nil ), // 11: did.v1.VerificationMethod
( * Witness )( nil ), // 12: did.v1.Witness
nil , // 13: did.v1.Metadata.PublicEntry
nil , // 14: did.v1.Metadata.PrivateEntry
nil , // 15: did.v1.PubKey.JwkEntry
( DIDNamespace )( 0 ), // 16: did.v1.DIDNamespace
( PermissionScope )( 0 ), // 17: did.v1.PermissionScope
( KeyRole )( 0 ), // 18: did.v1.KeyRole
( KeyAlgorithm )( 0 ), // 19: did.v1.KeyAlgorithm
( KeyEncoding )( 0 ), // 20: did.v1.KeyEncoding
( * OpenIDConfig )( nil ), // 21: did.v1.OpenIDConfig
2024-08-31 12:49:44 -04:00
}
var file_did_v1_models_proto_depIdxs = [] int32 {
2024-09-05 01:24:57 -04:00
16 , // 0: did.v1.DID.method:type_name -> did.v1.DIDNamespace
11 , // 1: did.v1.Document.verification_methods:type_name -> did.v1.VerificationMethod
13 , // 2: did.v1.Metadata.public:type_name -> did.v1.Metadata.PublicEntry
14 , // 3: did.v1.Metadata.private:type_name -> did.v1.Metadata.PrivateEntry
16 , // 4: did.v1.Permissions.grants:type_name -> did.v1.DIDNamespace
17 , // 5: did.v1.Permissions.scopes:type_name -> did.v1.PermissionScope
4 , // 6: did.v1.Profile.metadata:type_name -> did.v1.Metadata
18 , // 7: did.v1.PubKey.role:type_name -> did.v1.KeyRole
19 , // 8: did.v1.PubKey.algorithm:type_name -> did.v1.KeyAlgorithm
20 , // 9: did.v1.PubKey.encoding:type_name -> did.v1.KeyEncoding
15 , // 10: did.v1.PubKey.jwk:type_name -> did.v1.PubKey.JwkEntry
5 , // 11: did.v1.Service.permissions:type_name -> did.v1.Permissions
21 , // 12: did.v1.Service.openid:type_name -> did.v1.OpenIDConfig
4 , // 13: did.v1.Service.metadata:type_name -> did.v1.Metadata
16 , // 14: did.v1.VerificationMethod.method:type_name -> did.v1.DIDNamespace
8 , // 15: did.v1.VerificationMethod.public_key:type_name -> did.v1.PubKey
9 , // 16: did.v1.VerificationMethod.service:type_name -> did.v1.Service
7 , // 17: did.v1.Metadata.PrivateEntry.value:type_name -> did.v1.Property
18 , // [18:18] is the sub-list for method output_type
18 , // [18:18] is the sub-list for method input_type
18 , // [18:18] is the sub-list for extension type_name
18 , // [18:18] is the sub-list for extension extendee
0 , // [0:18] is the sub-list for field type_name
2024-08-31 12:49:44 -04:00
}
func init () { file_did_v1_models_proto_init () }
func file_did_v1_models_proto_init () {
if File_did_v1_models_proto != nil {
2024-07-05 22:20:13 -04:00
return
}
2024-09-05 01:24:57 -04:00
file_did_v1_constants_proto_init ()
2024-08-31 12:49:44 -04:00
file_did_v1_genesis_proto_init ()
2024-07-05 22:20:13 -04:00
if ! protoimpl . UnsafeEnabled {
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_msgTypes [ 0 ]. Exporter = func ( v interface {}, i int ) interface {} {
2024-09-05 01:24:57 -04:00
switch v := v .( * Accumulator ); i {
2024-08-10 17:01:14 -04:00
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_msgTypes [ 1 ]. Exporter = func ( v interface {}, i int ) interface {} {
2024-08-10 17:19:59 -04:00
switch v := v .( * Credential ); i {
2024-08-10 17:01:14 -04:00
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_msgTypes [ 2 ]. Exporter = func ( v interface {}, i int ) interface {} {
2024-09-05 01:24:57 -04:00
switch v := v .( * DID ); i {
2024-08-10 17:01:14 -04:00
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_msgTypes [ 3 ]. Exporter = func ( v interface {}, i int ) interface {} {
2024-09-05 01:24:57 -04:00
switch v := v .( * Document ); i {
2024-08-10 17:19:59 -04:00
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_msgTypes [ 4 ]. Exporter = func ( v interface {}, i int ) interface {} {
2024-09-05 01:24:57 -04:00
switch v := v .( * Metadata ); i {
2024-08-10 17:19:59 -04:00
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_msgTypes [ 5 ]. Exporter = func ( v interface {}, i int ) interface {} {
2024-09-05 01:24:57 -04:00
switch v := v .( * Permissions ); i {
2024-08-10 17:19:59 -04:00
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_msgTypes [ 6 ]. Exporter = func ( v interface {}, i int ) interface {} {
2024-09-05 01:24:57 -04:00
switch v := v .( * Profile ); i {
2024-08-10 17:19:59 -04:00
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_msgTypes [ 7 ]. Exporter = func ( v interface {}, i int ) interface {} {
2024-09-05 01:24:57 -04:00
switch v := v .( * Property ); i {
2024-08-10 17:19:59 -04:00
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
2024-08-31 12:49:44 -04:00
file_did_v1_models_proto_msgTypes [ 8 ]. Exporter = func ( v interface {}, i int ) interface {} {
2024-09-05 01:24:57 -04:00
switch v := v .( * PubKey ); i {
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
file_did_v1_models_proto_msgTypes [ 9 ]. Exporter = func ( v interface {}, i int ) interface {} {
switch v := v .( * Service ); i {
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
file_did_v1_models_proto_msgTypes [ 10 ]. Exporter = func ( v interface {}, i int ) interface {} {
switch v := v .( * Token ); i {
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
file_did_v1_models_proto_msgTypes [ 11 ]. Exporter = func ( v interface {}, i int ) interface {} {
2024-07-05 22:20:13 -04:00
switch v := v .( * VerificationMethod ); i {
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
2024-09-05 01:24:57 -04:00
file_did_v1_models_proto_msgTypes [ 12 ]. Exporter = func ( v interface {}, i int ) interface {} {
switch v := v .( * Witness ); i {
case 0 :
return & v . state
case 1 :
return & v . sizeCache
case 2 :
return & v . unknownFields
default :
return nil
}
}
2024-07-05 22:20:13 -04:00
}
type x struct {}
out := protoimpl . TypeBuilder {
File : protoimpl . DescBuilder {
GoPackagePath : reflect . TypeOf ( x {}). PkgPath (),
2024-08-31 12:49:44 -04:00
RawDescriptor : file_did_v1_models_proto_rawDesc ,
2024-07-05 22:20:13 -04:00
NumEnums : 0 ,
2024-09-05 01:24:57 -04:00
NumMessages : 16 ,
2024-07-05 22:20:13 -04:00
NumExtensions : 0 ,
NumServices : 0 ,
},
2024-08-31 12:49:44 -04:00
GoTypes : file_did_v1_models_proto_goTypes ,
DependencyIndexes : file_did_v1_models_proto_depIdxs ,
MessageInfos : file_did_v1_models_proto_msgTypes ,
2024-07-05 22:20:13 -04:00
}. Build ()
2024-08-31 12:49:44 -04:00
File_did_v1_models_proto = out . File
file_did_v1_models_proto_rawDesc = nil
file_did_v1_models_proto_goTypes = nil
file_did_v1_models_proto_depIdxs = nil
2024-07-05 22:20:13 -04:00
}