code: public <T> String write(final T object, final DataTypeDescriptor<T> descriptor,
  			final boolean indent) throws IOException {
  		if (descriptor == null) throw new NullPointerException("descriptor");
  
  		StringWriter out = new StringWriter();
  		JsonGenerator generator = factory.createGenerator(out);
  		if (indent) {
  			generator.useDefaultPrettyPrinter();
  		}
  
  		write(object, descriptor, generator);
  		generator.flush();
  		return out.toString();
  	}
docs: Serializes an object into a string.