git ssb

0+

wanderer🌟 / js-primea-hypervisor



Commit 7f083b2d6862e1386c0b25817fd1e1442bd8577a

use on creation

Signed-off-by: wanderer <mjbecze@gmail.com>
wanderer committed on 7/28/2017, 2:57:22 AM
Parent: 3c2fa2713562134ea6eec3a5224a1d71c7fec6da

Files changed

kernel.jschanged
tests/index.jschanged
kernel.jsView
@@ -40,9 +40,9 @@
4040 return this._startMessageLoop()
4141 }
4242
4343 async initialize (message) {
44- await this.run(message, 'onInitialize')
44+ await this.run(message, 'onCreation')
4545 return this._startMessageLoop()
4646 }
4747
4848 // waits for the next message
tests/index.jsView
@@ -9,9 +9,9 @@
99 start: false
1010 })
1111
1212 class BaseContainer extends AbstractContainer {
13- onInitialize (message) {
13+ onCreation (message) {
1414 this.kernel.state.code = message.data.byteLength ? message.data : undefined
1515 const port = message.ports[0]
1616 if (port) {
1717 this.kernel.ports.bind('root', port)
@@ -61,9 +61,9 @@
6161 '/': 'zdpuAozDi6tKPbqmHJxo7aNES2xVt1MkaCLyxcioEKzz3M2WH'
6262 }
6363
6464 class testVMContainer extends BaseContainer {
65- onInitialize () {}
65+ onCreation () {}
6666 }
6767
6868 const hypervisor = new Hypervisor(node.dag)
6969 hypervisor.registerContainer('test', testVMContainer)
@@ -506,9 +506,9 @@
506506 }
507507 }
508508
509509 class Waiter extends BaseContainer {
510- onInitialize () {
510+ onCreation () {
511511 return new Promise((resolve, reject) => {
512512 setTimeout(() => {
513513 resolve()
514514 }, 200)

Built with git-ssb-web