Created
January 11, 2016 22:50
-
-
Save epixa/8abbe6af1418022312e2 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#shutdown() | |
removes the message listener from the fork | |
#parseIncomingMessage() | |
ignores non-arrays | |
invokes onMessage for given msg | |
#onMessage() | |
when type is WORKER_BROADCAST | |
emits broadcast event with data | |
when type is WORKER_LISTENING | |
flags worker as listening | |
emits listening event | |
#onDisconnect() | |
flags worker as not listening |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment