Skip to content

Instantly share code, notes, and snippets.

@Gozala
Created May 9, 2018 21:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Gozala/c87be155e24c0d185a954714e78adec7 to your computer and use it in GitHub Desktop.
Save Gozala/c87be155e24c0d185a954714e78adec7 to your computer and use it in GitHub Desktop.
{
"namespace": "protocol",
"types": [
{
"$ref": "ProtocolHandler",
"type": "function",
"description": "Protocol handler",
"async": false,
"parameters": [
{
"name": "write",
"type": "Write",
"description": "Writes chunk of data to the output stream"
},
{
"name": "end",
"type": "End",
"description": "End the output stream"
}
]
},
{
"$ref": "Write",
"type": "function",
"async": false,
"parameters": [
{
"name": "chunk",
"type": "ArrayBuffer",
"description": "Data chunk to be written"
}
]
},
{
"$ref": "End",
"type": "function",
"async": false,
"parameters": []
}
],
"functions": [
{
"name": "registerProtocol",
"type": "function",
"description": "registers network protocol handler",
"async": true,
"parameters": [
{
"name": "scheme",
"type": "string",
"description": "The protocol scheme that implementation will handle."
},
{
"name": "handler",
"type": "ProtocolHandler",
"description": "Protocol handler for the registered protocol"
}
]
}
],
"properties": {},
"events": []
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment