go_micro_srv_task_script

package
v2.3.3 Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2021 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_proto_script_script_proto protoreflect.FileDescriptor

Functions

func NewScriptServiceEndpoints

func NewScriptServiceEndpoints() []*api.Endpoint

func RegisterScriptServiceHandler

func RegisterScriptServiceHandler(s server.Server, hdlr ScriptServiceHandler, opts ...server.HandlerOption) error

Types

type Nop

type Nop struct {
	// contains filtered or unexported fields
}

func (*Nop) Descriptor deprecated

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

Deprecated: Use Nop.ProtoReflect.Descriptor instead.

func (*Nop) ProtoMessage

func (*Nop) ProtoMessage()

func (*Nop) ProtoReflect

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

func (*Nop) Reset

func (x *Nop) Reset()

func (*Nop) String

func (x *Nop) String() string

type Query

type Query struct {
	Limit   uint32        `protobuf:"varint,1,opt,name=limit,proto3" json:"limit,omitempty"`
	Offset  uint32        `protobuf:"varint,2,opt,name=offset,proto3" json:"offset,omitempty"`
	Page    uint32        `protobuf:"varint,3,opt,name=page,proto3" json:"page,omitempty"`
	PerPage uint32        `protobuf:"varint,4,opt,name=perPage,proto3" json:"perPage,omitempty"`
	Filter  *ScriptFilter `protobuf:"bytes,5,opt,name=filter,proto3" json:"filter,omitempty"`
	// contains filtered or unexported fields
}

func (*Query) Descriptor deprecated

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

Deprecated: Use Query.ProtoReflect.Descriptor instead.

func (*Query) GetFilter

func (x *Query) GetFilter() *ScriptFilter

func (*Query) GetLimit

func (x *Query) GetLimit() uint32

func (*Query) GetOffset

func (x *Query) GetOffset() uint32

func (*Query) GetPage

func (x *Query) GetPage() uint32

func (*Query) GetPerPage

func (x *Query) GetPerPage() uint32

func (*Query) ProtoMessage

func (*Query) ProtoMessage()

func (*Query) ProtoReflect

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

func (*Query) Reset

func (x *Query) Reset()

func (*Query) String

func (x *Query) String() string

type Response

type Response struct {
	// contains filtered or unexported fields
}

func (*Response) Descriptor deprecated

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

Deprecated: Use Response.ProtoReflect.Descriptor instead.

func (*Response) ProtoMessage

func (*Response) ProtoMessage()

func (*Response) ProtoReflect

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

func (*Response) Reset

func (x *Response) Reset()

func (*Response) String

func (x *Response) String() string

type Script

type Script struct {
	Id          uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Name        string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"`
	CancelFunc  string `protobuf:"bytes,4,opt,name=cancelFunc,proto3" json:"cancelFunc,omitempty"`
	Content     string `protobuf:"bytes,5,opt,name=content,proto3" json:"content,omitempty"`
	// contains filtered or unexported fields
}

func (*Script) Descriptor deprecated

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

Deprecated: Use Script.ProtoReflect.Descriptor instead.

func (*Script) GetCancelFunc

func (x *Script) GetCancelFunc() string

func (*Script) GetContent

func (x *Script) GetContent() string

func (*Script) GetDescription

func (x *Script) GetDescription() string

func (*Script) GetId

func (x *Script) GetId() uint32

func (*Script) GetName

func (x *Script) GetName() string

func (*Script) ProtoMessage

func (*Script) ProtoMessage()

func (*Script) ProtoReflect

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

func (*Script) Reset

func (x *Script) Reset()

func (*Script) String

func (x *Script) String() string

type ScriptFilter

type ScriptFilter struct {
	And    []*ScriptFilter       `protobuf:"bytes,1,rep,name=and,proto3" json:"and,omitempty"`
	Or     []*ScriptFilter       `protobuf:"bytes,2,rep,name=or,proto3" json:"or,omitempty"`
	Id     *wrappers.Int32Value  `protobuf:"bytes,3,opt,name=id,proto3" json:"id,omitempty"`
	IdIn   []int32               `protobuf:"varint,4,rep,packed,name=idIn,proto3" json:"idIn,omitempty"`
	Name   *wrappers.StringValue `protobuf:"bytes,5,opt,name=name,proto3" json:"name,omitempty"`
	NameIn []string              `protobuf:"bytes,6,rep,name=nameIn,proto3" json:"nameIn,omitempty"`
	// contains filtered or unexported fields
}

func (*ScriptFilter) Descriptor deprecated

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

Deprecated: Use ScriptFilter.ProtoReflect.Descriptor instead.

func (*ScriptFilter) GetAnd

func (x *ScriptFilter) GetAnd() []*ScriptFilter

func (*ScriptFilter) GetId

func (x *ScriptFilter) GetId() *wrappers.Int32Value

func (*ScriptFilter) GetIdIn

func (x *ScriptFilter) GetIdIn() []int32

func (*ScriptFilter) GetName

func (x *ScriptFilter) GetName() *wrappers.StringValue

func (*ScriptFilter) GetNameIn

func (x *ScriptFilter) GetNameIn() []string

func (*ScriptFilter) GetOr

func (x *ScriptFilter) GetOr() []*ScriptFilter

func (*ScriptFilter) ProtoMessage

func (*ScriptFilter) ProtoMessage()

func (*ScriptFilter) ProtoReflect

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

func (*ScriptFilter) Reset

func (x *ScriptFilter) Reset()

func (*ScriptFilter) String

func (x *ScriptFilter) String() string

