diff --git a/README.md b/README.md
index 0fd0da0..94eb718 100644
--- a/README.md
+++ b/README.md
@@ -1,14 +1,18 @@
# ConfigLib
-**A Minecraft library for saving, loading, updating, and commenting YAML configuration files.**
+**A Minecraft library for saving, loading, updating, and commenting YAML
+configuration files.**
-This library facilitates creating, saving, loading, updating, and commenting YAML configuration
-files. It does so by automatically mapping instances of configuration classes to serializable maps
-which are first transformed into YAML and then saved to some specified file.
+This library facilitates creating, saving, loading, updating, and commenting
+YAML configuration files. It does so by automatically mapping instances of
+configuration classes to serializable maps which are first transformed into YAML
+and then saved to some specified file.
-Information on how to [import](#import) this library can be found at the end of this documentation.
-For a step-by-step tutorial that shows most features of this library in action check out
-the [Tutorial](https://github.com/Exlll/ConfigLib/wiki/Tutorial) page on the wiki!
+Information on how to [import](#import) this library can be found at the end of
+this documentation. For a step-by-step tutorial that shows most features of this
+library in action check out
+the [Tutorial](https://github.com/Exlll/ConfigLib/wiki/Tutorial) page on the
+wiki!
## Features
@@ -30,12 +34,13 @@ the [Tutorial](https://github.com/Exlll/ConfigLib/wiki/Tutorial) page on the wik
## Usage example
-This section contains a short usage example to get you started. The whole range of features is
-discussed in the following sections. Information on how to [import](#import) this library is located
-at the end of this documentation.
+This section contains a short usage example to get you started. The whole range
+of features is discussed in the following sections. Information on how
+to [import](#import) this library is located at the end of this documentation.
For a step-by-step tutorial with a more advanced example check out
-the [Tutorial](https://github.com/Exlll/ConfigLib/wiki/Tutorial) page on the wiki.
+the [Tutorial](https://github.com/Exlll/ConfigLib/wiki/Tutorial) page on the
+wiki.
If you want support for Bukkit classes like `ItemStack`, check out
the [Configuration properties](#configuration-properties) section.
@@ -96,8 +101,8 @@ public final class Example {
}
```
-By running the above code, a new YAML configuration is created at `/tmp/config.yml`. Its content
-looks like this:
+By running the above code, a new YAML configuration is created
+at `/tmp/config.yml`. Its content looks like this:
```yaml
host: 127.0.0.1
@@ -119,33 +124,38 @@ blockedUsers:
Two things are noticeable here:
-1. Not every user in the `blockedUsers` list has a `password` mapping. This is because null values
- are not output by default. That behavior can be changed by the builder.
-2. The password of the user with username `user3` has no comment. This is due to limitations of
- the YAML library. Configurations in lists, sets, or maps cannot have their comments printed.
+1. Not every user in the `blockedUsers` list has a `password` mapping. This is
+ because null values are not output by default. That behavior can be changed
+ by the builder.
+2. The password of the user with username `user3` has no comment. This is due to
+ limitations of the YAML library. Configurations in lists, sets, or maps
+ cannot have their comments printed.
## General information
-In the following sections the term _configuration type_ refers to any Java record type or to any
-non-generic class that is directly or indirectly (i.e. through subclassing) annotated with
-`@de.exlll.configlib.Configuration`. Accordingly, the term _configuration_ refers to an instance of
-such a type. A _configuration element_ is either a class field or a record component of a
+In the following sections the term _configuration type_ refers to any Java
+record type or to any non-generic class that is directly or indirectly (i.e.
+through subclassing) annotated with`@de.exlll.configlib.Configuration`.
+Accordingly, the term _configuration_ refers to an instance of such a type. A
+_configuration element_ is either a class field or a record component of a
configuration type.
### Declaring configuration types
To declare a configuration type, either define a Java record or annotate a class
-with `@Configuration` and make sure that it has a no-args constructor. The no-args constructor can
-be `private`. Inner classes (i.e. the ones that are nested but not `static`) have an implicit
-synthetic constructor with at least one argument and are, therefore, not supported.
+with `@Configuration` and make sure that it has a no-args constructor. The
+no-args constructor can be `private`. Inner classes (i.e. the ones that are
+nested but not `static`) have an implicit synthetic constructor with at least
+one argument and are, therefore, not supported.
-Now simply add components to your record or fields to your class whose type is any of the supported
-types listed in the next section. You can (and should) initialize all fields of a configuration
-class with non-null default values.
+Now simply add components to your record or fields to your class whose type is
+any of the supported types listed in the next section. You can (and should)
+initialize all fields of a configuration class with non-null default values.
### Supported types
-A configuration type may only contain configuration elements of the following types:
+A configuration type may only contain configuration elements of the following
+types:
| Type class | Types |
|-----------------------------|--------------------------------------------------------------------|
@@ -161,8 +171,8 @@ A configuration type may only contain configuration elements of the following ty
| `ConfigurationSerializable` | All Bukkit classes that implement this interface, like `ItemStack` |
| Collections | (Nested) Lists, sets, maps*, or arrays of previously listed types |
-(*) Map keys can only be of simple or enum type, i.e. they cannot be in the `Collections`,
-`Configurations`, or `ConfigurationSerializable` type class.
+(*) Map keys can only be of simple or enum type, i.e. they cannot be in
+the `Collections`, `Configurations`, or `ConfigurationSerializable` type class.
For all types that are not listed in the table above, you can provide your
own [custom serializer](#custom-serializers).
@@ -204,7 +214,8 @@ public final class SupportedTypes {
Examples of unsupported types
-The following class contains examples of types that this library does (and will) not support:
+The following class contains examples of types that this library does (and will)
+not support:
```java
public final class UnsupportedTypesExample of
-Let's say you have the following configuration type:
+Let's say you have the following configuration type
```java
@Configuration
@@ -264,31 +282,34 @@ i: 20
k: 30
```
-Now, when you use one of the methods below to call `update` for that configuration type and file,
-the configuration instance that `update` returns will have its `i` variable initialized to `20`
-and its `j` variable will have its default of `11`. After the operation, the configuration file will
-contain:
+Now, when you call the `update` method for that configuration type and file
+using any of the two options listed below, the configuration instance
+that `update` returns will have its `i` variable initialized to `20` and its `j`
+variable will have its default of `11`. After the operation, the configuration
+file will contain the following content (note that `k` has been dropped):
```yaml
i: 20
j: 11
```
+update
behavior when configuration file exists
+
nesting
examples
+ * The details of how configurations are serialized and deserialized are defined by the
+ * implementations of this interface.
+ *
+ * @param