Home | History | Annotate | Download | only in calendarcommon2

Lines Matching defs:Parameter

237         private LinkedHashMap<String, ArrayList<Parameter>> mParamsMap =
238 new LinkedHashMap<String, ArrayList<Parameter>>();
284 * Adds a {@link Parameter} to this property.
285 * @param param The parameter that should be added.
287 public void addParameter(Parameter param) {
288 ArrayList<Parameter> params = mParamsMap.get(param.name);
290 params = new ArrayList<Parameter>();
297 * Returns the set of parameter names for this property.
298 * @return The set of parameter names for this property.
310 public List<Parameter> getParameters(String name) {
315 * Returns the first parameter with the specified name. May return
316 * nll if there is no such parameter.
317 * @param name The name of the parameter that should be returned.
318 * @return The first parameter with the specified name.
320 public Parameter getFirstParameter(String name) {
321 ArrayList<Parameter> params = mParamsMap.get(name);
343 for (Parameter param : getParameters(parameterName)) {
354 * A parameter defined for an iCalendar property.
357 public static class Parameter {
362 * Creates a new empty parameter.
364 public Parameter() {
368 * Creates a new parameter with the specified name and value.
369 * @param name The name of the parameter.
370 * @param value The value of the parameter.
372 public Parameter(String name, String value) {
385 * Helper method that appends this parameter to a StringBuilder.
510 Parameter parameter = null;
511 while ((parameter = extractParameter(state)) != null) {
512 property.addParameter(parameter);
538 * Extracts the next parameter from the line, if any. If there are no more
541 private static Parameter extractParameter(ParserState state)
545 Parameter parameter = null;
551 if (parameter != null) {
554 + "parameter in " + text);
556 parameter.value = text.substring(equalIndex + 1,
559 return parameter; // may be null
561 if (parameter != null) {
564 + "parameter in " + text);
566 parameter.value = text.substring(equalIndex + 1,
568 return parameter;
570 parameter = new Parameter();
575 if ((parameter == null) || (startIndex == -1)) {
579 parameter.name = text.substring(startIndex + 1, equalIndex);
581 if (parameter == null) {
582 throw new FormatException("Expected parameter before '\"' in " + text);
585 throw new FormatException("Expected '=' within parameter in " + text);
588 throw new FormatException("Parameter value cannot contain a '\"' in " + text);
594 parameter.value = text.substring(state.index + 1, endQuote);
596 return parameter;