Documentation ¶
Overview ¶
Package client is the reference client implementation for the watefall service
Index ¶
- func Echo(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, r []byte) ([]byte, error)
- func Exec(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, ...) (int, error)
- func Install(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, rdr *os.File, ...) (string, error)
- func Pull(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, src, dst string) error
- func PullBytes(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, dst io.Writer, ...) error
- func Push(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, src, dst string) error
- func PushBytes(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, srcBytes []byte, ...) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Echo ¶
func Echo(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, r []byte) ([]byte, error)
Echo streams back the contents of the request. Useful for testing the connection.
func Exec ¶
func Exec(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, stdout, stderr io.Writer, stdin io.Reader, cmd string, args ...string) (int, error)
Exec executes the requested command on the device. Semantics are the same as execve.
func Install ¶
func Install(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, rdr *os.File, args ...string) (string, error)
Install installs an app on the target device
func Pull ¶
func Pull(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, src, dst string) error
Pull request a file/directory from the device and unpacks the contents into the desired path.
func PullBytes ¶
func PullBytes(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, dst io.Writer, src string) error
PullBytes requests contents of a single src file from the device and provides it on dst writer.
func Push ¶
func Push(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, src, dst string) error
Push pushes a tar stream to the server running in the device.
func PushBytes ¶
func PushBytes(ctx context.Context, client waterfall_grpc_pb.WaterfallClient, srcBytes []byte, dst string) error
PushBytes pushes src reader contents to a dst filepath on device.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.