@SuppressWarnings("rawtypes")
public void marshal(Object value, HierarchicalStreamWriter writer,
MarshallingContext context) {
AbstractMap map = (AbstractMap) value;
for (Object obj : map.entrySet()) {
Entry entry = (Entry) obj;
writer.startNode(entry.getKey().toString());
if (entry.getValue() instanceof String) {
writer.setValue(entry.getValue().toString());
} else if (entry.getValue() instanceof Map) {