diff options
author | Bas van Kervel <bas@ethdev.com> | 2015-06-09 22:06:51 +0800 |
---|---|---|
committer | Bas van Kervel <basvankervel@gmail.com> | 2015-06-11 20:01:41 +0800 |
commit | cc9ae399338557b6671e8fc83bb696c5ddb068fe (patch) | |
tree | 718e82c53c9dffebaf83cda6d1d1afe652e94e25 /rpc/api/utils.go | |
parent | 08d72a9245ce6f1e11f84a6b59d66cb083bea9f9 (diff) | |
download | dexon-cc9ae399338557b6671e8fc83bb696c5ddb068fe.tar dexon-cc9ae399338557b6671e8fc83bb696c5ddb068fe.tar.gz dexon-cc9ae399338557b6671e8fc83bb696c5ddb068fe.tar.bz2 dexon-cc9ae399338557b6671e8fc83bb696c5ddb068fe.tar.lz dexon-cc9ae399338557b6671e8fc83bb696c5ddb068fe.tar.xz dexon-cc9ae399338557b6671e8fc83bb696c5ddb068fe.tar.zst dexon-cc9ae399338557b6671e8fc83bb696c5ddb068fe.zip |
added admin API
Diffstat (limited to 'rpc/api/utils.go')
-rw-r--r-- | rpc/api/utils.go | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/rpc/api/utils.go b/rpc/api/utils.go index eae23d351..072abf883 100644 --- a/rpc/api/utils.go +++ b/rpc/api/utils.go @@ -21,6 +21,8 @@ func ParseApiString(apistr string, codec codec.Codec, xeth *xeth.XEth, eth *eth. for i, name := range names { switch strings.ToLower(strings.TrimSpace(name)) { + case AdminApiName: + apis[i] = NewAdminApi(xeth, eth, codec) case DebugApiName: apis[i] = NewDebugApi(xeth, eth, codec) case EthApiName: @@ -30,9 +32,9 @@ func ParseApiString(apistr string, codec codec.Codec, xeth *xeth.XEth, eth *eth. case NetApiName: apis[i] = NewNetApi(xeth, eth, codec) case PersonalApiName: - apis[i] = NewPersonal(xeth, eth, codec) + apis[i] = NewPersonalApi(xeth, eth, codec) case Web3ApiName: - apis[i] = NewWeb3(xeth, codec) + apis[i] = NewWeb3Api(xeth, codec) default: return nil, fmt.Errorf("Unknown API '%s'", name) } @@ -43,6 +45,8 @@ func ParseApiString(apistr string, codec codec.Codec, xeth *xeth.XEth, eth *eth. func Javascript(name string) string { switch strings.ToLower(strings.TrimSpace(name)) { + case AdminApiName: + return Admin_JS case DebugApiName: return Debug_JS case MinerApiName: |