Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go-fuse
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
go-fuse
Commits
19509970
Commit
19509970
authored
Sep 05, 2011
by
Han-Wen Nienhuys
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update documentation for a bit.
parent
9ec4c8af
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
4 deletions
+18
-4
README
README
+7
-0
fuse/api.go
fuse/api.go
+11
-4
No files found.
README
View file @
19509970
...
...
@@ -11,6 +11,13 @@ negligible.
* Supports in-process mounting of different FileSystems onto
subdirectories of the FUSE mount.
* Supports 3 interfaces for writing filesystems:
- PathFileSystem: define filesystems in terms path names
- NodeFileSystem: define filesystems in terms of inodes.
NodeFileSystem allow true hardlinks.
- RawFileSystem: define filesystems in terms of FUSE's raw
wire protocol.
* Includes two fleshed out examples, zipfs and unionfs.
...
...
fuse/api.go
View file @
19509970
// The fuse package provides APIs to implement filesystems in
// userspace, using libfuse on Linux.
// userspace, using libfuse on Linux. Typically, each call of the API
// happens in its own goroutine, so take care to make the file system
// thread-safe.
package
fuse
import
(
...
...
@@ -8,6 +11,11 @@ import (
// Types for users to implement.
// NodeFileSystem is a high level API that resembles the kernel's idea
// of what an FS looks like. NodeFileSystems can have multiple
// hard-links to one file, for example. It is also suited if the data
// to represent fits in memory: you can construct FsNode at mount
// time, and the filesystem will be ready.
type
NodeFileSystem
interface
{
Unmount
()
Mount
(
conn
*
FileSystemConnector
)
...
...
@@ -58,7 +66,6 @@ type FsNode interface {
Utimens
(
file
File
,
atime
uint64
,
mtime
uint64
,
context
*
Context
)
(
code
Status
)
}
// A filesystem API that uses paths rather than inodes. A minimal
// file system should have at least a functional GetAttr method.
// Typically, each call happens in its own goroutine, so take care to
...
...
@@ -146,7 +153,7 @@ type WithFlags struct {
Flags
uint32
}
// MountOptions contains time out options for a FileSystem. The
// MountOptions contains time out options for a
(Node)
FileSystem. The
// default copied from libfuse and set in NewMountOptions() is
// (1s,1s,0s).
type
FileSystemOptions
struct
{
...
...
@@ -181,7 +188,7 @@ type DefaultFileSystem struct{}
// DefaultFile returns ENOSYS for every operation.
type
DefaultFile
struct
{}
// RawFileSystem is an interface close
r
to the FUSE wire protocol.
// RawFileSystem is an interface close to the FUSE wire protocol.
//
// Unless you really know what you are doing, you should not implement
// this, but rather the FileSystem interface; the details of getting
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment