code: public static boolean requiredBoolean(JSONObject o, String id) throws JSONConverterException {
          checkKeys(o, id);
          Object x = o.get(id);
          if (!(x instanceof Boolean)) {
              throw new JSONConverterException("Boolean expected at key '" + id + "' but was '" + x.getClass() + "'.");
          }
          return (Boolean) x;
      }
docs: Read an expected boolean.
  
  @param o  the object to parse
  @param id the id in the map that should point to the boolean
  @return the boolean
  @throws org.btrplace.json.JSONConverterException if the key does not point to a boolean