code: public static Reader reader(Format type, final InputStream in,
                                  final Map<String, ReadHandler<?, ?>> customHandlers,
                                  final DefaultReadHandler<?> customDefaultHandler) {
          try {
              switch (type) {
                  case JSON:
                  case JSON_VERBOSE:
                      return ReaderFactory.getJsonInstance(in, customHandlers, customDefaultHandler);
                  case MSGPACK:
                      return ReaderFactory.getMsgpackInstance(in, customHandlers, customDefaultHandler);
                  default:
                      throw new IllegalArgumentException("Unknown Reader type: " + type.toString());
              }
          } catch (Throwable e) {
              throw new RuntimeException(e);
          }
      }
docs: Creates a reader instance.
  @param type the format to read in
  @param in the input stream to read from
  @param customHandlers a map of custom ReadHandlers to use in addition
  or in place of the default ReadHandlers
  @param customDefaultHandler a DefaultReadHandler to use for processing
  encoded values for which there is no read handler
  @return a reader