diff options
author | Ethan Buchman <ethan@coinculture.info> | 2015-02-27 06:54:57 +0800 |
---|---|---|
committer | Ethan Buchman <ethan@coinculture.info> | 2015-02-27 06:54:57 +0800 |
commit | 5a827417d9cef0d2a765df11e747b1755bf04898 (patch) | |
tree | cd3764686dcb59f5b1b9faf16c9f29dcc5efd593 /ui | |
parent | 9446489cf3f2eb4b5237b9355b3975fde2886508 (diff) | |
parent | cc5c8a444dbc23501ba1a131eb2334f4b5e1ce9f (diff) | |
download | dexon-5a827417d9cef0d2a765df11e747b1755bf04898.tar dexon-5a827417d9cef0d2a765df11e747b1755bf04898.tar.gz dexon-5a827417d9cef0d2a765df11e747b1755bf04898.tar.bz2 dexon-5a827417d9cef0d2a765df11e747b1755bf04898.tar.lz dexon-5a827417d9cef0d2a765df11e747b1755bf04898.tar.xz dexon-5a827417d9cef0d2a765df11e747b1755bf04898.tar.zst dexon-5a827417d9cef0d2a765df11e747b1755bf04898.zip |
Merge branch 'develop' of https://github.com/ethereum/go-ethereum into develop
Diffstat (limited to 'ui')
-rw-r--r-- | ui/frontend.go | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/ui/frontend.go b/ui/frontend.go new file mode 100644 index 000000000..22dc64fdf --- /dev/null +++ b/ui/frontend.go @@ -0,0 +1,18 @@ +package ui + +// ReturnInterface is returned by the Intercom interface when a method is called +type ReturnInterface interface { + Get(i int) (interface{}, error) + Size() int +} + +// Frontend is the basic interface for calling arbitrary methods on something that +// implements a front end (GUI, CLI, etc) +type Frontend interface { + // Checks whether a specific method is implemented + Supports(method string) bool + // Call calls the given method on interface it implements. This will return + // an error with errNotImplemented if the method hasn't been implemented + // and will return a ReturnInterface if it does. + Call(method string) (ReturnInterface, error) +} |