throw new JSONException("JSONArray[" + index + "] is not a JSONObject.");
}
public long getLong(int index) throws JSONException {
Object object = this.get(index);
try {
<BUG>return object instanceof Number ? ((Number) object).longValue()
: Long.parseLong((String) object);

} catch (Exception e) {
throw new JSONException("JSONArray[" + index + "] is not a number.");
}</BUG>
}

throw new JSONException("JSONArray[" + index + "] is not a JSONObject.");
}
public long getLong(int index) throws JSONException {
Object object = this.get(index);
try {
if (object instanceof Number) {
return ((Number) object).longValue();
} else if (object instanceof String) {
return Long.parseLong((String) object);
}
} catch (Exception e) {
}
throw new JSONException("JSONArray[" + index + "] is not a number.");
}
