Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewFileWatcherChannel ¶
TODO make this constructor private
Create a file channel, a file channel is identified by its unique name name is the path where the watcher directory is created Only Master channel has the privilege to remove the dir at close time
Types ¶
type Channel ¶
type Channel interface { //send a raw json datagram to the channel, return when send is "complete" -- message is dropped to the persistent layer Send(string) error //receive a dategram, the go channel on the other end is closed when channel is closed GetMessage() <-chan string //safely release all in memory resources -- drain the sending/receiving/queue and GetMessage() go channel, channel is reusable after close Close() //destroy the persistent channel transport, channel is no longer reusable after destroy Destroy() }
Channel is defined as a persistent interface for raw json datagram transmission, it is designed to adopt both file ad named pipe
Click to show internal directories.
Click to hide internal directories.