github.com/simpleiot/simpleiot@v0.18.3/client/doc.go (about)

     1  /*
     2  Package client contains utilties for creating Simple IoT clients.
     3  
     4  A Simple IoT Client contains the logic for nodes described in the Simple IoT graph store.
     5  Examples of built in clients include: Modbus, 1-wire, Upstream, etc.
     6  
     7  A client [Manager] is used to watch the Simple IoT store and create and update new clients
     8  as they are created and modified.
     9  
    10  See [Client] and [NewManager] for ideas on how to get started with your own client.
    11  
    12  When debugging client test code, it can be very useful to dump the node tree for inspection.
    13  This can be done with the following code:
    14  
    15  	nodes, err := client.ExportNodes(nc, "root")
    16  	if err != nil {
    17  		t.Fatal("Error exporting nodes: ", err)
    18  	}
    19  
    20  	fmt.Println(string(nodes))
    21  
    22  This package also contains a number of utility functions for interacting with the
    23  Simple IoT [NATS API].
    24  
    25  [NATS API]: https://docs.simpleiot.org/docs/ref/api.html#nats
    26  */
    27  package client