type ScriptIndex

type ScriptIndex struct {
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*ScriptIndex) Descriptor deprecated

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

Deprecated: Use ScriptIndex.ProtoReflect.Descriptor instead.

func (*ScriptIndex) GetId

func (x *ScriptIndex) GetId() uint32

func (*ScriptIndex) ProtoMessage

func (*ScriptIndex) ProtoMessage()

func (*ScriptIndex) ProtoReflect

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

func (*ScriptIndex) Reset

func (x *ScriptIndex) Reset()

func (*ScriptIndex) String

func (x *ScriptIndex) String() string

type ScriptService

type ScriptService interface {
	AddScript(ctx context.Context, in *Script, opts ...client.CallOption) (*Response, error)
	DeleteScript(ctx context.Context, in *ScriptIndex, opts ...client.CallOption) (*Response, error)
	UpdateScript(ctx context.Context, in *UpdateScriptReq, opts ...client.CallOption) (*Response, error)
	GetScript(ctx context.Context, in *ScriptIndex, opts ...client.CallOption) (*Script, error)
	GetScripts(ctx context.Context, in *Query, opts ...client.CallOption) (*Scripts, error)
	// 获取下一个可用的脚本ID
	GetNextScriptID(ctx context.Context, in *Nop, opts ...client.CallOption) (*ScriptIndex, error)
}

func NewScriptService

func NewScriptService(name string, c client.Client) ScriptService

type ScriptServiceHandler

type ScriptServiceHandler interface {
	AddScript(context.Context, *Script, *Response) error
	DeleteScript(context.Context, *ScriptIndex, *Response) error
	UpdateScript(context.Context, *UpdateScriptReq, *Response) error
	GetScript(context.Context, *ScriptIndex, *Script) error
	GetScripts(context.Context, *Query, *Scripts) error
	// 获取下一个可用的脚本ID
	GetNextScriptID(context.Context, *Nop, *ScriptIndex) error
}

type Scripts

type Scripts struct {
	Scripts    []*Script `protobuf:"bytes,1,rep,name=scripts,proto3" json:"scripts,omitempty"`
	Totalpages uint32    `protobuf:"varint,2,opt,name=totalpages,proto3" json:"totalpages,omitempty"`
	Currpages  uint32    `protobuf:"varint,3,opt,name=currpages,proto3" json:"currpages,omitempty"`
	Totals     uint32    `protobuf:"varint,4,opt,name=totals,proto3" json:"totals,omitempty"`
	// contains filtered or unexported fields
}

func (*Scripts) Descriptor deprecated

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

Deprecated: Use Scripts.ProtoReflect.Descriptor instead.

func (*Scripts) GetCurrpages

func (x *Scripts) GetCurrpages() uint32

func (*Scripts) GetScripts

func (x *Scripts) GetScripts() []*Script

func (*Scripts) GetTotalpages

func (x *Scripts) GetTotalpages() uint32

func (*Scripts) GetTotals

func (x *Scripts) GetTotals() uint32

func (*Scripts) ProtoMessage

func (*Scripts) ProtoMessage()

func (*Scripts) ProtoReflect

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

func (*Scripts) Reset

func (x *Scripts) Reset()

func (*Scripts) String

func (x *Scripts) String() string

type UpdateScript

type UpdateScript struct {
	Id          *wrappers.Int32Value  `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Name        *wrappers.StringValue `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Description *wrappers.StringValue `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"`
	CancelFunc  *wrappers.StringValue `protobuf:"bytes,4,opt,name=cancelFunc,proto3" json:"cancelFunc,omitempty"`
	Content     *wrappers.StringValue `protobuf:"bytes,5,opt,name=content,proto3" json:"content,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateScript) Descriptor deprecated

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

Deprecated: Use UpdateScript.ProtoReflect.Descriptor instead.

func (*UpdateScript) GetCancelFunc

func (x *UpdateScript) GetCancelFunc() *wrappers.StringValue

func (*UpdateScript) GetContent

func (x *UpdateScript) GetContent() *wrappers.StringValue

func (*UpdateScript) GetDescription

func (x *UpdateScript) GetDescription() *wrappers.StringValue

func (*UpdateScript) GetId

func (x *UpdateScript) GetId() *wrappers.Int32Value

func (*UpdateScript) GetName

func (x *UpdateScript) GetName() *wrappers.StringValue

func (*UpdateScript) ProtoMessage

func (*UpdateScript) ProtoMessage()

func (*UpdateScript) ProtoReflect

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

func (*UpdateScript) Reset

func (x *UpdateScript) Reset()

func (*UpdateScript) String

func (x *UpdateScript) String() string

type UpdateScriptReq

type UpdateScriptReq struct {
	Id     uint32        `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Update *UpdateScript `protobuf:"bytes,2,opt,name=update,proto3" json:"update,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateScriptReq) Descriptor deprecated

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

Deprecated: Use UpdateScriptReq.ProtoReflect.Descriptor instead.

func (*UpdateScriptReq) GetId

func (x *UpdateScriptReq) GetId() uint32

func (*UpdateScriptReq) GetUpdate

func (x *UpdateScriptReq) GetUpdate() *UpdateScript

func (*UpdateScriptReq) ProtoMessage

func (*UpdateScriptReq) ProtoMessage()

func (*UpdateScriptReq) ProtoReflect

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

func (*UpdateScriptReq) Reset

func (x *UpdateScriptReq) Reset()

func (*UpdateScriptReq) String

func (x *UpdateScriptReq) String() string

Jump to

Keyboard shortcuts

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