Documentation ¶
Overview ¶
Generated by the go idl tools. DO NOT EDIT 2023-01-11 04:41:10 source: TestCaller
Generated by the go idl tools. DO NOT EDIT 2022-03-17 11:27:42 source: box_example
Index ¶
- Constants
- func TestCallerProxyCreator(trans transport.ITransport) idlrpc.IProxy
- func TestCallerStubCreator(v interface{}) idlrpc.IStub
- type DemoServiceContext
- func (c *DemoServiceContext) Clone() idlrpc.IServiceContext
- func (c *DemoServiceContext) Error(format string, i ...interface{})
- func (c *DemoServiceContext) GetIdentityID() string
- func (c *DemoServiceContext) GetIdentityTag() string
- func (c *DemoServiceContext) GetProxy(uuid uint64) idlrpc.IProxy
- func (c *DemoServiceContext) GetProxyFromPeer(uuid uint64) idlrpc.IProxy
- func (c *DemoServiceContext) GetProxyWithNickname(uint64, string) idlrpc.IProxy
- func (c *DemoServiceContext) GetTransport() transport.ITransport
- func (c *DemoServiceContext) Info(format string, i ...interface{})
- func (c *DemoServiceContext) PushLogHeader(s string)
- func (c *DemoServiceContext) Warning(format string, i ...interface{})
- type ITestCaller
- type TestCallerImpl
- func (sp *TestCallerImpl) GetInfo(ctx idlrpc.IServiceContext) (ret1 string, err error)
- func (sp *TestCallerImpl) GetNickName() string
- func (sp *TestCallerImpl) GetUUID() uint64
- func (sp *TestCallerImpl) OnAfterFork(ctx idlrpc.IServiceContext) bool
- func (sp *TestCallerImpl) OnBeforeDestroy() bool
- func (sp *TestCallerImpl) OnCancel(subID string, event string) error
- func (sp *TestCallerImpl) OnSubscribe(subID string, event string, bytes []byte) error
- func (sp *TestCallerImpl) OnTick() bool
- func (sp *TestCallerImpl) SetInfo(ctx idlrpc.IServiceContext, _1 string) (err error)
- type TestCallerProxy
- func (sp *TestCallerProxy) GetInfo() (ret1 string, err error)
- func (sp *TestCallerProxy) GetSignature(methid uint32) string
- func (sp *TestCallerProxy) GetSrvName() string
- func (sp *TestCallerProxy) GetUUID() uint64
- func (sp *TestCallerProxy) IsOneWay(methodid uint32) (isoneway bool)
- func (sp *TestCallerProxy) SetInfo(_1 string) (err error)
- type TestCallerStub
- func (sb *TestCallerStub) Call(ctx idlrpc.IServiceContext, methodId uint32, req []byte) (resp []byte, err error)
- func (sb *TestCallerStub) GetInfo(ctx idlrpc.IServiceContext, req []byte) (resp []byte, err error)
- func (sb *TestCallerStub) GetMultipleNum() uint32
- func (sb *TestCallerStub) GetServiceName() string
- func (sb *TestCallerStub) GetSignature(methodid uint32) string
- func (sb *TestCallerStub) GetStatus() idlrpc.ServiceStatus
- func (sb *TestCallerStub) GetUUID() idlrpc.SvcUuid
- func (sb *TestCallerStub) IsOneWay(methodid uint32) (isoneway bool)
- func (sb *TestCallerStub) OnAfterFork(ctx idlrpc.IServiceContext) bool
- func (sb *TestCallerStub) OnBeforeDestroy() bool
- func (sb *TestCallerStub) OnCancel(subID string, event string) error
- func (sb *TestCallerStub) OnSub(subID string, event string, data []byte) error
- func (sb *TestCallerStub) OnTick() bool
- func (sb *TestCallerStub) SetInfo(ctx idlrpc.IServiceContext, req []byte) (resp []byte, err error)
- func (sb *TestCallerStub) SetStatus(status idlrpc.ServiceStatus)
- type TestMsgHandler
- type TransportRing
- func (trans *TransportRing) Close()
- func (trans *TransportRing) GetID() uint32
- func (trans *TransportRing) GlobalIndex() protocol.GlobalIndexType
- func (trans *TransportRing) Heartbeat() error
- func (trans *TransportRing) IdentityID() string
- func (trans *TransportRing) IdentityTag() string
- func (trans *TransportRing) IsClose() bool
- func (trans *TransportRing) LocalAddr() string
- func (trans *TransportRing) Peek(length int) ([]byte, int, error)
- func (trans *TransportRing) PopSend() []byte
- func (trans *TransportRing) Read(pkg []byte, length int) (int, error)
- func (trans *TransportRing) RemoteAddr() string
- func (trans *TransportRing) Send(pkg []byte) error
- func (trans *TransportRing) SetID(id uint32)
- func (trans *TransportRing) SetIdentityID(s string)
- func (trans *TransportRing) SetIdentityTag(s string)
- func (trans *TransportRing) Size() uint32
- func (trans *TransportRing) Write(pkg []byte, length int) (int, error)
Constants ¶
View Source
const ( SrvUUID = 6784101236246863201 SrvName = "TestCaller" )
Variables ¶
This section is empty.
Functions ¶
func TestCallerProxyCreator ¶
func TestCallerProxyCreator(trans transport.ITransport) idlrpc.IProxy
func TestCallerStubCreator ¶
Types ¶
type DemoServiceContext ¶ added in v0.5.4
type DemoServiceContext struct { *idlrpc.RpcContext // contains filtered or unexported fields }
func NewDemoServiceContext ¶ added in v0.5.4
func NewDemoServiceContext() *DemoServiceContext
func (*DemoServiceContext) Clone ¶ added in v0.5.5
func (c *DemoServiceContext) Clone() idlrpc.IServiceContext
func (*DemoServiceContext) Error ¶ added in v0.5.4
func (c *DemoServiceContext) Error(format string, i ...interface{})
func (*DemoServiceContext) GetIdentityID ¶ added in v0.5.4
func (c *DemoServiceContext) GetIdentityID() string
func (*DemoServiceContext) GetIdentityTag ¶ added in v0.5.4
func (c *DemoServiceContext) GetIdentityTag() string
func (*DemoServiceContext) GetProxy ¶ added in v0.5.4
func (c *DemoServiceContext) GetProxy(uuid uint64) idlrpc.IProxy
func (*DemoServiceContext) GetProxyFromPeer ¶ added in v0.5.4
func (c *DemoServiceContext) GetProxyFromPeer(uuid uint64) idlrpc.IProxy
func (*DemoServiceContext) GetProxyWithNickname ¶ added in v0.5.4
func (c *DemoServiceContext) GetProxyWithNickname(uint64, string) idlrpc.IProxy
func (*DemoServiceContext) GetTransport ¶ added in v0.5.4
func (c *DemoServiceContext) GetTransport() transport.ITransport
func (*DemoServiceContext) Info ¶ added in v0.5.4
func (c *DemoServiceContext) Info(format string, i ...interface{})
func (*DemoServiceContext) PushLogHeader ¶ added in v0.5.4
func (c *DemoServiceContext) PushLogHeader(s string)
func (*DemoServiceContext) Warning ¶ added in v0.5.4
func (c *DemoServiceContext) Warning(format string, i ...interface{})
type ITestCaller ¶
type ITestCaller interface { idlrpc.IService SetInfo(idlrpc.IServiceContext, string) error GetInfo(idlrpc.IServiceContext) (string, error) }
type TestCallerImpl ¶
type TestCallerImpl struct {
// contains filtered or unexported fields
}
func NewTestCaller ¶
func NewTestCaller() *TestCallerImpl
func (*TestCallerImpl) GetInfo ¶
func (sp *TestCallerImpl) GetInfo(ctx idlrpc.IServiceContext) (ret1 string, err error)
func (*TestCallerImpl) GetNickName ¶
func (sp *TestCallerImpl) GetNickName() string
func (*TestCallerImpl) GetUUID ¶
func (sp *TestCallerImpl) GetUUID() uint64
func (*TestCallerImpl) OnAfterFork ¶
func (sp *TestCallerImpl) OnAfterFork(ctx idlrpc.IServiceContext) bool
func (*TestCallerImpl) OnBeforeDestroy ¶
func (sp *TestCallerImpl) OnBeforeDestroy() bool
func (*TestCallerImpl) OnCancel ¶ added in v0.5.0
func (sp *TestCallerImpl) OnCancel(subID string, event string) error
func (*TestCallerImpl) OnSubscribe ¶ added in v0.5.0
func (sp *TestCallerImpl) OnSubscribe(subID string, event string, bytes []byte) error
func (*TestCallerImpl) OnTick ¶
func (sp *TestCallerImpl) OnTick() bool
func (*TestCallerImpl) SetInfo ¶
func (sp *TestCallerImpl) SetInfo(ctx idlrpc.IServiceContext, _1 string) (err error)
type TestCallerProxy ¶
TestCallerProxy define stub.ProxyStub
func (*TestCallerProxy) GetInfo ¶
func (sp *TestCallerProxy) GetInfo() (ret1 string, err error)
func (*TestCallerProxy) GetSignature ¶
func (sp *TestCallerProxy) GetSignature(methid uint32) string
func (*TestCallerProxy) GetSrvName ¶
func (sp *TestCallerProxy) GetSrvName() string
func (*TestCallerProxy) GetUUID ¶
func (sp *TestCallerProxy) GetUUID() uint64
GetUUID define function
func (*TestCallerProxy) IsOneWay ¶
func (sp *TestCallerProxy) IsOneWay(methodid uint32) (isoneway bool)
func (*TestCallerProxy) SetInfo ¶
func (sp *TestCallerProxy) SetInfo(_1 string) (err error)
type TestCallerStub ¶
type TestCallerStub struct {
// contains filtered or unexported fields
}
func NewTestCallerStub ¶
func NewTestCallerStub(srvImpl ITestCaller) *TestCallerStub
func (*TestCallerStub) Call ¶
func (sb *TestCallerStub) Call(ctx idlrpc.IServiceContext, methodId uint32, req []byte) (resp []byte, err error)
func (*TestCallerStub) GetInfo ¶
func (sb *TestCallerStub) GetInfo(ctx idlrpc.IServiceContext, req []byte) (resp []byte, err error)
func (*TestCallerStub) GetMultipleNum ¶ added in v0.5.2
func (sb *TestCallerStub) GetMultipleNum() uint32
func (*TestCallerStub) GetServiceName ¶
func (sb *TestCallerStub) GetServiceName() string
func (*TestCallerStub) GetSignature ¶
func (sb *TestCallerStub) GetSignature(methodid uint32) string
func (*TestCallerStub) GetStatus ¶
func (sb *TestCallerStub) GetStatus() idlrpc.ServiceStatus
func (*TestCallerStub) GetUUID ¶
func (sb *TestCallerStub) GetUUID() idlrpc.SvcUuid
func (*TestCallerStub) IsOneWay ¶
func (sb *TestCallerStub) IsOneWay(methodid uint32) (isoneway bool)
func (*TestCallerStub) OnAfterFork ¶
func (sb *TestCallerStub) OnAfterFork(ctx idlrpc.IServiceContext) bool
func (*TestCallerStub) OnBeforeDestroy ¶
func (sb *TestCallerStub) OnBeforeDestroy() bool
func (*TestCallerStub) OnCancel ¶ added in v0.5.0
func (sb *TestCallerStub) OnCancel(subID string, event string) error
func (*TestCallerStub) OnSub ¶ added in v0.5.0
func (sb *TestCallerStub) OnSub(subID string, event string, data []byte) error
func (*TestCallerStub) OnTick ¶
func (sb *TestCallerStub) OnTick() bool
func (*TestCallerStub) SetInfo ¶
func (sb *TestCallerStub) SetInfo(ctx idlrpc.IServiceContext, req []byte) (resp []byte, err error)
func (*TestCallerStub) SetStatus ¶
func (sb *TestCallerStub) SetStatus(status idlrpc.ServiceStatus)
type TestMsgHandler ¶ added in v0.5.6
type TestMsgHandler struct {
RawMsgChan chan *testNoRpcMessage
}
func NewTestMsgHandler ¶ added in v0.5.6
func NewTestMsgHandler() *TestMsgHandler
func (*TestMsgHandler) OnIdentityNotify ¶ added in v0.5.6
func (h *TestMsgHandler) OnIdentityNotify(transport transport.ITransport, identityID string, identityTag string)
func (*TestMsgHandler) OnLoggedOut ¶ added in v0.5.6
func (h *TestMsgHandler) OnLoggedOut(index protocol.GlobalIndexType)
func (*TestMsgHandler) OnRawMessage ¶ added in v0.5.6
func (h *TestMsgHandler) OnRawMessage(transport transport.ITransport, msg []byte)
type TransportRing ¶
type TransportRing struct {
// contains filtered or unexported fields
}
TransportRing 双队列,一读一写
func NewTransportRing ¶
func NewTransportRing() *TransportRing
func (*TransportRing) Close ¶
func (trans *TransportRing) Close()
func (*TransportRing) GetID ¶
func (trans *TransportRing) GetID() uint32
func (*TransportRing) GlobalIndex ¶
func (trans *TransportRing) GlobalIndex() protocol.GlobalIndexType
func (*TransportRing) Heartbeat ¶ added in v0.4.16
func (trans *TransportRing) Heartbeat() error
func (*TransportRing) IdentityID ¶ added in v0.5.3
func (trans *TransportRing) IdentityID() string
func (*TransportRing) IdentityTag ¶ added in v0.5.3
func (trans *TransportRing) IdentityTag() string
func (*TransportRing) IsClose ¶
func (trans *TransportRing) IsClose() bool
func (*TransportRing) LocalAddr ¶
func (trans *TransportRing) LocalAddr() string
func (*TransportRing) PopSend ¶
func (trans *TransportRing) PopSend() []byte
func (*TransportRing) RemoteAddr ¶
func (trans *TransportRing) RemoteAddr() string
func (*TransportRing) Send ¶
func (trans *TransportRing) Send(pkg []byte) error
func (*TransportRing) SetID ¶
func (trans *TransportRing) SetID(id uint32)
func (*TransportRing) SetIdentityID ¶ added in v0.5.3
func (trans *TransportRing) SetIdentityID(s string)
func (*TransportRing) SetIdentityTag ¶ added in v0.5.3
func (trans *TransportRing) SetIdentityTag(s string)
func (*TransportRing) Size ¶
func (trans *TransportRing) Size() uint32
Source Files ¶
Click to show internal directories.
Click to hide internal directories.