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
45092e19
Commit
45092e19
authored
Oct 16, 2014
by
Jeromy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add blockset and bloomfilter and beginnings of pinning service
parent
7fe2ad68
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
0 deletions
+8
-0
merkledag.go
merkledag.go
+8
-0
No files found.
merkledag.go
View file @
45092e19
...
@@ -59,6 +59,14 @@ func MakeLink(n *Node) (*Link, error) {
...
@@ -59,6 +59,14 @@ func MakeLink(n *Node) (*Link, error) {
},
nil
},
nil
}
}
func
(
l
*
Link
)
GetNode
(
serv
*
DAGService
)
(
*
Node
,
error
)
{
if
l
.
Node
!=
nil
{
return
l
.
Node
,
nil
}
return
serv
.
Get
(
u
.
Key
(
l
.
Hash
))
}
// AddNodeLink adds a link to another node.
// AddNodeLink adds a link to another node.
func
(
n
*
Node
)
AddNodeLink
(
name
string
,
that
*
Node
)
error
{
func
(
n
*
Node
)
AddNodeLink
(
name
string
,
that
*
Node
)
error
{
lnk
,
err
:=
MakeLink
(
that
)
lnk
,
err
:=
MakeLink
(
that
)
...
...
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