sum

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2019 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Overview

Package sum is a generated protocol buffer package.

It is generated from these files:

proto/sum.proto

It has these top-level messages:

Record
RecordResponse
ListRequest
RecordListResponse
FindResponse
Oracle
OracleResponse
Call
Data
CallResponse
ById
ByName
ByMeta
ServerInfo
Empty

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterSumServiceServer

func RegisterSumServiceServer(s *grpc.Server, srv SumServiceServer)

Types

type ById

type ById struct {
	Id uint64 `protobuf:"varint,1,opt,name=id" json:"id,omitempty"`
}

func (*ById) Descriptor

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

func (*ById) GetId

func (m *ById) GetId() uint64

func (*ById) ProtoMessage

func (*ById) ProtoMessage()

func (*ById) Reset

func (m *ById) Reset()

func (*ById) String

func (m *ById) String() string

type ByMeta

type ByMeta struct {
	Meta  string `protobuf:"bytes,1,opt,name=meta" json:"meta,omitempty"`
	Value string `protobuf:"bytes,2,opt,name=value" json:"value,omitempty"`
}

func (*ByMeta) Descriptor

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

func (*ByMeta) GetMeta

func (m *ByMeta) GetMeta() string

func (*ByMeta) GetValue

func (m *ByMeta) GetValue() string

func (*ByMeta) ProtoMessage

func (*ByMeta) ProtoMessage()

func (*ByMeta) Reset

func (m *ByMeta) Reset()

func (*ByMeta) String

func (m *ByMeta) String() string

type ByName

type ByName struct {
	Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
}

func (*ByName) Descriptor

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

func (*ByName) GetName

func (m *ByName) GetName() string

func (*ByName) ProtoMessage

func (*ByName) ProtoMessage()

func (*ByName) Reset

func (m *ByName) Reset()

func (*ByName) String

func (m *ByName) String() string

type Call

type Call struct {
	OracleId uint64   `protobuf:"varint,1,opt,name=oracle_id,json=oracleId" json:"oracle_id,omitempty"`
	Args     []string `protobuf:"bytes,2,rep,name=args" json:"args,omitempty"`
}

func (*Call) Descriptor

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

func (*Call) GetArgs

func (m *Call) GetArgs() []string

func (*Call) GetOracleId

func (m *Call) GetOracleId() uint64

func (*Call) ProtoMessage

func (*Call) ProtoMessage()

func (*Call) Reset

func (m *Call) Reset()

func (*Call) String

func (m *Call) String() string

type CallResponse

type CallResponse struct {
	Success bool   `protobuf:"varint,1,opt,name=success" json:"success,omitempty"`
	Msg     string `protobuf:"bytes,2,opt,name=msg" json:"msg,omitempty"`
	Data    *Data  `protobuf:"bytes,3,opt,name=data" json:"data,omitempty"`
}

func (*CallResponse) Descriptor

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

func (*CallResponse) GetData

func (m *CallResponse) GetData() *Data

func (*CallResponse) GetMsg

func (m *CallResponse) GetMsg() string

func (*CallResponse) GetSuccess

func (m *CallResponse) GetSuccess() bool

func (*CallResponse) ProtoMessage

func (*CallResponse) ProtoMessage()

func (*CallResponse) Reset

func (m *CallResponse) Reset()

func (*CallResponse) String

func (m *CallResponse) String() string

type Data

type Data struct {
	Compressed bool   `protobuf:"varint,1,opt,name=compressed" json:"compressed,omitempty"`
	Payload    []byte `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"`
}

func (*Data) Descriptor

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

func (*Data) GetCompressed

func (m *Data) GetCompressed() bool

func (*Data) GetPayload

func (m *Data) GetPayload() []byte

func (*Data) ProtoMessage

func (*Data) ProtoMessage()

func (*Data) Reset

func (m *Data) Reset()

func (*Data) String

func (m *Data) String() string

type Empty

type Empty struct {
}

func (*Empty) Descriptor

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

func (*Empty) ProtoMessage

func (*Empty) ProtoMessage()

func (*Empty) Reset

func (m *Empty) Reset()

func (*Empty) String

func (m *Empty) String() string

type FindResponse

type FindResponse struct {
	Success bool      `protobuf:"varint,1,opt,name=success" json:"success,omitempty"`
	Msg     string    `protobuf:"bytes,2,opt,name=msg" json:"msg,omitempty"`
	Records []*Record `protobuf:"bytes,3,rep,name=records" json:"records,omitempty"`
}

func (*FindResponse) Descriptor

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

func (*FindResponse) GetMsg

func (m *FindResponse) GetMsg() string

func (*FindResponse) GetRecords

func (m *FindResponse) GetRecords() []*Record

func (*FindResponse) GetSuccess

func (m *FindResponse) GetSuccess() bool

func (*FindResponse) ProtoMessage

func (*FindResponse) ProtoMessage()

func (*FindResponse) Reset

