package
1.1.7
Repository: https://github.com/matrixainetwork/go-matrix.git
Documentation: pkg.go.dev

# Packages

No description provided by the author

# Functions

ConnLabel generates a deterministic string which represents a connection between two nodes, used to compare if two connections are between the same nodes.
ControlEvent creates a new control event.
Get a list of mockers (keys of the map)Useful for frontend to build available mocker selection.
Lookup a mocker by its name, returns the mockerFn.
NewClient returns a new simulation API client.
NewEvent creates a new event for the given object which should be either a Node, Conn or Msg.
NewMsgFilters constructs a collection of message filters from a URL query parameter.
NewNetwork returns a Network which uses the given NodeAdapter and NetworkConfig.
NewServer returns a new simulation API server.
NewSimulation returns a new simulation which runs in the given network.

# Constants

EventTypeConn is the type of event emitted when a connection is is either established or dropped between two nodes.
EventTypeMsg is the type of event emitted when a p2p message it sent between two nodes.
EventTypeNode is the type of event emitted when a node is either created, started or stopped.

# Variables

DefaultClient is the default simulation API client which expects the API to be running at http://localhost:8888.

# Structs

Client is a client for the simulation HTTP API which supports creating and managing simulation networks.
Conn represents a connection between two nodes in the network.
Event is an event emitted by a simulation network.
No description provided by the author
Msg represents a p2p message sent between two nodes in the network.
MsgFilter is used to filter message events based on protocol and message code.
Network models a p2p simulation network which consists of a collection of simulated nodes and the connections which exist between them.
NetworkConfig defines configuration options for starting a Network.
Node is a wrapper around adapters.Node which is used to track the status of a node in the network.
NodeSnapshot represents the state of a node in the network.
Server is an HTTP server providing an API to manage a simulation network.
Simulation provides a framework for running actions in a simulated network and then waiting for expectations to be met.
Snapshot represents the state of a network at a single point in time and can be used to restore the state of a network.
No description provided by the author
No description provided by the author
SubscribeOpts is a collection of options to use when subscribing to network events.

# Type aliases

EventType is the type of event emitted by a simulation network.
MsgFilters is a collection of filters which are used to filter message events.