/** * Gets the value at the specified index. * * @param index the index to retrieve * @return the key at the specified index * @throws IndexOutOfBoundsException if the index is invalid */ public V getValue(final int index) { return get(insertOrder.get(index)); }
@Override public V getValue() { if (readable == false) { throw new IllegalStateException(AbstractHashedMap.GETVALUE_INVALID); } return parent.get(last); }
@Override public V getValue() { return parent.get(getKey()); }
/** * Removes the element at the specified index. * * @param index the index of the object to remove * @return the removed value, or <code>null</code> if none existed * @throws IndexOutOfBoundsException if the index is invalid */ public V remove(final int index) { return remove(get(index)); }
/** * Used to get a Message from the set of already retrieved message via it's message Id. * <br>If a Message with the provided id has not already been retrieved (thus, doesn't not exist in this MessageHistory * object), then this method returns null. * <p> * <b>Note:</b> This methods is not the same as {@link MessageChannel#getMessageById(long)}, which itself queries * Discord. This method is for getting a message that has already been retrieved by this MessageHistory object. * * @param id * The id of the requested Message. * * @return Possibly-null Message with the same {@code id} as the one provided. */ public Message getMessageById(long id) { return history.get(id); }
public int doEndTag() throws JspException { try { JspWriter out = pageContext.getOut(); List optList = null; ListOrderedMap optGroups = null; try { optList = (List) getFormObject().getOptionLists().get(name); outputOptionsMarkup(optList,out); } catch (ClassCastException e){ // maybe it's a ListOrderedMap of optgroups optGroups = (ListOrderedMap) getFormObject().getOptionLists().get(name); OrderedMapIterator ogKey = optGroups.mapIterator(); while (ogKey.hasNext()) { String optGroupName = (String) ogKey.next(); out.println("<optgroup label=\""+StringEscapeUtils.ESCAPE_HTML4.translate(optGroupName)+"\">"); outputOptionsMarkup((List)optGroups.get(optGroupName),out); out.println("</optgroup>"); } } catch (NullPointerException npe) { System.out.println("OptionTag could not find option list for "+name); } } catch(Exception ex) { ex.printStackTrace(); throw new JspException(ex.getMessage()); } return SKIP_BODY; // EVAL_PAGE; did colnames only //EVAL_PAGE in connection pooled version; } }
while (dpHashIt.hasNext()) { String uri = dpHashIt.next(); DataProperty dp = (DataProperty) dpMap.get(uri); DynamicField dynamo = new DynamicField(); dynamo.setName(dp.getPublicName());