Skip to content

BinOM (Binary Object Model) - library for working with a hierarchical data format for general purposes.

License

Notifications You must be signed in to change notification settings

gbytegear/BinOM

Repository files navigation

BinOM(Binary Object Model) - library for working with a hierarchical data format for general purposes.

Basic goals:

  • Development of a generic data format for building structures of any complexity
  • Ensuring the most optimal read and data processing speed
  • Development of tools for the most convenient work with data

RoadMap

  • Implement container classes
    • binom::Number
    • binom::BitArray
      • binom::BitArray::Value
      • binom::BitArray::Iterator
      • binom::BitArray::ReverseIterator
    • binom::BufferArray
      • binom::BufferArray::GenericValueRef
      • binom::BufferArray::Iterator
      • binom::BufferArray::ReverseIterator
    • binom::Array
      • binom::Array::Iterator
      • binom::Array::ReverseIterator
    • binom::List - std::list<Variable>
    • Indexed containers:
      • namespace binom::index
        • binom::Index - table column
        • binom::Field - map field or multimap field or table cell
        • binom::FieldRef - frontend of map field or multimap field or table cell
      • binom::Map - std::set<index::Field, index::MapComparator>
      • binom::MultiMap - std::multiset<index::Field, index::MapComparator>
      • binom::Table
  • Implement serialization/deserialization methods of BinOM containers
    • binom::Number serialization/deserialization
    • binom::BitArray serialization/deserialization
    • binom::BufferArray serialization/deserialization
    • binom::Array serialization/deserialization
    • binom::List serialization/deserialization
    • binom::Map serialization/deserialization
    • binom::MultiMap serialization/deserialization
    • binom::Table serialization/deserialization
  • Implement file storage (DBMS)
    • File memory manager
    • File node accessor
  • Languages
    • BinOM Struct Description Language (BSDL)
    • BinOM Node Query (BNQ)
    • BinOM Data Change Language (BDCL)

Build & Run

Library

For build shared and static library - run in project directory:

# In this project directory
cd build
cmake -G <"MSYS Makefile"/"Unix Makefile"> ..
make -j <Hardware thread count>

Library files will be placed in build directiry:

<BinOM Project directory>/build/libbinom.a
<BinOM Project directory>/build/libbinom.so

Link library with your project:

g++ -I<Path to BinOM project directory>/libbinom/include -L<Path to BinOM project directory>/build -lbinom -lpthread <your sources>

Automatic test

For build and run automatic test - run in project directory:

make test -j

BinOM Types info

Types:

  • null - NULL
  • boolean - Boolean value
  • ui8 - Unsigned 8-bit integer number
  • si8 - Signed 8-bit integer number
  • ui16 - Unsigned 16-bit integer number
  • si16 - Signed 16-bit integer number
  • ui32 - Unsigned 32-bit integer number
  • si32 - Signed 32-bit integer number
  • f32 - 32-bit number with floating point
  • ui64 - Unsigned 64-bit integer number
  • si64 - Signed 64-bit integer number
  • f64 - 64-bit number with floating point
  • bit_array - Array of boolean values
  • ui8_array - Array of unsigned 8-bit integer numbers
  • si8_array - Array of signed 8-bit integer numbers
  • ui16_array - Array of unsigned 16-bit integer numbers
  • si16_array - Array of signed 16-bit integer numbers
  • ui32_array - Array of unsigned 32-bit integer numbers
  • si32_array - Array of signed 32-bit integer numbers
  • f32_array - Array of 32-bit numbers with floating point
  • ui64_array - Array of unsigned 64-bit integer numbers
  • si64_array - Array of signed 64-bit integer numbers
  • f64_array - Array of 64-bit numbers with floating point
  • array - Heterogeneous array
  • list - Heterogeneous doubly linked list
  • map - Key-sorted associative heterogeneous container with unique key
  • multimap - Key-sorted associative heterogeneous container with non-unique key
  • table - Multiple key-sorted associative heterogeneous container

KeyType:

  • null - NULL
  • boolean - Boolean value
  • ui8 - Unsigned 8-bit integer number
  • si8 - Signed 8-bit integer number
  • ui16 - Unsigned 16-bit integer number
  • si16 - Signed 16-bit integer number
  • ui32 - Unsigned 32-bit integer number
  • si32 - Signed 32-bit integer number
  • f32 - 32-bit number with floating point
  • ui64 - Unsigned 64-bit integer number
  • si64 - Signed 64-bit integer number
  • f64 - 64-bit number with floating point
  • bit_array - Array of boolean values
  • ui8_array - Array of unsigned 8-bit integer numbers
  • si8_array - Array of signed 8-bit integer numbers
  • ui16_array - Array of unsigned 16-bit integer numbers
  • si16_array - Array of signed 16-bit integer numbers
  • ui32_array - Array of unsigned 32-bit integer numbers
  • si32_array - Array of signed 32-bit integer numbers
  • f32_array - Array of 32-bit numbers with floating point
  • ui64_array - Array of unsigned 64-bit integer numbers
  • si64_array - Array of signed 64-bit integer numbers
  • f64_array - Array of 64-bit numbers with floating point

Type properties:

Type class enum / C++ Class:

  • null - /*Class not provided*/ - null
  • number - binom::Number - container for numeric data types;
  • bit_array - binom::BitArray - сontainer for boolean values;
  • buffer_array - binom::BufferArray - сontainer for the same type of numeric values;
  • array - binom::Array - heterogeneous array;
  • list - binom::List - heterogeneous doubly linked list;
  • map - binom::Map - Key-sorted associative heterogeneous containe with unique key;
  • multimap - binom::MultiMap - Key-sorted associative heterogeneous container with non-unique key;
  • table - binom::Table - Multiple key-sorted associative heterogeneous container

Number value widths:

  • byte - 8 bit width;
  • word - 16 bit width;
  • dword - 32 bit width;
  • qword - 64 bit width.

Number value types:

  • unsigned_integer;
  • signed_integer;
  • float_point.

Value type:

  • boolean - Boolean value
  • ui8 - Unsigned 8-bit integer number
  • si8 - Signed 8-bit integer number
  • ui16 - Unsigned 16-bit integer number
  • si16 - Signed 16-bit integer number
  • ui32 - Unsigned 32-bit integer number
  • si32 - Signed 32-bit integer number
  • f32 - 32-bit number with floating point
  • ui64 - Unsigned 64-bit integer number
  • si64 - Signed 64-bit integer number