Commit 12537a60 authored by Łukasz Magiera's avatar Łukasz Magiera

coreapi: key: some changes to match command functionality

License: MIT
Signed-off-by: default avatarŁukasz Magiera <magik6k@gmail.com>
parent 24dde488
......@@ -4,14 +4,20 @@ import (
"context"
options "github.com/ipfs/go-ipfs/core/coreapi/interface/options"
"gx/ipfs/QmdVrMn1LhB4ybb8hMVaMLXnA8XRSewMnK6YqXKXoTcRvN/go-libp2p-peer"
)
// Key specifies the interface to Keys in KeyAPI Keystore
type Key interface {
// Key returns key name
Name() string
// Path returns key path
Path() Path
// Id returns key PeerID
Id() peer.ID
}
// KeyAPI specifies the interface to Keystore
......@@ -28,5 +34,5 @@ type KeyAPI interface {
List(ctx context.Context) ([]Key, error)
// Remove removes keys from keystore. Returns ipns path of the removed key
Remove(ctx context.Context, name string) (Path, error)
Remove(ctx context.Context, name string) (Key, error)
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment