SetConnection sets the RPC connection for callbacks. This must be called after the transport connection is established but before any filesystem operations that need callbacks.
(ctx context.Context, conn Conn)
| 68 | // This must be called after the transport connection is established |
| 69 | // but before any filesystem operations that need callbacks. |
| 70 | func (fs *callbackFS) SetConnection(ctx context.Context, conn Conn) { |
| 71 | fs.ctx = ctx |
| 72 | fs.conn = conn |
| 73 | } |
| 74 | |
| 75 | // isEnabled returns true if the named callback is enabled. |
| 76 | func (fs *callbackFS) isEnabled(name string) bool { |