Package com.codingchili.core.files
Class YamlFileStore
java.lang.Object
com.codingchili.core.files.YamlFileStore
- All Implemented Interfaces:
FileStore
Parses YAML configuration files into JsonObjects.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionio.vertx.core.json.JsonObjectreadObject(io.vertx.core.buffer.Buffer buffer)Reads a T object from a specified application-relative path.voidwriteObject(io.vertx.core.json.JsonObject object, Path path)Writes a json-object to the given path.
-
Constructor Details
-
YamlFileStore
public YamlFileStore()
-
-
Method Details
-
readObject
public io.vertx.core.json.JsonObject readObject(io.vertx.core.buffer.Buffer buffer)Description copied from interface:FileStoreReads a T object from a specified application-relative path.- Specified by:
readObjectin interfaceFileStore- Parameters:
buffer- data of the object to read to json- Returns:
- the loaded json object.
-
writeObject
Description copied from interface:FileStoreWrites a json-object to the given path.- Specified by:
writeObjectin interfaceFileStore- Parameters:
object- the object to write.path- the path to where the object is written to.
-
getExtensions
- Specified by:
getExtensionsin interfaceFileStore- Returns:
- the extension handled by this file store.
-