/** * Remove all parameters with the specified name. * @param paramName the name of parameters to remove */ public final void removeAll(final String paramName) { final ParameterList params = getParameters(paramName); parameters.removeAll(params.parameters); }
/** * Remove all parameters with the specified name. * @param paramName the name of parameters to remove */ public final void removeAll(final String paramName) { final ParameterList params = getParameters(paramName); parameters.removeAll(params.parameters); }
/** * Remove all parameters with the specified name. * @param paramName the name of parameters to remove */ public final void removeAll(final String paramName) { final ParameterList params = getParameters(paramName); parameters.removeAll(params.parameters); }
/** * Remove all parameters with the specified name. * @param paramName the name of parameters to remove */ public final void removeAll(final String paramName) { final ParameterList params = getParameters(paramName); parameters.removeAll(params.parameters); }
/** * Remove all parameters with the specified name. * @param paramName the name of parameters to remove */ public final void removeAll(final String paramName) { final ParameterList params = getParameters(paramName); parameters.removeAll(params.parameters); }
/** * Convenience method for retrieving a list of named parameters. * * @param name name of parameters to retrieve * @return a parameter list containing only parameters with the specified name */ public final ParameterList getParameters(final String name) { return getParameters().getParameters(name); }
/** * Convenience method for retrieving a list of named parameters. * * @param name name of parameters to retrieve * @return a parameter list containing only parameters with the specified name */ public final ParameterList getParameters(final String name) { return getParameters().getParameters(name); }
/** * Convenience method for retrieving a list of named parameters. * * @param name name of parameters to retrieve * @return a parameter list containing only parameters with the specified name */ public final ParameterList getParameters(final String name) { return getParameters().getParameters(name); }
/** * Convenience method for retrieving a list of named parameters. * * @param name name of parameters to retrieve * @return a parameter list containing only parameters with the specified name */ public final ParameterList getParameters(final String name) { return getParameters().getParameters(name); }
/** * Convenience method for retrieving a list of named parameters. * @param name name of parameters to retrieve * @return a parameter list containing only parameters with the specified name */ public final ParameterList getParameters(final String name) { return getParameters().getParameters(name); }
/** * Ensure a parameter occurs once. * * @param paramName * the parameter name * @param parameters * a list of parameters to query * @throws ValidationException * when the specified parameter does not occur once */ public void assertOne(final String paramName, final ParameterList parameters) throws ValidationException { if (parameters.getParameters(paramName).size() != 1) { throw new ValidationException(ASSERT_ONE_MESSAGE, new Object[] {paramName}); } }
/** * Ensure a parameter occurs no more than once. * * @param paramName * the parameter name * @param parameters * a list of parameters to query * @throws ValidationException * when the specified parameter occurs more than once */ public void assertOneOrLess(final String paramName, final ParameterList parameters) throws ValidationException { if (parameters.getParameters(paramName).size() > 1) { throw new ValidationException(ASSERT_ONE_OR_LESS_MESSAGE, new Object[] {paramName}); } }
/** * Ensure a parameter occurs once. * * @param paramName * the parameter name * @param parameters * a list of parameters to query * @throws ValidationException * when the specified parameter does not occur once */ public void assertOne(final String paramName, final ParameterList parameters) throws ValidationException { if (parameters.getParameters(paramName).size() != 1) { throw new ValidationException(ASSERT_ONE_MESSAGE, new Object[] {paramName}); } }
/** * Ensure a parameter occurs once. * * @param paramName * the parameter name * @param parameters * a list of parameters to query * @throws ValidationException * when the specified parameter does not occur once */ public void assertOne(final String paramName, final ParameterList parameters) throws ValidationException { if (parameters.getParameters(paramName).size() != 1) { throw new ValidationException(ASSERT_ONE_MESSAGE, new Object[] {paramName}); } }
/** * Replace any parameters of the same type with the one specified. * @param parameter parameter to add to this list in place of all others with the same name * @return true if successfully added to this list */ public final boolean replace(final Parameter parameter) { for (final Iterator<Parameter> i = getParameters(parameter.getName()).iterator(); i.hasNext();) { remove(i.next()); } return add(parameter); }
/** * Replace any parameters of the same type with the one specified. * @param parameter parameter to add to this list in place of all others with the same name * @return true if successfully added to this list */ public final boolean replace(final Parameter parameter) { for (final Iterator i = getParameters(parameter.getName()).iterator(); i.hasNext();) { remove((Parameter) i.next()); } return add(parameter); }
/** * Replace any parameters of the same type with the one specified. * @param parameter parameter to add to this list in place of all others with the same name * @return true if successfully added to this list */ public final boolean replace(final Parameter parameter) { for (final Iterator<Parameter> i = getParameters(parameter.getName()).iterator(); i.hasNext();) { remove(i.next()); } return add(parameter); }
/** * @param p * @return AbbreviatedValue */ public static AbbreviatedValue getAbbrevVal(final Property p) { ParameterList pars = p.getParameters(); ParameterList abbrevPars = pars.getParameters(Parameter.ABBREV); Collection<String> abbrevs = new ArrayList<String>(); Iterator it = abbrevPars.iterator(); while (it.hasNext()) { Parameter par = (Parameter)it.next(); abbrevs.add(par.getValue()); } return new AbbreviatedValue(abbrevs, p.getValue()); }
/** * Replace any parameters of the same type with the one specified. * @param parameter parameter to add to this list in place of all others with the same name * @return true if successfully added to this list */ public final boolean replace(final Parameter parameter) { for (Parameter parameter1 : getParameters(parameter.getName())) { remove(parameter1); } return add(parameter); }
/** * Replace any parameters of the same type with the one specified. * @param parameter parameter to add to this list in place of all others with the same name * @return true if successfully added to this list */ public final boolean replace(final Parameter parameter) { for (Parameter parameter1 : getParameters(parameter.getName())) { remove(parameter1); } return add(parameter); }