Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
dms3
go-merkledag
Commits
60d738bc
Commit
60d738bc
authored
Sep 27, 2014
by
Jeromy
Committed by
Juan Batiz-Benet
Oct 01, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
new files and directories appear to work properly
parent
8dda7830
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
0 deletions
+10
-0
merkledag.go
merkledag.go
+10
-0
No files found.
merkledag.go
View file @
60d738bc
...
@@ -65,6 +65,16 @@ func (n *Node) AddNodeLink(name string, that *Node) error {
...
@@ -65,6 +65,16 @@ func (n *Node) AddNodeLink(name string, that *Node) error {
return
nil
return
nil
}
}
func
(
n
*
Node
)
RemoveNodeLink
(
name
string
)
error
{
for
i
,
l
:=
range
n
.
Links
{
if
l
.
Name
==
name
{
n
.
Links
=
append
(
n
.
Links
[
:
i
],
n
.
Links
[
i
+
1
:
]
...
)
return
nil
}
}
return
u
.
ErrNotFound
}
// Size returns the total size of the data addressed by node,
// Size returns the total size of the data addressed by node,
// including the total sizes of references.
// including the total sizes of references.
func
(
n
*
Node
)
Size
()
(
uint64
,
error
)
{
func
(
n
*
Node
)
Size
()
(
uint64
,
error
)
{
...
...
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