code: public static boolean isEmpty(Object value) throws IOException {
  		if(value instanceof String) {
  			// If A is a string, then the result is A.
  			return ((String)value).isEmpty();
  		} else if(value == null) {
  			// Otherwise, if A is null, then the result is "".
  			return true;
  		} else if(value instanceof Writable) {
  			return ((Writable)value).getLength() == 0;
  		} else if(value instanceof Node) {
  			// Otherwise, if is a DOM node, serialize the output
  			return false; // There is a node, is not empty
  		} else {
  			// Otherwise, if A.toString() throws an exception, then raise an error
  			// Otherwise, the result is A.toString();
  			return value.toString().isEmpty();
  		}
  	}
docs: Checks if a value is null or empty.