Skip to content
This repository has been archived by the owner on Jan 2, 2019. It is now read-only.
/ libini Public archive

A simple serialization/parser ini C library with a C++17 interface

License

Notifications You must be signed in to change notification settings

anvouk/libini

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NOTE: This project has been deprecated.

libini

A simple serialization/parser ini C library with a C++17 interface.

Features

  • std::string, int and float serialization and parsing
  • simple ini manipulation (can only add keys)
  • small and fast implementation
  • no third-party library required

Quick Start

Serialization

#include <libini/ini.hpp>

int main() {
    libini::ini ini;
    ini.set("", "GlobalKey", 123);
    ini.set("Person.Attributes", "Name", "John");

    ini.serialize("my_file.ini")
}

Parsing

#include <libini/ini.hpp>

int main() {
    libini::ini ini;
    ini.parse("my_file.ini")

    int global_key = ini.get<int>("", "GlobalKey");
    std::string name = ini.get<std::string>("Person.Attributes", "Name");

    // try getting a non-existing key
    auto some_key = ini.get_opt<int>("MySection", "SomeKey");
 }

About

A simple serialization/parser ini C library with a C++17 interface

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published