Ejemplo n.º 1
0
  /**
   * Construct an operation within the given list as its owner and initialize all the elements with
   * the given values, which are a string encoding of those elements. All elements are enabled at
   * the beginning.
   *
   * @param owner The list as the owner of the constructed GTIngredientList.
   * @param values The string encoding of the values of the elements.
   */
  public RenameOperation(GTIngredientList owner, String values) {
    super(owner, 1);

    NamedObj container = owner.getOwner().getContainer();
    _name = new PtolemyExpressionString(container, "");
    setValues(values);
  }
  /**
   * Construct an operation within the given list as its owner and with the given value to each of
   * its elements..
   *
   * @param owner The list as the owner of the constructed GTIngredientList.
   * @param attributeName Value of the attributeName element.
   * @param attributeClass Value of the attributeClass element.
   * @param attributeValue Value of the attributeValue element.
   */
  public DynamicAttributeOperation(
      GTIngredientList owner, String attributeName, String attributeClass, String attributeValue) {
    super(owner, 3);

    NamedObj container = owner.getOwner().getContainer();
    _attributeName = new PtolemyExpressionString(container, attributeName);
    _attributeClass = attributeClass;
    _attributeValue = new PtolemyExpressionString(container, attributeValue);
  }