https://github.com/astral-c/bstream
A Binary Reader/Writer for C++
https://github.com/astral-c/bstream
bstream cpp file-reader
Last synced: 11 months ago
JSON representation
A Binary Reader/Writer for C++
- Host: GitHub
- URL: https://github.com/astral-c/bstream
- Owner: Astral-C
- License: mit
- Created: 2018-01-29T23:03:35.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2024-09-13T14:24:01.000Z (over 1 year ago)
- Last Synced: 2024-09-14T05:19:14.941Z (over 1 year ago)
- Topics: bstream, cpp, file-reader
- Language: C++
- Size: 70.3 KB
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# bStream - A Binary Reader/Writer for C++
bStream is a header only library for reading and writing big/little endian binary files in C++.
The library contains two classes, `CFileStream` for reading and writing 'physical' files and `CMemoryStream` which is for creating and modifying files in memory. `CMemoryStream` has two constructors, one for generating a new buffer and one for reading from a pre-existing buffer, when made using a pre-existing buffer the stream will not automatically expand as it would when generating a new buffer.
## Usage
To include bStream in your project simply put `#define BSTREAM_IMPLEMENTATION` in _one_ of the files where you are including bStream. Alternatively the provided bstream.cpp can be added to your project's files and it will handle this for you.