Documentation
¶
Index ¶
- Variables
- func Template() string
- type Author
- type Challenge
- func (*Challenge) Descriptor() ([]byte, []int)deprecated
- func (x *Challenge) GetName() string
- func (x *Challenge) GetRefer() string
- func (x *Challenge) GetTags() []string
- func (*Challenge) ProtoMessage()
- func (x *Challenge) ProtoReflect() protoreflect.Message
- func (x *Challenge) Reset()
- func (x *Challenge) String() string
- type Container
- func (*Container) Descriptor() ([]byte, []int)deprecated
- func (x *Container) GetImage() string
- func (x *Container) GetPorts() []string
- func (x *Container) GetResource() *Resource
- func (*Container) ProtoMessage()
- func (x *Container) ProtoReflect() protoreflect.Message
- func (x *Container) Reset()
- func (x *Container) String() string
- type Meta
- func Default() *Meta
- func Empty() *Meta
- func MustParseBytes(data []byte) ([]*Meta, error)
- func New(name, contact string) *Meta
- func NewSkill(id, pid, tid string, leaf int64, image, name string, level TaskLevel) *Meta
- func ParseBytes(data []byte) ([]*Meta, error)
- func ParseFromFile(fds ...multipart.File) ([]*Meta, error)
- func (*Meta) Descriptor() ([]byte, []int)deprecated
- func (x *Meta) GetAuthor() *Author
- func (x *Meta) GetChallenge() *Challenge
- func (x *Meta) GetContainers() []*Container
- func (x *Meta) GetSkill() *Skill
- func (x *Meta) GetTask() *Task
- func (m *Meta) NewSkill(id, pid, tid string, leaf int64, image, name string, level TaskLevel) *Meta
- func (t *Meta) ParseFormat() *Meta
- func (*Meta) ProtoMessage()
- func (x *Meta) ProtoReflect() protoreflect.Message
- func (m *Meta) R() *Meta
- func (x *Meta) Reset()
- func (x *Meta) String() string
- type Resource
- type Skill
- func (*Skill) Descriptor() ([]byte, []int)deprecated
- func (x *Skill) GetId() string
- func (x *Skill) GetLeaf() int64
- func (x *Skill) GetPid() string
- func (x *Skill) GetTid() string
- func (*Skill) ProtoMessage()
- func (x *Skill) ProtoReflect() protoreflect.Message
- func (x *Skill) Reset()
- func (x *Skill) String() string
- type Task
- func (*Task) Descriptor() ([]byte, []int)deprecated
- func (x *Task) GetAttachmentUrl() string
- func (x *Task) GetCategory() string
- func (x *Task) GetDescription() string
- func (x *Task) GetFlag() string
- func (x *Task) GetHints() []string
- func (x *Task) GetLevel() string
- func (x *Task) GetLevelCode() TaskLevel
- func (x *Task) GetName() string
- func (x *Task) GetType() string
- func (x *Task) GetTypeCode() TaskType
- func (t *Task) ParseFormat() *Task
- func (*Task) ProtoMessage()
- func (x *Task) ProtoReflect() protoreflect.Message
- func (x *Task) Reset()
- func (x *Task) String() string
- type TaskLevel
- type TaskType
Constants ¶
This section is empty.
Variables ¶
View Source
var ( TaskLevel_name = map[int32]string{ 0: "Checkin", 1: "Easy", 2: "Medium", 3: "Hard", } TaskLevel_value = map[string]int32{ "Checkin": 0, "Easy": 1, "Medium": 2, "Hard": 3, } )
Enum value maps for TaskLevel.
View Source
var ( TaskType_name = map[int32]string{ 0: "Unknown", 1: "Con", 2: "File", 3: "Ext", } TaskType_value = map[string]int32{ "Unknown": 0, "Con": 1, "File": 2, "Ext": 3, } )
Enum value maps for TaskType.
View Source
var File_meta_proto protoreflect.FileDescriptor
Functions ¶
Types ¶
type Author ¶
type Author struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Contact string `protobuf:"bytes,2,opt,name=contact,proto3" json:"contact,omitempty"` // contains filtered or unexported fields }
func (*Author) Descriptor
deprecated
added in
v1.0.9
func (*Author) GetContact ¶ added in v1.0.9
func (*Author) ProtoMessage ¶ added in v1.0.9
func (*Author) ProtoMessage()
func (*Author) ProtoReflect ¶ added in v1.0.9
func (x *Author) ProtoReflect() protoreflect.Message
type Challenge ¶
type Challenge struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Refer string `protobuf:"bytes,2,opt,name=refer,proto3" json:"refer,omitempty"` Tags []string `protobuf:"bytes,3,rep,name=tags,proto3" json:"tags,omitempty"` // contains filtered or unexported fields }
func (*Challenge) Descriptor
deprecated
added in
v1.0.9
func (*Challenge) ProtoMessage ¶ added in v1.0.9
func (*Challenge) ProtoMessage()
func (*Challenge) ProtoReflect ¶ added in v1.0.9
func (x *Challenge) ProtoReflect() protoreflect.Message
type Container ¶ added in v1.0.9
type Container struct { Image string `protobuf:"bytes,1,opt,name=image,proto3" json:"image,omitempty"` Ports []string `protobuf:"bytes,2,rep,name=ports,proto3" json:"ports,omitempty"` // Image Expose 端口 eg: 80/tcp Resource *Resource `protobuf:"bytes,3,opt,name=resource,proto3" json:"resource,omitempty"` // contains filtered or unexported fields }
func (*Container) Descriptor
deprecated
added in
v1.0.9
func (*Container) GetResource ¶ added in v1.0.9
func (*Container) ProtoMessage ¶ added in v1.0.9
func (*Container) ProtoMessage()
func (*Container) ProtoReflect ¶ added in v1.0.9
func (x *Container) ProtoReflect() protoreflect.Message
type Meta ¶
type Meta struct { Author *Author `protobuf:"bytes,1,opt,name=author,proto3" json:"author,omitempty"` Task *Task `protobuf:"bytes,2,opt,name=task,proto3" json:"task,omitempty"` Challenge *Challenge `protobuf:"bytes,3,opt,name=challenge,proto3" json:"challenge,omitempty"` Skill *Skill `protobuf:"bytes,4,opt,name=skill,proto3" json:"skill,omitempty"` Containers []*Container `protobuf:"bytes,5,rep,name=containers,proto3" json:"containers,omitempty"` // contains filtered or unexported fields }
func MustParseBytes ¶ added in v1.0.12
func ParseBytes ¶ added in v1.0.8
func (*Meta) Descriptor
deprecated
added in
v1.0.9
func (*Meta) GetChallenge ¶ added in v1.0.9
func (*Meta) GetContainers ¶ added in v1.0.11
func (*Meta) ParseFormat ¶ added in v1.0.11
func (*Meta) ProtoMessage ¶ added in v1.0.9
func (*Meta) ProtoMessage()
func (*Meta) ProtoReflect ¶ added in v1.0.9
func (x *Meta) ProtoReflect() protoreflect.Message
type Resource ¶ added in v1.0.9
type Resource struct { Cpu *resource.Quantity `protobuf:"bytes,1,opt,name=cpu,proto3" json:"cpu,omitempty"` Mem *resource.Quantity `protobuf:"bytes,2,opt,name=mem,proto3" json:"mem,omitempty"` // contains filtered or unexported fields }
func (*Resource) Descriptor
deprecated
added in
v1.0.9
func (*Resource) ProtoMessage ¶ added in v1.0.9
func (*Resource) ProtoMessage()
func (*Resource) ProtoReflect ¶ added in v1.0.9
func (x *Resource) ProtoReflect() protoreflect.Message
type Skill ¶
type Skill struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` Pid string `protobuf:"bytes,2,opt,name=pid,proto3" json:"pid,omitempty"` Tid string `protobuf:"bytes,3,opt,name=tid,proto3" json:"tid,omitempty"` Leaf int64 `protobuf:"varint,4,opt,name=leaf,proto3" json:"leaf,omitempty"` // 树叶节点 // contains filtered or unexported fields }
func (*Skill) Descriptor
deprecated
added in
v1.0.9
func (*Skill) ProtoMessage ¶ added in v1.0.9
func (*Skill) ProtoMessage()
func (*Skill) ProtoReflect ¶ added in v1.0.9
func (x *Skill) ProtoReflect() protoreflect.Message
type Task ¶
type Task struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Type string `protobuf:"bytes,2,opt,name=type,proto3" json:"type,omitempty"` TypeCode TaskType `protobuf:"varint,3,opt,name=type_code,json=typeCode,proto3,enum=meta.TaskType" json:"type_code,omitempty"` Category string `protobuf:"bytes,4,opt,name=category,proto3" json:"category,omitempty"` Description string `protobuf:"bytes,5,opt,name=description,proto3" json:"description,omitempty"` Level string `protobuf:"bytes,6,opt,name=level,proto3" json:"level,omitempty"` LevelCode TaskLevel `protobuf:"varint,7,opt,name=level_code,json=levelCode,proto3,enum=meta.TaskLevel" json:"level_code,omitempty"` Flag string `protobuf:"bytes,8,opt,name=flag,proto3" json:"flag,omitempty"` AttachmentUrl string `protobuf:"bytes,9,opt,name=attachment_url,json=attachmentUrl,proto3" json:"attachment_url,omitempty"` Hints []string `protobuf:"bytes,10,rep,name=hints,proto3" json:"hints,omitempty"` // contains filtered or unexported fields }
func (*Task) Descriptor
deprecated
added in
v1.0.9
func (*Task) GetAttachmentUrl ¶ added in v1.0.9
func (*Task) GetCategory ¶ added in v1.0.9
func (*Task) GetDescription ¶ added in v1.0.9
func (*Task) GetLevelCode ¶ added in v1.0.9
func (*Task) GetTypeCode ¶ added in v1.0.9
func (*Task) ParseFormat ¶ added in v1.0.11
func (*Task) ProtoMessage ¶ added in v1.0.9
func (*Task) ProtoMessage()
func (*Task) ProtoReflect ¶ added in v1.0.9
func (x *Task) ProtoReflect() protoreflect.Message
type TaskLevel ¶ added in v1.0.7
type TaskLevel int32
func (TaskLevel) Descriptor ¶ added in v1.0.9
func (TaskLevel) Descriptor() protoreflect.EnumDescriptor
func (TaskLevel) EnumDescriptor
deprecated
added in
v1.0.9
func (TaskLevel) Number ¶ added in v1.0.9
func (x TaskLevel) Number() protoreflect.EnumNumber
func (TaskLevel) Type ¶ added in v1.0.9
func (TaskLevel) Type() protoreflect.EnumType
type TaskType ¶ added in v1.0.7
type TaskType int32
func (TaskType) Descriptor ¶ added in v1.0.9
func (TaskType) Descriptor() protoreflect.EnumDescriptor
func (TaskType) EnumDescriptor
deprecated
added in
v1.0.9
func (TaskType) Number ¶ added in v1.0.9
func (x TaskType) Number() protoreflect.EnumNumber
func (TaskType) Type ¶ added in v1.0.9
func (TaskType) Type() protoreflect.EnumType
Click to show internal directories.
Click to hide internal directories.