code: public Double getDouble(String name) {
          //let it fail in the more general case where it isn't actually a number
          Number number = (Number) content.get(name);
          if (number == null) {
              return null;
          } else if (number instanceof Double) {
              return (Double) number;
          } else {
              return number.doubleValue(); //autoboxing to Double
          }
      }
docs: Retrieves the value from the field name and casts it to {@link Double}.
  
  Note that if value was stored as another numerical type, some truncation or rounding may occur.
  
  @param name the name of the field.
  @return the result or null if it does not exist.