mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-30 00:00:11 +01:00
42 lines
503 B
Go
42 lines
503 B
Go
package node
|
|
|
|
type NodeCtor func() Node
|
|
|
|
type Node interface {
|
|
Close() error
|
|
|
|
Prepare() error
|
|
|
|
Parse(cfg []byte) error
|
|
|
|
Check() error
|
|
|
|
Start() error
|
|
Stop() error
|
|
|
|
Pause() error
|
|
Resume() error
|
|
Restart() error
|
|
|
|
Read() ([]byte, error)
|
|
Write(data []byte) error
|
|
|
|
Reverse() error
|
|
|
|
GetPollFDs() ([]int, error)
|
|
GetNetemFDs() ([]int, error)
|
|
|
|
// GetMemoryType()
|
|
|
|
Details() string
|
|
}
|
|
|
|
type NodeConfig struct {
|
|
Type string `json:"type"`
|
|
|
|
In struct {
|
|
} `json:"in"`
|
|
|
|
Out struct {
|
|
} `json:"out"`
|
|
}
|