code: public String getString(int index, String otherwise) {
          Object o = list.get(index);
          if (o == null) return otherwise;
          if (o instanceof String) return (String) o;
          if (o instanceof byte[]) return encodeBinary((byte[])o);
          throw new JsonException("not a string");
      }
docs: Returns the String at index or otherwise if not found
  
  @param index
  @param otherwise
  @return the value at index or otherwise
  @throws java.lang.IndexOutOfBoundsException if the index is out of the array bounds