An open API service indexing awesome lists of open source software.

https://github.com/amiremohamadi/rw

A minimal library to parse and work with binary stored files in C++ (read and write lib)
https://github.com/amiremohamadi/rw

cplusplus cpp file parser read reader write

Last synced: about 1 year ago
JSON representation

A minimal library to parse and work with binary stored files in C++ (read and write lib)

Awesome Lists containing this project

README

          

# RW
> A minimal library to parse and work with binary stored files in C++ (read and write lib)

With Rwlib you can write a list of datatypes (includes your own data types!) in binary mode to a file or read from a file.


Read and write (from/to classes and structs) easier than any time!

## How to use
* Include rw.h to your cpp file
```c++
#include "rw.h"
```
* For example we have and struct like this:
```c++
struct Student {
char name[10];
int age;
int id;
};
```
* And we have a vector of Students:
```c++
vector list;
```
* Now create an object of RW:
```c++
RW rw("my_students.bin");
```
it will create a file with name "my_students.bin"
* Read and Write data with these two simple commands:
```c++
rw.parseToFile(list);
rw.parseToVec(list);
```

> There is also an example:
[example](https://github.com/amiremohamadi/rw/tree/master/example)

## ToDo
- [ ] Many Things!