make api.Channel as interface
[govpp.git] / doc.go
1 // Package govpp provides the entry point to govpp functionality. It provides the API for connecting the govpp core
2 // to VPP either using the default VPP adapter, or using the adapter previously set by SetAdapter function
3 // (useful mostly just for unit/integration tests with mocked VPP adapter).
4 //
5 // To create a connection to VPP, use govpp.Connect function:
6 //
7 //      conn, err := govpp.Connect()
8 //      if err != nil {
9 //              // handle error!
10 //      }
11 //      defer conn.Disconnect()
12 //
13 // Make sure you close the connection after using it. If the connection is not closed, it will leak resources. Please
14 // note that only one VPP connection is allowed for a single process.
15 //
16 // In case you need to mock the connection to VPP (e.g. for testing), use the govpp.SetAdapter function before
17 // calling govpp.Connect.
18 //
19 // Once connected to VPP, use the functions from the api package to communicate with it.
20 package govpp