func (m *FindResponse) Reset()

func (*FindResponse) String

func (m *FindResponse) String() string

type ListRequest

type ListRequest struct {
	Page    uint64 `protobuf:"varint,1,opt,name=page" json:"page,omitempty"`
	PerPage uint64 `protobuf:"varint,2,opt,name=per_page,json=perPage" json:"per_page,omitempty"`
}

func (*ListRequest) Descriptor

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

func (*ListRequest) GetPage

func (m *ListRequest) GetPage() uint64

func (*ListRequest) GetPerPage

func (m *ListRequest) GetPerPage() uint64

func (*ListRequest) ProtoMessage

func (*ListRequest) ProtoMessage()

func (*ListRequest) Reset

func (m *ListRequest) Reset()

func (*ListRequest) String

func (m *ListRequest) String() string

type Oracle

type Oracle struct {
	Id   uint64 `protobuf:"varint,1,opt,name=id" json:"id,omitempty"`
	Name string `protobuf:"bytes,2,opt,name=name" json:"name,omitempty"`
	Code string `protobuf:"bytes,3,opt,name=code" json:"code,omitempty"`
}

func (*Oracle) Descriptor

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

func (*Oracle) GetCode

func (m *Oracle) GetCode() string

func (*Oracle) GetId

func (m *Oracle) GetId() uint64

func (*Oracle) GetName

func (m *Oracle) GetName() string

func (*Oracle) ProtoMessage

func (*Oracle) ProtoMessage()

func (*Oracle) Reset

func (m *Oracle) Reset()

func (*Oracle) String

func (m *Oracle) String() string

type OracleResponse

type OracleResponse struct {
	Success bool      `protobuf:"varint,1,opt,name=success" json:"success,omitempty"`
	Msg     string    `protobuf:"bytes,2,opt,name=msg" json:"msg,omitempty"`
	Oracles []*Oracle `protobuf:"bytes,3,rep,name=oracles" json:"oracles,omitempty"`
}

func (*OracleResponse) Descriptor

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

func (*OracleResponse) GetMsg

func (m *OracleResponse) GetMsg() string

func (*OracleResponse) GetOracles

func (m *OracleResponse) GetOracles() []*Oracle

func (*OracleResponse) GetSuccess

func (m *OracleResponse) GetSuccess() bool

func (*OracleResponse) ProtoMessage

func (*OracleResponse) ProtoMessage()

func (*OracleResponse) Reset

func (m *OracleResponse) Reset()

func (*OracleResponse) String

func (m *OracleResponse) String() string

type Record

type Record struct {
	Id   uint64            `protobuf:"varint,1,opt,name=id" json:"id,omitempty"`
	Data []float64         `protobuf:"fixed64,2,rep,packed,name=data" json:"data,omitempty"`
	Meta map[string]string `` /* 128-byte string literal not displayed */
}

func (*Record) Descriptor

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

func (*Record) GetData

func (m *Record) GetData() []float64

func (*Record) GetId

func (m *Record) GetId() uint64

func (*Record) GetMeta

func (m *Record) GetMeta() map[string]string

func (*Record) ProtoMessage

func (*Record) ProtoMessage()

func (*Record) Reset

func (m *Record) Reset()

func (*Record) String

func (m *Record) String() string

type RecordListResponse

type RecordListResponse struct {
	Total   uint64    `protobuf:"varint,1,opt,name=total" json:"total,omitempty"`
	Pages   uint64    `protobuf:"varint,2,opt,name=pages" json:"pages,omitempty"`
	Records []*Record `protobuf:"bytes,3,rep,name=records" json:"records,omitempty"`
}

func (*RecordListResponse) Descriptor

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

func (*RecordListResponse) GetPages

func (m *RecordListResponse) GetPages() uint64

func (*RecordListResponse) GetRecords

func (m *RecordListResponse) GetRecords() []*Record

func (*RecordListResponse) GetTotal

func (m *RecordListResponse) GetTotal() uint64

func (*RecordListResponse) ProtoMessage

func (*RecordListResponse) ProtoMessage()

func (*RecordListResponse) Reset

func (m *RecordListResponse) Reset()

func (*RecordListResponse) String

func (m *RecordListResponse) String() string

type RecordResponse

type RecordResponse struct {
	Success bool    `protobuf:"varint,1,opt,name=success" json:"success,omitempty"`
	Msg     string  `protobuf:"bytes,2,opt,name=msg" json:"msg,omitempty"`
	Record  *Record `protobuf:"bytes,3,opt,name=record" json:"record,omitempty"`
}

func (*RecordResponse) Descriptor

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

func (*RecordResponse) GetMsg

func (m *RecordResponse) GetMsg() string

func (*RecordResponse) GetRecord

func (m *RecordResponse) GetRecord() *Record

func (*RecordResponse) GetSuccess

func (m *RecordResponse) GetSuccess() bool

