0.0.4 • Published 11 years ago

pusher.flexvar v0.0.4

Weekly downloads
6
License
-
Repository
bitbucket
Last release
11 years ago

pusher.flexvar

A C++ "flexible variable" library, designed for conveniently dealing with JSON/BSON-like data within C++.

It was designed to make writing the bridge code for C++ Node modules easier. It also happens to be fairly useful as a C++ library on its own. It allows code such as follows to be written in C++.

flexvar v, q;
q = 42.001f;
v["x"] = 4;
v["y"] = 12;
v["message"] = "Hello World";

This in turn is very easy to recursively copy into a v8::Handle<Object> for transfer of data into Javascript code.

Overview

Huh? A C++ NPM module?

This is a bit of an experiment in distributing C++ code via an NPM package...

Demo

TBD.

Examples

TBD.

User Manual

TBD.

API Documentation

TBD.

F.A.Q.

How do I use a flexvar to share rather than copy data between C++ and JS?

This isn't directly support. The flexvar library is intended to be lightweight and without direct dependencies on V8. A library for data sharing between C++ and Javascript (while very useful) would look quite different from the current flexvar library.

Benchmarks

TBD.

Unit Tests

Build the project and run the unittest executable.

Dependencies

  • None

Development

Currently only tested on Windows in a Visual Studio + cygwin environment; however should be usable on any platform with minimal changes.

npm install --dev
node rebuild.js