Documentation ¶
Index ¶
- type Router
- type UnionRouter
- func (u *UnionRouter) Broadcast(bxhID string) error
- func (u *UnionRouter) QueryIBTP(id string, isReq bool) (*pb.IBTP, error)
- func (u *UnionRouter) QueryInterchain(bxhID, serviceID string) (*pb.Interchain, error)
- func (u *UnionRouter) Route(ibtp *pb.IBTP) error
- func (u *UnionRouter) Start() error
- func (u *UnionRouter) Stop() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Router ¶
type Router interface { // Start starts the router module Start() error // Stop Stop() error //Broadcast broadcasts the registered appchain ids to the union network Broadcast(id string) error //Route sends ibtp to the union pier in target relay chain Route(ibtp *pb.IBTP) error QueryInterchain(bxhID, serviceID string) (*pb.Interchain, error) QueryIBTP(id string, isReq bool) (*pb.IBTP, error) }
type UnionRouter ¶
type UnionRouter struct {
// contains filtered or unexported fields
}
func New ¶
func New(peermgr peermgr.PeerManager, logger logrus.FieldLogger) *UnionRouter
func (*UnionRouter) Broadcast ¶
func (u *UnionRouter) Broadcast(bxhID string) error
Broadcast broadcasts current BitXHub Chain ID to the union network
func (*UnionRouter) QueryInterchain ¶ added in v1.13.0
func (u *UnionRouter) QueryInterchain(bxhID, serviceID string) (*pb.Interchain, error)
func (*UnionRouter) Route ¶
func (u *UnionRouter) Route(ibtp *pb.IBTP) error
Route sends ibtp to the union pier in target relay chain
func (*UnionRouter) Start ¶
func (u *UnionRouter) Start() error
func (*UnionRouter) Stop ¶
func (u *UnionRouter) Stop() error
Directories ¶
Path | Synopsis |
---|---|
Package mock_router is a generated GoMock package.
|
Package mock_router is a generated GoMock package. |
Click to show internal directories.
Click to hide internal directories.