func (*RecordResponse) ProtoMessage

func (*RecordResponse) ProtoMessage()

func (*RecordResponse) Reset

func (m *RecordResponse) Reset()

func (*RecordResponse) String

func (m *RecordResponse) String() string

type ServerInfo

type ServerInfo struct {
	Version string   `protobuf:"bytes,1,opt,name=version" json:"version,omitempty"`
	Uptime  uint64   `protobuf:"varint,2,opt,name=uptime" json:"uptime,omitempty"`
	Pid     uint64   `protobuf:"varint,3,opt,name=pid" json:"pid,omitempty"`
	Uid     uint64   `protobuf:"varint,4,opt,name=uid" json:"uid,omitempty"`
	Argv    []string `protobuf:"bytes,5,rep,name=argv" json:"argv,omitempty"`
	Records uint64   `protobuf:"varint,6,opt,name=records" json:"records,omitempty"`
	Oracles uint64   `protobuf:"varint,7,opt,name=oracles" json:"oracles,omitempty"`
}

func (*ServerInfo) Descriptor

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

func (*ServerInfo) GetArgv

func (m *ServerInfo) GetArgv() []string

func (*ServerInfo) GetOracles

func (m *ServerInfo) GetOracles() uint64

func (*ServerInfo) GetPid

func (m *ServerInfo) GetPid() uint64

func (*ServerInfo) GetRecords

func (m *ServerInfo) GetRecords() uint64

func (*ServerInfo) GetUid

func (m *ServerInfo) GetUid() uint64

func (*ServerInfo) GetUptime

func (m *ServerInfo) GetUptime() uint64

func (*ServerInfo) GetVersion

func (m *ServerInfo) GetVersion() string

func (*ServerInfo) ProtoMessage

func (*ServerInfo) ProtoMessage()

func (*ServerInfo) Reset

func (m *ServerInfo) Reset()

func (*ServerInfo) String

func (m *ServerInfo) String() string

type SumServiceClient

type SumServiceClient interface {
	// vectors CRUD
	CreateRecord(ctx context.Context, in *Record, opts ...grpc.CallOption) (*RecordResponse, error)
	UpdateRecord(ctx context.Context, in *Record, opts ...grpc.CallOption) (*RecordResponse, error)
	ReadRecord(ctx context.Context, in *ById, opts ...grpc.CallOption) (*RecordResponse, error)
	ListRecords(ctx context.Context, in *ListRequest, opts ...grpc.CallOption) (*RecordListResponse, error)
	DeleteRecord(ctx context.Context, in *ById, opts ...grpc.CallOption) (*RecordResponse, error)
	// find a vector given a meta name and value to filter for
	FindRecords(ctx context.Context, in *ByMeta, opts ...grpc.CallOption) (*FindResponse, error)
	// oracles CRUD
	CreateOracle(ctx context.Context, in *Oracle, opts ...grpc.CallOption) (*OracleResponse, error)
	UpdateOracle(ctx context.Context, in *Oracle, opts ...grpc.CallOption) (*OracleResponse, error)
	ReadOracle(ctx context.Context, in *ById, opts ...grpc.CallOption) (*OracleResponse, error)
	FindOracle(ctx context.Context, in *ByName, opts ...grpc.CallOption) (*OracleResponse, error)
	DeleteOracle(ctx context.Context, in *ById, opts ...grpc.CallOption) (*OracleResponse, error)
	// execute a call to a oracle given its id
	Run(ctx context.Context, in *Call, opts ...grpc.CallOption) (*CallResponse, error)
	// get info about the service
	Info(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*ServerInfo, error)
}

func NewSumServiceClient

func NewSumServiceClient(cc *grpc.ClientConn) SumServiceClient

type SumServiceServer

type SumServiceServer interface {
	// vectors CRUD
	CreateRecord(context.Context, *Record) (*RecordResponse, error)
	UpdateRecord(context.Context, *Record) (*RecordResponse, error)
	ReadRecord(context.Context, *ById) (*RecordResponse, error)
	ListRecords(context.Context, *ListRequest) (*RecordListResponse, error)
	DeleteRecord(context.Context, *ById) (*RecordResponse, error)
	// find a vector given a meta name and value to filter for
	FindRecords(context.Context, *ByMeta) (*FindResponse, error)
	// oracles CRUD
	CreateOracle(context.Context, *Oracle) (*OracleResponse, error)
	UpdateOracle(context.Context, *Oracle) (*OracleResponse, error)
	ReadOracle(context.Context, *ById) (*OracleResponse, error)
	FindOracle(context.Context, *ByName) (*OracleResponse, error)
	DeleteOracle(context.Context, *ById) (*OracleResponse, error)
	// execute a call to a oracle given its id
	Run(context.Context, *Call) (*CallResponse, error)
	// get info about the service
	Info(context.Context, *Empty) (*ServerInfo, error)
}

Jump to

Keyboard shortcuts

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