docs(marketing): improve section data model and section rendering

This commit is contained in:
Prad Nukala
2024-10-24 16:11:30 -04:00
parent c8657022a2
commit f14f6ff536
9 changed files with 97 additions and 1007 deletions
+25 -694
View File
@@ -2763,610 +2763,6 @@ func (x *fastReflection_Caveats) ProtoMethods() *protoiface.Methods {
}
}
var _ protoreflect.List = (*_Transactions_1_list)(nil)
type _Transactions_1_list struct {
list *[]string
}
func (x *_Transactions_1_list) Len() int {
if x.list == nil {
return 0
}
return len(*x.list)
}
func (x *_Transactions_1_list) Get(i int) protoreflect.Value {
return protoreflect.ValueOfString((*x.list)[i])
}
func (x *_Transactions_1_list) Set(i int, value protoreflect.Value) {
valueUnwrapped := value.String()
concreteValue := valueUnwrapped
(*x.list)[i] = concreteValue
}
func (x *_Transactions_1_list) Append(value protoreflect.Value) {
valueUnwrapped := value.String()
concreteValue := valueUnwrapped
*x.list = append(*x.list, concreteValue)
}
func (x *_Transactions_1_list) AppendMutable() protoreflect.Value {
panic(fmt.Errorf("AppendMutable can not be called on message Transactions at list field Allowlist as it is not of Message kind"))
}
func (x *_Transactions_1_list) Truncate(n int) {
*x.list = (*x.list)[:n]
}
func (x *_Transactions_1_list) NewElement() protoreflect.Value {
v := ""
return protoreflect.ValueOfString(v)
}
func (x *_Transactions_1_list) IsValid() bool {
return x.list != nil
}
var _ protoreflect.List = (*_Transactions_2_list)(nil)
type _Transactions_2_list struct {
list *[]string
}
func (x *_Transactions_2_list) Len() int {
if x.list == nil {
return 0
}
return len(*x.list)
}
func (x *_Transactions_2_list) Get(i int) protoreflect.Value {
return protoreflect.ValueOfString((*x.list)[i])
}
func (x *_Transactions_2_list) Set(i int, value protoreflect.Value) {
valueUnwrapped := value.String()
concreteValue := valueUnwrapped
(*x.list)[i] = concreteValue
}
func (x *_Transactions_2_list) Append(value protoreflect.Value) {
valueUnwrapped := value.String()
concreteValue := valueUnwrapped
*x.list = append(*x.list, concreteValue)
}
func (x *_Transactions_2_list) AppendMutable() protoreflect.Value {
panic(fmt.Errorf("AppendMutable can not be called on message Transactions at list field Denylist as it is not of Message kind"))
}
func (x *_Transactions_2_list) Truncate(n int) {
*x.list = (*x.list)[:n]
}
func (x *_Transactions_2_list) NewElement() protoreflect.Value {
v := ""
return protoreflect.ValueOfString(v)
}
func (x *_Transactions_2_list) IsValid() bool {
return x.list != nil
}
var (
md_Transactions protoreflect.MessageDescriptor
fd_Transactions_allowlist protoreflect.FieldDescriptor
fd_Transactions_denylist protoreflect.FieldDescriptor
)
func init() {
file_macaroon_v1_genesis_proto_init()
md_Transactions = File_macaroon_v1_genesis_proto.Messages().ByName("Transactions")
fd_Transactions_allowlist = md_Transactions.Fields().ByName("allowlist")
fd_Transactions_denylist = md_Transactions.Fields().ByName("denylist")
}
var _ protoreflect.Message = (*fastReflection_Transactions)(nil)
type fastReflection_Transactions Transactions
func (x *Transactions) ProtoReflect() protoreflect.Message {
return (*fastReflection_Transactions)(x)
}
func (x *Transactions) slowProtoReflect() protoreflect.Message {
mi := &file_macaroon_v1_genesis_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_Transactions_messageType fastReflection_Transactions_messageType
var _ protoreflect.MessageType = fastReflection_Transactions_messageType{}
type fastReflection_Transactions_messageType struct{}
func (x fastReflection_Transactions_messageType) Zero() protoreflect.Message {
return (*fastReflection_Transactions)(nil)
}
func (x fastReflection_Transactions_messageType) New() protoreflect.Message {
return new(fastReflection_Transactions)
}
func (x fastReflection_Transactions_messageType) Descriptor() protoreflect.MessageDescriptor {
return md_Transactions
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func (x *fastReflection_Transactions) Descriptor() protoreflect.MessageDescriptor {
return md_Transactions
}
// 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_Transactions) Type() protoreflect.MessageType {
return _fastReflection_Transactions_messageType
}
// New returns a newly allocated and mutable empty message.
func (x *fastReflection_Transactions) New() protoreflect.Message {
return new(fastReflection_Transactions)
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func (x *fastReflection_Transactions) Interface() protoreflect.ProtoMessage {
return (*Transactions)(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_Transactions) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {
if len(x.Allowlist) != 0 {
value := protoreflect.ValueOfList(&_Transactions_1_list{list: &x.Allowlist})
if !f(fd_Transactions_allowlist, value) {
return
}
}
if len(x.Denylist) != 0 {
value := protoreflect.ValueOfList(&_Transactions_2_list{list: &x.Denylist})
if !f(fd_Transactions_denylist, 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_Transactions) Has(fd protoreflect.FieldDescriptor) bool {
switch fd.FullName() {
case "macaroon.v1.Transactions.allowlist":
return len(x.Allowlist) != 0
case "macaroon.v1.Transactions.denylist":
return len(x.Denylist) != 0
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: macaroon.v1.Transactions"))
}
panic(fmt.Errorf("message macaroon.v1.Transactions 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_Transactions) Clear(fd protoreflect.FieldDescriptor) {
switch fd.FullName() {
case "macaroon.v1.Transactions.allowlist":
x.Allowlist = nil
case "macaroon.v1.Transactions.denylist":
x.Denylist = nil
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: macaroon.v1.Transactions"))
}
panic(fmt.Errorf("message macaroon.v1.Transactions 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_Transactions) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value {
switch descriptor.FullName() {
case "macaroon.v1.Transactions.allowlist":
if len(x.Allowlist) == 0 {
return protoreflect.ValueOfList(&_Transactions_1_list{})
}
listValue := &_Transactions_1_list{list: &x.Allowlist}
return protoreflect.ValueOfList(listValue)
case "macaroon.v1.Transactions.denylist":
if len(x.Denylist) == 0 {
return protoreflect.ValueOfList(&_Transactions_2_list{})
}
listValue := &_Transactions_2_list{list: &x.Denylist}
return protoreflect.ValueOfList(listValue)
default:
if descriptor.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: macaroon.v1.Transactions"))
}
panic(fmt.Errorf("message macaroon.v1.Transactions 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_Transactions) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) {
switch fd.FullName() {
case "macaroon.v1.Transactions.allowlist":
lv := value.List()
clv := lv.(*_Transactions_1_list)
x.Allowlist = *clv.list
case "macaroon.v1.Transactions.denylist":
lv := value.List()
clv := lv.(*_Transactions_2_list)
x.Denylist = *clv.list
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: macaroon.v1.Transactions"))
}
panic(fmt.Errorf("message macaroon.v1.Transactions 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_Transactions) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "macaroon.v1.Transactions.allowlist":
if x.Allowlist == nil {
x.Allowlist = []string{}
}
value := &_Transactions_1_list{list: &x.Allowlist}
return protoreflect.ValueOfList(value)
case "macaroon.v1.Transactions.denylist":
if x.Denylist == nil {
x.Denylist = []string{}
}
value := &_Transactions_2_list{list: &x.Denylist}
return protoreflect.ValueOfList(value)
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: macaroon.v1.Transactions"))
}
panic(fmt.Errorf("message macaroon.v1.Transactions 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_Transactions) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "macaroon.v1.Transactions.allowlist":
list := []string{}
return protoreflect.ValueOfList(&_Transactions_1_list{list: &list})
case "macaroon.v1.Transactions.denylist":
list := []string{}
return protoreflect.ValueOfList(&_Transactions_2_list{list: &list})
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: macaroon.v1.Transactions"))
}
panic(fmt.Errorf("message macaroon.v1.Transactions 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_Transactions) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor {
switch d.FullName() {
default:
panic(fmt.Errorf("%s is not a oneof field in macaroon.v1.Transactions", 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_Transactions) 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_Transactions) 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_Transactions) 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_Transactions) ProtoMethods() *protoiface.Methods {
size := func(input protoiface.SizeInput) protoiface.SizeOutput {
x := input.Message.Interface().(*Transactions)
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.Allowlist) > 0 {
for _, s := range x.Allowlist {
l = len(s)
n += 1 + l + runtime.Sov(uint64(l))
}
}
if len(x.Denylist) > 0 {
for _, s := range x.Denylist {
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().(*Transactions)
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.Denylist) > 0 {
for iNdEx := len(x.Denylist) - 1; iNdEx >= 0; iNdEx-- {
i -= len(x.Denylist[iNdEx])
copy(dAtA[i:], x.Denylist[iNdEx])
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Denylist[iNdEx])))
i--
dAtA[i] = 0x12
}
}
if len(x.Allowlist) > 0 {
for iNdEx := len(x.Allowlist) - 1; iNdEx >= 0; iNdEx-- {
i -= len(x.Allowlist[iNdEx])
copy(dAtA[i:], x.Allowlist[iNdEx])
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Allowlist[iNdEx])))
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().(*Transactions)
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: Transactions: wiretype end group for non-group")
}
if fieldNum <= 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Transactions: 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 Allowlist", 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.Allowlist = append(x.Allowlist, 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 Denylist", 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.Denylist = append(x.Denylist, 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.List = (*_Caveat_1_list)(nil)
type _Caveat_1_list struct {
@@ -3437,7 +2833,7 @@ func (x *Caveat) ProtoReflect() protoreflect.Message {
}
func (x *Caveat) slowProtoReflect() protoreflect.Message {
mi := &file_macaroon_v1_genesis_proto_msgTypes[6]
mi := &file_macaroon_v1_genesis_proto_msgTypes[5]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -4212,51 +3608,6 @@ func (x *Caveats) GetSupportedThirdParty() []*Caveat {
return nil
}
// Transactions defines the allowlist,denylist for transactions which can be
// broadcasted to the network with the Sonr DWN Signed macaroon.
type Transactions struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Allowlist []string `protobuf:"bytes,1,rep,name=allowlist,proto3" json:"allowlist,omitempty"`
Denylist []string `protobuf:"bytes,2,rep,name=denylist,proto3" json:"denylist,omitempty"`
}
func (x *Transactions) Reset() {
*x = Transactions{}
if protoimpl.UnsafeEnabled {
mi := &file_macaroon_v1_genesis_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *Transactions) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*Transactions) ProtoMessage() {}
// Deprecated: Use Transactions.ProtoReflect.Descriptor instead.
func (*Transactions) Descriptor() ([]byte, []int) {
return file_macaroon_v1_genesis_proto_rawDescGZIP(), []int{5}
}
func (x *Transactions) GetAllowlist() []string {
if x != nil {
return x.Allowlist
}
return nil
}
func (x *Transactions) GetDenylist() []string {
if x != nil {
return x.Denylist
}
return nil
}
type Caveat struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
@@ -4270,7 +3621,7 @@ type Caveat struct {
func (x *Caveat) Reset() {
*x = Caveat{}
if protoimpl.UnsafeEnabled {
mi := &file_macaroon_v1_genesis_proto_msgTypes[6]
mi := &file_macaroon_v1_genesis_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -4284,7 +3635,7 @@ func (*Caveat) ProtoMessage() {}
// Deprecated: Use Caveat.ProtoReflect.Descriptor instead.
func (*Caveat) Descriptor() ([]byte, []int) {
return file_macaroon_v1_genesis_proto_rawDescGZIP(), []int{6}
return file_macaroon_v1_genesis_proto_rawDescGZIP(), []int{5}
}
func (x *Caveat) GetScopes() []string {
@@ -4355,30 +3706,23 @@ var file_macaroon_v1_genesis_proto_rawDesc = []byte{
0x31, 0x2e, 0x43, 0x61, 0x76, 0x65, 0x61, 0x74, 0x52, 0x13, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72,
0x74, 0x65, 0x64, 0x54, 0x68, 0x69, 0x72, 0x64, 0x50, 0x61, 0x72, 0x74, 0x79, 0x3a, 0x19, 0xe8,
0xa0, 0x1f, 0x01, 0x8a, 0xe7, 0xb0, 0x2a, 0x10, 0x6d, 0x61, 0x63, 0x61, 0x72, 0x6f, 0x6f, 0x6e,
0x2f, 0x63, 0x61, 0x76, 0x65, 0x61, 0x74, 0x73, 0x22, 0x68, 0x0a, 0x0c, 0x54, 0x72, 0x61, 0x6e,
0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x6c, 0x6c, 0x6f,
0x77, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x09, 0x61, 0x6c, 0x6c,
0x6f, 0x77, 0x6c, 0x69, 0x73, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x64, 0x65, 0x6e, 0x79, 0x6c, 0x69,
0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x08, 0x64, 0x65, 0x6e, 0x79, 0x6c, 0x69,
0x73, 0x74, 0x3a, 0x1e, 0xe8, 0xa0, 0x1f, 0x01, 0x8a, 0xe7, 0xb0, 0x2a, 0x15, 0x6d, 0x61, 0x63,
0x61, 0x72, 0x6f, 0x6f, 0x6e, 0x2f, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f,
0x6e, 0x73, 0x22, 0x5a, 0x0a, 0x06, 0x43, 0x61, 0x76, 0x65, 0x61, 0x74, 0x12, 0x16, 0x0a, 0x06,
0x73, 0x63, 0x6f, 0x70, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x73, 0x63,
0x6f, 0x70, 0x65, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x63, 0x61, 0x76, 0x65, 0x61, 0x74, 0x18, 0x02,
0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x63, 0x61, 0x76, 0x65, 0x61, 0x74, 0x12, 0x20, 0x0a, 0x0b,
0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28,
0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x9f,
0x01, 0x0a, 0x0f, 0x63, 0x6f, 0x6d, 0x2e, 0x6d, 0x61, 0x63, 0x61, 0x72, 0x6f, 0x6f, 0x6e, 0x2e,
0x76, 0x31, 0x42, 0x0c, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f,
0x50, 0x01, 0x5a, 0x31, 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, 0x6d,
0x61, 0x63, 0x61, 0x72, 0x6f, 0x6f, 0x6e, 0x2f, 0x76, 0x31, 0x3b, 0x6d, 0x61, 0x63, 0x61, 0x72,
0x6f, 0x6f, 0x6e, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x4d, 0x58, 0x58, 0xaa, 0x02, 0x0b, 0x4d, 0x61,
0x63, 0x61, 0x72, 0x6f, 0x6f, 0x6e, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0b, 0x4d, 0x61, 0x63, 0x61,
0x72, 0x6f, 0x6f, 0x6e, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x17, 0x4d, 0x61, 0x63, 0x61, 0x72, 0x6f,
0x6f, 0x6e, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74,
0x61, 0xea, 0x02, 0x0c, 0x4d, 0x61, 0x63, 0x61, 0x72, 0x6f, 0x6f, 0x6e, 0x3a, 0x3a, 0x56, 0x31,
0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x2f, 0x63, 0x61, 0x76, 0x65, 0x61, 0x74, 0x73, 0x22, 0x5a, 0x0a, 0x06, 0x43, 0x61, 0x76, 0x65,
0x61, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03,
0x28, 0x09, 0x52, 0x06, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x63, 0x61,
0x76, 0x65, 0x61, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x63, 0x61, 0x76, 0x65,
0x61, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f,
0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70,
0x74, 0x69, 0x6f, 0x6e, 0x42, 0x9f, 0x01, 0x0a, 0x0f, 0x63, 0x6f, 0x6d, 0x2e, 0x6d, 0x61, 0x63,
0x61, 0x72, 0x6f, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x42, 0x0c, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69,
0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x31, 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, 0x6d, 0x61, 0x63, 0x61, 0x72, 0x6f, 0x6f, 0x6e, 0x2f, 0x76, 0x31,
0x3b, 0x6d, 0x61, 0x63, 0x61, 0x72, 0x6f, 0x6f, 0x6e, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x4d, 0x58,
0x58, 0xaa, 0x02, 0x0b, 0x4d, 0x61, 0x63, 0x61, 0x72, 0x6f, 0x6f, 0x6e, 0x2e, 0x56, 0x31, 0xca,
0x02, 0x0b, 0x4d, 0x61, 0x63, 0x61, 0x72, 0x6f, 0x6f, 0x6e, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x17,
0x4d, 0x61, 0x63, 0x61, 0x72, 0x6f, 0x6f, 0x6e, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d,
0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0c, 0x4d, 0x61, 0x63, 0x61, 0x72, 0x6f,
0x6f, 0x6e, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (
@@ -4393,23 +3737,22 @@ func file_macaroon_v1_genesis_proto_rawDescGZIP() []byte {
return file_macaroon_v1_genesis_proto_rawDescData
}
var file_macaroon_v1_genesis_proto_msgTypes = make([]protoimpl.MessageInfo, 7)
var file_macaroon_v1_genesis_proto_msgTypes = make([]protoimpl.MessageInfo, 6)
var file_macaroon_v1_genesis_proto_goTypes = []interface{}{
(*GenesisState)(nil), // 0: macaroon.v1.GenesisState
(*Params)(nil), // 1: macaroon.v1.Params
(*Methods)(nil), // 2: macaroon.v1.Methods
(*Scopes)(nil), // 3: macaroon.v1.Scopes
(*Caveats)(nil), // 4: macaroon.v1.Caveats
(*Transactions)(nil), // 5: macaroon.v1.Transactions
(*Caveat)(nil), // 6: macaroon.v1.Caveat
(*Caveat)(nil), // 5: macaroon.v1.Caveat
}
var file_macaroon_v1_genesis_proto_depIdxs = []int32{
1, // 0: macaroon.v1.GenesisState.params:type_name -> macaroon.v1.Params
2, // 1: macaroon.v1.Params.methods:type_name -> macaroon.v1.Methods
3, // 2: macaroon.v1.Params.scopes:type_name -> macaroon.v1.Scopes
4, // 3: macaroon.v1.Params.caveats:type_name -> macaroon.v1.Caveats
6, // 4: macaroon.v1.Caveats.supported_first_party:type_name -> macaroon.v1.Caveat
6, // 5: macaroon.v1.Caveats.supported_third_party:type_name -> macaroon.v1.Caveat
5, // 4: macaroon.v1.Caveats.supported_first_party:type_name -> macaroon.v1.Caveat
5, // 5: macaroon.v1.Caveats.supported_third_party:type_name -> macaroon.v1.Caveat
6, // [6:6] is the sub-list for method output_type
6, // [6:6] is the sub-list for method input_type
6, // [6:6] is the sub-list for extension type_name
@@ -4484,18 +3827,6 @@ func file_macaroon_v1_genesis_proto_init() {
}
}
file_macaroon_v1_genesis_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*Transactions); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_macaroon_v1_genesis_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*Caveat); i {
case 0:
return &v.state
@@ -4514,7 +3845,7 @@ func file_macaroon_v1_genesis_proto_init() {
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_macaroon_v1_genesis_proto_rawDesc,
NumEnums: 0,
NumMessages: 7,
NumMessages: 6,
NumExtensions: 0,
NumServices: 0,
},