+ return null;
+ }
+
+ @Override
+ protected Object fromString(String content) throws IOException {
+ if (content != null) {
+ return new URL(content);
+ }
+ return null;
+ }
+
+ @Override
+ protected String getType() {
+ return "java.net.URL";
+ }
+ });
+
+ // Images (this is currently the only supported image type by default)
+ customTypes.put("be.nikiroo.utils.Image", new CustomSerializer() {
+ @Override
+ protected String toString(Object value) {
+ return ((Image) value).toBase64();