Skip to content
Leonhard edited this page Oct 20, 2020 · 12 revisions

The usage is generic for every FileType.

Instantiation:

You can either use the internal constructors of the FileTypes or the LightningBuilder

Valid constructors (For all FileTypes) are:

new FILETYPE-HERE(FILE)
new FILETYPE-HERE(NAME, PATH)
new FILETYPE-HERE(FILETYPE) //Copy-constructor
new FILETYPE-HERE(NAME, PATH, INPUTSTREAM)

Usage:

Basic-Operations:

![Basic operations]

Yaml yaml = new Yaml("Name", "Path");
Config config = new Config("Name", "Path"); //Special version of YAML
Json json = new Json("Name", "Path");
Toml toml = new Toml("Name", "Path");

Config configUsingLightningBuilder = LightningBuilder
     .fromFile("")
     .addInputStreamFromResource() //Optional
     .setDataType()
     .setReloadSettings()
     .createConfig(); // Building

Getting values out of our file.

Getters

More advanced getters:

More advanced operations

IO-Stuff:

Misc-Operations:

Clone this wiki locally