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
1bebc90a
Commit
1bebc90a
authored
Jun 12, 2012
by
Han-Wen Nienhuys
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add some more comments.
parent
a8c70d06
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
fuse/api.go
fuse/api.go
+8
-2
No files found.
fuse/api.go
View file @
1bebc90a
...
@@ -26,11 +26,17 @@ type NodeFileSystem interface {
...
@@ -26,11 +26,17 @@ type NodeFileSystem interface {
String
()
string
String
()
string
}
}
// The FsNode implements the basic functionality of inodes; this is
// where the majority of the FS code for a typical filesystem will be.
type
FsNode
interface
{
type
FsNode
interface
{
// The following are called by the FileSystemConnector
// Inode and SetInode are basic getter/setters. They are
// called by the FileSystemConnector. You get them for free by
// embedding DefaultFsNode.
Inode
()
*
Inode
Inode
()
*
Inode
SetInode
(
node
*
Inode
)
SetInode
(
node
*
Inode
)
// Lookup finds a child node to this node; it is only called
// for directory FsNodes.
Lookup
(
out
*
Attr
,
name
string
,
context
*
Context
)
(
node
FsNode
,
code
Status
)
Lookup
(
out
*
Attr
,
name
string
,
context
*
Context
)
(
node
FsNode
,
code
Status
)
// Deletable() should return true if this inode may be
// Deletable() should return true if this inode may be
...
@@ -47,7 +53,7 @@ type FsNode interface {
...
@@ -47,7 +53,7 @@ type FsNode interface {
Access
(
mode
uint32
,
context
*
Context
)
(
code
Status
)
Access
(
mode
uint32
,
context
*
Context
)
(
code
Status
)
Readlink
(
c
*
Context
)
([]
byte
,
Status
)
Readlink
(
c
*
Context
)
([]
byte
,
Status
)
// Namespace operations
// Namespace operations
; these are only called on directory FsNodes.
Mknod
(
name
string
,
mode
uint32
,
dev
uint32
,
context
*
Context
)
(
newNode
FsNode
,
code
Status
)
Mknod
(
name
string
,
mode
uint32
,
dev
uint32
,
context
*
Context
)
(
newNode
FsNode
,
code
Status
)
Mkdir
(
name
string
,
mode
uint32
,
context
*
Context
)
(
newNode
FsNode
,
code
Status
)
Mkdir
(
name
string
,
mode
uint32
,
context
*
Context
)
(
newNode
FsNode
,
code
Status
)
Unlink
(
name
string
,
context
*
Context
)
(
code
Status
)
Unlink
(
name
string
,
context
*
Context
)
(
code
Status
)
...
...
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