Giter Club home page Giter Club logo

lua-flatbuffers's Introduction

lua-flatbuffers

Lua library for FlatBuffers

Status

Reading from trusted FlatBuffers is pretty stable now, but be careful that bad input buffer could crash your process, I didn't check the buffer border now.

Please feel free to send pull request!

如果您需要TODO里面的功能,可以在issue里提出,也非常欢迎发送pull request。

Usage

os.execute 'flatc --binary --schema test.fb'

FlatBuffersSchema = FlatBuffers.bfbs('test.bfbs')

your_message_as_a_lua_table = FlatBuffersSchema:decode('a buffer encode a message in FlatBuffers format')

说明

当前只支持Lua 5.3

只实现了我用到的FlatBuffers的读功能,后续有时间会把缺失的功能补上。

开发计划:

  • 写FlatBuffers
  • buffer:read函数对指针读范围进行安全检查
  • 不使用string元表
  • 直接解析schema文件, 不再依赖flatc编译schema到bfbs或json
  • 支持Lua 5.1/5.2和luajit
  • 添加文档和测试

TODO

  • write flatbuffers
  • parse schema, do not depend flatc to compile schema to bfbs/json
  • add support for Lua 5.1/5.2 and luajit
  • add documentation & tests & examples
  • safe buffer read library

lua-flatbuffers's People

Contributors

davidxifeng avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.