package vg.civcraft.mc.civmodcore.serialization;

public class ExampleSerializable implements NBTSerializable {

	private String message;

	public String getMessage() {
		return this.message;
	}

	public void setMessage(String message) {
		this.message = message;
	}

	@Override
	public void serialize(NBTCompound nbt) throws NBTSerializationException {
		nbt.setString("message", this.message);
	}

	@Override
	public void deserialize(NBTCompound nbt) throws NBTSerializationException {
		this.message = nbt.getString("message");
	}

}

@@ -43,23 +43,100 @@
 ation;%0A%0A
+/**%0A * Class to be used during testing as an example serializable.%0A */%0A
 public 
+final 
 class Ex
@@ -157,33 +157,23 @@
 ble 
-implement
+extend
 s NBT
-Serializabl
+Cach
 e %7B%0A
@@ -186,396 +186,412 @@
 ate 
-String 
+static final String MESSAGE_KEY = %22
 message
+%22
 ;%0A%0A%09
-public String getMessage() %7B%0A%09%09return this.message;%0A%09%7D%0A%0A%09public void setMessage(
+/**%0A%09 * Gets the message stored within the NBT directly.%0A%09 *%0A%09 * @return Returns the message stored within this class' NBT.%0A%09 */%0A%09public 
 String 
-m
+getM
 essage
+(
 ) %7B%0A%09%09
-this.message = message;%0A%09%7D%0A%0A%09@Override%0A%09public void serialize(NBTCompound nbt) throws NBTSerializationException %7B%0A%09%09nbt.setString(%22message%22, this.message);%0A%09%7D%0A%0A%09@Override%0A%09public void deserialize(NBTCompound nbt) throws NBTSerializationException %7B%0A%09%09this.message = 
+return this.nbt.getString(MESSAGE_KEY);%0A%09%7D%0A%0A%09/**%0A%09 * Assigns a message to this class' NBT.%0A%09 *%0A%09 * @param message The message to assign.%0A%09 */%0A%09public void setMessage(String message) %7B%0A%09%09this.
 nbt.
-g
+s
 etSt
@@ -595,25 +595,36 @@
 tString(
-%22
+MESSAGE_KEY, 
 message
-%22
 );%0A%09%7D%0A%0A%7D

Test :: ExampleSerializable swapped over to NBTCache