pb

package
v1.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 6, 2022 License: Apache-2.0, MIT, Apache-2.0, + 1 more Imports: 4 Imported by: 0

Documentation

Overview

Package pb provides protobuf definitions for serialized types in Cluster.

Index

Constants

This section is empty.

Variables

View Source
var (
	Pin_PinType_name = map[int32]string{
		0: "BadType",
		1: "DataType",
		2: "MetaType",
		3: "ClusterDAGType",
		4: "ShardType",
	}
	Pin_PinType_value = map[string]int32{
		"BadType":        0,
		"DataType":       1,
		"MetaType":       2,
		"ClusterDAGType": 3,
		"ShardType":      4,
	}
)

Enum value maps for Pin_PinType.

View Source
var File_types_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Metadata added in v1.0.1

type Metadata struct {
	Key   string `protobuf:"bytes,1,opt,name=Key,proto3" json:"Key,omitempty"`
	Value string `protobuf:"bytes,2,opt,name=Value,proto3" json:"Value,omitempty"`
	// contains filtered or unexported fields
}

func (*Metadata) Descriptor deprecated added in v1.0.1

func (*Metadata) Descriptor() ([]byte, []int)

Deprecated: Use Metadata.ProtoReflect.Descriptor instead.

func (*Metadata) GetKey added in v1.0.1

func (x *Metadata) GetKey() string

func (*Metadata) GetValue added in v1.0.1

func (x *Metadata) GetValue() string

func (*Metadata) ProtoMessage added in v1.0.1

func (*Metadata) ProtoMessage()

func (*Metadata) ProtoReflect added in v1.0.1

func (x *Metadata) ProtoReflect() protoreflect.Message

func (*Metadata) Reset added in v1.0.1

func (x *Metadata) Reset()

func (*Metadata) String added in v1.0.1

func (x *Metadata) String() string

type Pin

type Pin struct {
	Cid         []byte      `protobuf:"bytes,1,opt,name=Cid,proto3" json:"Cid,omitempty"`
	Type        Pin_PinType `protobuf:"varint,2,opt,name=Type,proto3,enum=api.pb.Pin_PinType" json:"Type,omitempty"`
	Allocations [][]byte    `protobuf:"bytes,3,rep,name=Allocations,proto3" json:"Allocations,omitempty"`
	MaxDepth    int32       `protobuf:"zigzag32,4,opt,name=MaxDepth,proto3" json:"MaxDepth,omitempty"`
	Reference   []byte      `protobuf:"bytes,5,opt,name=Reference,proto3" json:"Reference,omitempty"`
	Options     *PinOptions `protobuf:"bytes,6,opt,name=Options,proto3" json:"Options,omitempty"`
	Timestamp   uint64      `protobuf:"varint,7,opt,name=Timestamp,proto3" json:"Timestamp,omitempty"`
	// contains filtered or unexported fields
}

func (*Pin) Descriptor deprecated

func (*Pin) Descriptor() ([]byte, []int)

Deprecated: Use Pin.ProtoReflect.Descriptor instead.

func (*Pin) GetAllocations

func (x *Pin) GetAllocations() [][]byte

func (*Pin) GetCid

func (x *Pin) GetCid() []byte

func (*Pin) GetMaxDepth

func (x *Pin) GetMaxDepth() int32

func (*Pin) GetOptions

func (x *Pin) GetOptions() *PinOptions

func (*Pin) GetReference

func (x *Pin) GetReference() []byte

func (*Pin) GetTimestamp added in v0.14.2

func (x *Pin) GetTimestamp() uint64

func (*Pin) GetType

func (x *Pin) GetType() Pin_PinType

func (*Pin) ProtoMessage

func (*Pin) ProtoMessage()

func (*Pin) ProtoReflect added in v0.13.0

func (x *Pin) ProtoReflect() protoreflect.Message

func (*Pin) Reset

func (x *Pin) Reset()

func (*Pin) String

func (x *Pin) String() string

