Opcode-specific response structs and encode/1 dispatcher.
Each struct below carries the payload that follows fuse_out_header
for a given opcode's success reply. Use via
Wick.Protocol.encode_response/3, which prepends the shared
16-byte out-header.
Ops that have no reply body (UNLINK, RMDIR, RENAME, RELEASE, FLUSH,
FSYNC, DESTROY, SETXATTR, …) and FORGET / BATCH_FORGET (no reply
ever) use %Empty{}.
Summary
Functions
Decode a stream of fuse_direntplus records. Test helper that
round-trips against encode/1 for ReaddirPlus responses.
Decode a stream of fuse_dirent records. Primarily a test helper
that round-trips against encode/1 for Readdir responses.
Encode the response body (excluding fuse_out_header).
Types
@type t() :: Wick.Protocol.Response.Empty.t() | Wick.Protocol.Response.Init.t() | Wick.Protocol.Response.Entry.t() | Wick.Protocol.Response.AttrReply.t() | Wick.Protocol.Response.Open.t() | Wick.Protocol.Response.CreateReply.t() | Wick.Protocol.Response.Write.t() | Wick.Protocol.Response.Read.t() | Wick.Protocol.Response.Statfs.t() | Wick.Protocol.Response.Readdir.t() | Wick.Protocol.Response.ReaddirPlus.t() | Wick.Protocol.Response.XattrSize.t() | Wick.Protocol.Response.XattrData.t() | Wick.Protocol.Response.GetLkReply.t()
Functions
@spec decode_direntpluses(binary()) :: {:ok, [Wick.Protocol.Response.DirentPlus.t()]} | {:error, :malformed_body}
Decode a stream of fuse_direntplus records. Test helper that
round-trips against encode/1 for ReaddirPlus responses.
@spec decode_dirents(binary()) :: {:ok, [Wick.Protocol.Response.Dirent.t()]} | {:error, :malformed_body}
Decode a stream of fuse_dirent records. Primarily a test helper
that round-trips against encode/1 for Readdir responses.
Encode the response body (excluding fuse_out_header).