Documentation
¶
Index ¶
- type BindReadOnlyArgs
- type BindReadOnlyReply
- type BindReadWriteArgs
- type BindReadWriteReply
- type ListArgs
- type ListReply
- type PathBinder
- type RemoteBinderClient
- type Server
- func (s Server) BindReadOnly(args *BindReadOnlyArgs, reply *BindReadOnlyReply) error
- func (s Server) BindReadWrite(args *BindReadWriteArgs, reply *BindReadWriteReply) error
- func (s Server) List(args *ListArgs, reply *ListReply) error
- func (s Server) Unbind(args *UnbindArgs, reply *UnbindReply) error
- type UnbindArgs
- type UnbindReply
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BindReadOnlyArgs ¶
type BindReadOnlyReply ¶
type BindReadOnlyReply struct {
// Errors types cannot be passed as-is in RPC so they
// must be converted to plain strings.
// Details at https://github.com/golang/go/issues/23340
Err string
}
type BindReadWriteArgs ¶
type BindReadWriteReply ¶
type BindReadWriteReply struct {
// Errors types cannot be passed as-is in RPC so they
// must be converted to plain strings.
// Details at https://github.com/golang/go/issues/23340
Err string
}
type ListReply ¶
type ListReply struct {
BindList []string
// Errors types cannot be passed as-is in RPC so they
// must be converted to plain strings.
// Details at https://github.com/golang/go/issues/23340
Err string
}
type PathBinder ¶
type PathBinder interface {
BindReadOnly(source string, destination string) error
BindReadWrite(source string, destination string) error
Unbind(destination string) error
List() ([]string, error)
}
func NewFakePathBinder ¶
func NewFakePathBinder() PathBinder
func NewLocalPathBinder ¶
func NewLocalPathBinder() PathBinder
func NewRemoteBindClient ¶
func NewRemoteBindClient(socketPath string) PathBinder
type RemoteBinderClient ¶
type RemoteBinderClient struct {
SocketPath string
// contains filtered or unexported fields
}
RemoteBinderClient sends client requests to RPC
func (*RemoteBinderClient) BindReadOnly ¶
func (r *RemoteBinderClient) BindReadOnly(source string, destination string) error
func (*RemoteBinderClient) BindReadWrite ¶
func (r *RemoteBinderClient) BindReadWrite(source string, destination string) error
func (*RemoteBinderClient) List ¶
func (r *RemoteBinderClient) List() ([]string, error)
func (*RemoteBinderClient) Unbind ¶
func (r *RemoteBinderClient) Unbind(destination string) error
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server receives RPC requests
func NewServer ¶
func NewServer(binder PathBinder) *Server
func (Server) BindReadOnly ¶
func (s Server) BindReadOnly(args *BindReadOnlyArgs, reply *BindReadOnlyReply) error
func (Server) BindReadWrite ¶
func (s Server) BindReadWrite(args *BindReadWriteArgs, reply *BindReadWriteReply) error
func (Server) Unbind ¶
func (s Server) Unbind(args *UnbindArgs, reply *UnbindReply) error
type UnbindArgs ¶
type UnbindArgs struct {
Destination string
}
type UnbindReply ¶
type UnbindReply struct {
// Errors types cannot be passed as-is in RPC so they
// must be converted to plain strings.
// Details at https://github.com/golang/go/issues/23340
Err string
}
Click to show internal directories.
Click to hide internal directories.