/** * Returns a list of accept strings. */ public List<String> getAcceptList() { List<Accept> accepts = getAccepts(); List<String> result = Lists.newArrayListWithCapacity(accepts.size()); for (Accept accept : accepts) { result.add(accept.getValue()); } return result; }
/** * Returns a list of accept strings. */ public List<String> getAcceptList() { List<Accept> accepts = getAccepts(); List<String> result = Lists.newArrayListWithCapacity(accepts.size()); for (Accept accept : accepts) { result.add(accept.getValue()); } return result; }
/** * Returns a list of accept strings. */ public List<String> getAcceptList() { List<Accept> accepts = getAccepts(); List<String> result = Lists.newArrayListWithCapacity(accepts.size()); for (Accept accept : accepts) { result.add(accept.getValue()); } return result; }
/** * Removes an accept string. * * @param acceptStr the string to remove * @return true if the acceptStr was removed. */ public boolean removeAccept(String acceptStr) { boolean modified = false; for (Accept accept : getAccepts()) { if (acceptStr.equals(accept.getValue())) { super.removeElement(Accept.KEY, accept); modified = true; } } return modified; }
/** * Removes an accept string. * * @param acceptStr the string to remove * @return true if the acceptStr was removed. */ public boolean removeAccept(String acceptStr) { boolean modified = false; for (Accept accept : getAccepts()) { if (acceptStr.equals(accept.getValue())) { super.removeElement(Accept.KEY, accept); modified = true; } } return modified; }
/** * Removes an accept string. * * @param acceptStr the string to remove * @return true if the acceptStr was removed. */ public boolean removeAccept(String acceptStr) { boolean modified = false; for (Accept accept : getAccepts()) { if (acceptStr.equals(accept.getValue())) { super.removeElement(Accept.KEY, accept); modified = true; } } return modified; }
List<Accept> accepts = getAccepts(); if (accepts.size() > 1) { StringBuilder sb = new StringBuilder();
List<Accept> accepts = getAccepts(); if (accepts.size() > 1) { StringBuilder sb = new StringBuilder();
List<Accept> accepts = getAccepts(); if (accepts.size() > 1) { StringBuilder sb = new StringBuilder();