/**
   * Get all parameter sets.
   *
   * @return All parameter sets.
   */
  public IParameterSet[] getParameterSets() {
    IParameterSet[] ret;

    Collection paramsets =
        getState()
            .getAttributeValues(getRPlan(), OAVBDIRuntimeModel.parameterelement_has_parametersets);
    if (paramsets != null) {
      ret = new IParameterSet[paramsets.size()];
      int i = 0;
      for (Iterator it = paramsets.iterator(); it.hasNext(); i++) {
        Object paramset = it.next();
        String name =
            (String) getState().getAttributeValue(paramset, OAVBDIMetaModel.modelelement_has_name);
        ret[i] =
            ParameterSetFlyweight.getParameterSetFlyweight(
                getState(), getScope(), paramset, name, getRPlan());
      }
    } else {
      ret = new IParameterSet[0];
    }
    return ret;
  }
 /**
  * Get a parameter.
  *
  * @param name The name.
  * @return The parameter set.
  */
 public IParameterSet getParameterSet(String name) {
   return ParameterSetFlyweight.getParameterSetFlyweight(state, rcapa, null, name, rplan);
 }