type PinOptions

type PinOptions struct {
	ReplicationFactorMin int32  `protobuf:"zigzag32,1,opt,name=ReplicationFactorMin,proto3" json:"ReplicationFactorMin,omitempty"`
	ReplicationFactorMax int32  `protobuf:"zigzag32,2,opt,name=ReplicationFactorMax,proto3" json:"ReplicationFactorMax,omitempty"`
	Name                 string `protobuf:"bytes,3,opt,name=Name,proto3" json:"Name,omitempty"`
	ShardSize            uint64 `protobuf:"varint,4,opt,name=ShardSize,proto3" json:"ShardSize,omitempty"`
	// Deprecated: Do not use.
	Metadata       map[string]string `` /* 157-byte string literal not displayed */
	PinUpdate      []byte            `protobuf:"bytes,7,opt,name=PinUpdate,proto3" json:"PinUpdate,omitempty"`
	ExpireAt       uint64            `protobuf:"varint,8,opt,name=ExpireAt,proto3" json:"ExpireAt,omitempty"`
	Origins        [][]byte          `protobuf:"bytes,9,rep,name=Origins,proto3" json:"Origins,omitempty"`
	SortedMetadata []*Metadata       `protobuf:"bytes,10,rep,name=SortedMetadata,proto3" json:"SortedMetadata,omitempty"`
	// contains filtered or unexported fields
}

func (*PinOptions) Descriptor deprecated

func (*PinOptions) Descriptor() ([]byte, []int)

Deprecated: Use PinOptions.ProtoReflect.Descriptor instead.

func (*PinOptions) GetExpireAt added in v0.12.0

func (x *PinOptions) GetExpireAt() uint64

func (*PinOptions) GetMetadata deprecated

func (x *PinOptions) GetMetadata() map[string]string

Deprecated: Do not use.

func (*PinOptions) GetName

func (x *PinOptions) GetName() string

func (*PinOptions) GetOrigins added in v0.14.0

func (x *PinOptions) GetOrigins() [][]byte

func (*PinOptions) GetPinUpdate added in v0.11.0

func (x *PinOptions) GetPinUpdate() []byte

func (*PinOptions) GetReplicationFactorMax

func (x *PinOptions) GetReplicationFactorMax() int32

func (*PinOptions) GetReplicationFactorMin

func (x *PinOptions) GetReplicationFactorMin() int32

func (*PinOptions) GetShardSize

func (x *PinOptions) GetShardSize() uint64

func (*PinOptions) GetSortedMetadata added in v1.0.1

func (x *PinOptions) GetSortedMetadata() []*Metadata

func (*PinOptions) ProtoMessage

func (*PinOptions) ProtoMessage()

func (*PinOptions) ProtoReflect added in v0.13.0

func (x *PinOptions) ProtoReflect() protoreflect.Message

func (*PinOptions) Reset

func (x *PinOptions) Reset()

func (*PinOptions) String

func (x *PinOptions) String() string

type Pin_PinType

type Pin_PinType int32
const (
	Pin_BadType        Pin_PinType = 0 // 1 << iota
	Pin_DataType       Pin_PinType = 1 // 2 << iota
	Pin_MetaType       Pin_PinType = 2
	Pin_ClusterDAGType Pin_PinType = 3
	Pin_ShardType      Pin_PinType = 4
)

func (Pin_PinType) Descriptor added in v0.13.0

func (Pin_PinType) Enum added in v0.13.0

func (x Pin_PinType) Enum() *Pin_PinType

func (Pin_PinType) EnumDescriptor deprecated

func (Pin_PinType) EnumDescriptor() ([]byte, []int)

Deprecated: Use Pin_PinType.Descriptor instead.

func (Pin_PinType) Number added in v0.13.0

func (x Pin_PinType) Number() protoreflect.EnumNumber

func (Pin_PinType) String

func (x Pin_PinType) String() string

func (Pin_PinType) Type added in v0.13.0

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL