Integrations moved to Old Repos
This commit is contained in:
1 parent
7bc349c258
commit
4cf7212625
593 files changed
No files matched your search
@@ -0,0 +1,37 @@
|
||||
function newEthereumActionSwitch() {
|
||||
|
||||
let thisObject = {
|
||||
executeAction: executeAction,
|
||||
initialize: initialize,
|
||||
finalize: finalize
|
||||
}
|
||||
|
||||
let functionLibraryGeth = newGeth()
|
||||
|
||||
return thisObject
|
||||
|
||||
function finalize() {
|
||||
functionLibraryGeth = undefined
|
||||
}
|
||||
|
||||
function initialize() {
|
||||
/* Nothing to initialize since a Function Library does not hold any state. */
|
||||
}
|
||||
|
||||
async function executeAction(action) {
|
||||
switch (action.name) {
|
||||
case 'Install Geth': {
|
||||
functionLibraryGeth.install(action.node)
|
||||
break
|
||||
}
|
||||
case 'Run Geth': {
|
||||
functionLibraryGeth.run(action.node)
|
||||
break
|
||||
}
|
||||
case 'Stop Geth': {
|
||||
functionLibraryGeth.stop(action.node)
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user