Code Monkey home page Code Monkey logo

catbuffer's Introduction

catbuffer

Build Status

Catbuffer library defines the protocol to serialize and deserialize Catapult entities. SDKs and applications use the generated code to interact with REST transaction endpoint.

Supported languages

  • C++

Requirements

  • Python >= 3.4
  • pip install -r requirements.txt

Usage

python main.py [OPTIONS]

Option Description Default
-s, --schema TEXT input CATS file
-o, --output TEXT output directory _generated
-i, --include TEXT schema root directory ./schemas
-g, --generator TEXT generator to use to produce output files
-c, --copyright TEXT file containing copyright data to use with output files ../HEADER.inc

Examples

Generate transaction builders

The schemas define the entities data structure. The library generates the leanest code necessary to serialize and deserialize defined entities.

For example, run the following command to generate C++ transaction builders for a transfer transaction:

python main.py --schema schemas/transfer/transfer.cats --generator cpp_builder

The generator creates a new file under _generated/cpp_builder folder.

Run the linter

pylint --load-plugins pylint_quotes main.py catparser generators test
pycodestyle --config=.pycodestyle .

Run the tests

python -m unittest discover -v

Copyright (c) 2018 Jaguar0625, gimre, BloodyRookie, Tech Bureau, Corp Licensed under the MIT License

catbuffer's People

Contributors

alexhuszagh avatar bloodyrookie avatar dgarcia360 avatar gimre-xymcity avatar jaguar0625 avatar vektrat avatar

Stargazers

 avatar

Watchers

 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.