+ // URL:
+ customTypes.put("java.net.URL", new CustomSerializer() {
+ @Override
+ protected String toString(Object value) {
+ if (value != null) {
+ return ((URL) value).toString();
+ }
+ 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";
+ }
+ });
+