Mention in README that transient fields are not serialised

This commit is contained in:
Moandji Ezana 2016-06-15 09:42:47 -04:00
parent ddeab75689
commit 40f866f5cd

View file

@ -236,7 +236,7 @@ toml.containsTableArray("a"); // false
### Converting Objects To TOML ### Converting Objects To TOML
You can write any arbitrary object to a TOML `String`, `File`, `Writer`, or `OutputStream` with a `TomlWriter`. Each TomlWriter instance is customisable, immutable and threadsafe, so it can be reused and passed around. Constants are ignored. You can write any arbitrary object to a TOML `String`, `File`, `Writer`, or `OutputStream` with a `TomlWriter`. Each TomlWriter instance is customisable, immutable and threadsafe, so it can be reused and passed around. Constants and transient fields are ignored.
```java ```java
class AClass { class AClass {
@ -277,11 +277,11 @@ class BClass {
BClass obj = new BClass(); BClass obj = new BClass();
obj.aMap.put("item", 1); obj.aMap.put("item", 1);
TomlWriter tomlWriter = new TomlWriter.Builder(). TomlWriter tomlWriter = new TomlWriter.Builder()
indentValuesBy(2). .indentValuesBy(2)
indentTablesBy(4). .indentTablesBy(4)
padArrayDelimitersBy(3). .padArrayDelimitersBy(3)
build(); .build();
String tomlString = tomlWriter.write(obj); String tomlString = tomlWriter.write(obj);