1 package fr.ove.openmath.jome.model;
2
3 import java.util.*;
4 import fr.ove.openmath.jome.model.*;
5 import fr.ove.openmath.jome.model.events.ModelEvent;
6
7 /***
8 * The substitution model of the symbol, with the same name, in the Mfd2 cd.
9 *
10 * @author © 1999 DIRAT Laurent
11 * @version 2.0 28/10/1999
12 */
13 public class Mfd2Substitution extends Function {
14 /***
15 * Inserts the instance in the formula tree structure.<BR>
16 * @param current the position in the formula tree where the operator is to be insert.
17 * @return the new current position int hte formula tree.
18 */
19 public FormulaTreeStructure insert(FormulaTreeStructure current) {
20
21
22
23
24
25 current = super.insert(current);
26
27 return (new Mfd2SubstitutionElement()).insert(current);
28 }
29
30 /***
31 * Adds a new SubstitutionElement to the end of the list.
32 * Returns the new element.
33 */
34 public FormulaTreeStructure addElement() {
35
36 FormulaTreeStructure current = super.addElement();
37 return (new Mfd2SubstitutionElement()).insert(current);
38 }
39 }