Skip to content

funcards/engine.io-parser

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

engine.io-parser

workflow Coverage Status GoDoc License

This is the GO parser version 4 for the engine.io protocol encoding.

Installation

Use go get.

go get github.com/funcards/engine.io-parser/v4

Then import the parser package into your own code.

import "github.com/funcards/engine.io-parser/v4"

How to use

The parser can encode/decode packets, payloads and payloads as binary.

Example:

payload := eiop.Payload{
    {Type: eiop.Open},
    {Type: eiop.Close},
    {Type: eiop.Ping, Data: "probe"},
    {Type: eiop.Pong, Data: "probe"},
    {Type: eiop.Message, Data: "test"},
}
encoded := payload.Encode(&buf)
fmt.Println(encoded.(string))

payload1 = eiop.DecodePayload(encoded) // payload == payload1

License

Distributed under MIT License, please see license file within the code for more details.

About

Parser for the engine.io protocol, used by server

Resources

License

Stars

1 star

Watchers

1 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages