1 /*
2 * Copyright 2007 - 2007 JEuclid, http://jeuclid.sf.net
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16 package org.w3c.dom.mathml;
17
18 import org.w3c.dom.DOMException;
19
20 /*
21 * Please note: This file was automatically generated from the source of the
22 * MathML specification. Do not edit it. If there are errors or missing
23 * elements, please correct the stylesheet instead.
24 */
25
26 /**
27 * This interface supports the MathML Content elements that may contain child
28 * Content elements. The elements directly supported by MathMLContentContainer
29 * include: reln (deprecated), lambda, lowlimit, uplimit, degree,
30 * domainofapplication, and momentabout. Interfaces derived from
31 * MathMLContentContainer support the elements apply, fn, interval, condition,
32 * declare, bvar, set, list, vector, matrix, and matrixrow.
33 *
34 *
35 */
36 public interface MathMLContentContainer extends MathMLContentElement,
37 MathMLContainer {
38 /**
39 * The number of bvar child elements of this element.
40 *
41 * @return value of the nBoundVariables attribute.
42 */
43 int getNBoundVariables();
44
45 /**
46 * This attribute represents the condition child element of this node. See .
47 *
48 * @return value of the condition attribute.
49 */
50 MathMLConditionElement getCondition();
51
52 /**
53 * setter for the condition attribute.
54 *
55 * @param condition
56 * new value for condition.
57 * @see #getCondition()
58 * @throws DOMException
59 * HIERARCHY_REQUEST_ERR: Raised if this element does not
60 * permit a child condition element. In particular, raised if
61 * this element is not a apply, set, or list.
62 */
63 void setCondition(MathMLConditionElement condition);
64
65 /**
66 * This attribute represents the degree child element of this node. This
67 * expresses, for instance, the degree of differentiation if this element
68 * is a bvar child of an apply element whose first child is a diff or
69 * partialdiff. If this is an apply element whose first child is a
70 * partialdiff, the opDegree attribute, if present, represents the total
71 * degree of differentiation. See .
72 *
73 * @return value of the opDegree attribute.
74 */
75 MathMLElement getOpDegree();
76
77 /**
78 * setter for the opDegree attribute.
79 *
80 * @param opDegree
81 * new value for opDegree.
82 * @see #getOpDegree()
83 * @throws DOMException
84 * HIERARCHY_REQUEST_ERR: Raised if this element does not
85 * permit a child degree element. In particular, raised if
86 * this element is not a bvar or apply.
87 */
88 void setOpDegree(MathMLElement opDegree);
89
90 /**
91 * This attribute represents the domainofapplication child element of this
92 * node, if present. This may express, for instance, the domain of
93 * integration if this element is an apply element whose first child is an
94 * integral operator (int). See .
95 *
96 * @return value of the domainOfApplication attribute.
97 */
98 MathMLElement getDomainOfApplication();
99
100 /**
101 * setter for the domainOfApplication attribute.
102 *
103 * @param domainOfApplication
104 * new value for domainOfApplication.
105 * @see #getDomainOfApplication()
106 * @throws DOMException
107 * HIERARCHY_REQUEST_ERR: Raised if this element does not
108 * permit a child domainofapplication element.
109 */
110 void setDomainOfApplication(MathMLElement domainOfApplication);
111
112 /**
113 * This attribute represents the momentabout child element of this node,
114 * if present. This typically expresses the point about which a
115 * statistical moment is to be calculated, if this element is an apply
116 * element whose first child is a moment. See .
117 *
118 * @return value of the momentAbout attribute.
119 */
120 MathMLElement getMomentAbout();
121
122 /**
123 * setter for the momentAbout attribute.
124 *
125 * @param momentAbout
126 * new value for momentAbout.
127 * @see #getMomentAbout()
128 * @throws DOMException
129 * HIERARCHY_REQUEST_ERR: Raised if this element does not
130 * permit a child momentabout element. In particular, raised
131 * if this element is not an apply whose first child is a
132 * moment.
133 */
134 void setMomentAbout(MathMLElement momentAbout);
135
136 /**
137 * This method retrieves the index-th MathMLBvarElement child of the
138 * MathMLElement. Note that only bvar child elements are counted in
139 * determining the index-th bound variable.
140 *
141 * @param index
142 * The one-based index into the bound variable children of this
143 * element of the MathMLBvarElement to be retrieved.
144 * @return The MathMLBvarElement representing the index-th bvar child of
145 * this element.
146 */
147 MathMLBvarElement getBoundVariable(int index);
148
149 /**
150 * This method inserts a MathMLBvarElement as a child node before the
151 * current index-th bound variable child of this MathMLElement. If index
152 * is 0, newBVar is appended as the last bound variable child. This has
153 * the effect of adding a bound variable to the expression this element
154 * represents. Note that the new bound variable is inserted as the
155 * index-th bvar child node, not necessarily as the index-th child node.
156 * The point of the method is to allow insertion of bound variables
157 * without requiring the caller to calculate the exact order of child
158 * qualifier elements.
159 *
160 * @param newBVar
161 * A MathMLBvarElement representing the bvar element being
162 * added.
163 * @param index
164 * The one-based index into the bound variable children of this
165 * element before which newBVar is to be inserted.
166 * @return The MathMLBvarElement being added.
167 * @throws DOMException
168 * HIERARCHY_REQUEST_ERR: Raised if this element does not
169 * permit child bvar elements.
170 */
171 MathMLBvarElement insertBoundVariable(MathMLBvarElement newBVar, int index)
172 throws DOMException;
173
174 /**
175 * This method sets the index-th bound variable child of this
176 * MathMLElement to newBVar. This has the effect of setting a bound
177 * variable in the expression this element represents. Note that the new
178 * bound variable is inserted as the index-th bvar child node, not
179 * necessarily as the index-th child node. The point of the method is to
180 * allow insertion of bound variables without requiring the caller to
181 * calculate the exact order of child qualifier elements. If there is
182 * already a bvar at the index-th position, it is replaced by newBVar.
183 *
184 * @param newBVar
185 * The new MathMLBvarElement child of this element being set.
186 * @param index
187 * The one-based index into the bound variable children of this
188 * element at which newBVar is to be inserted.
189 * @return The MathMLBvarElement being set.
190 * @throws DOMException
191 * HIERARCHY_REQUEST_ERR: Raised if this element does not
192 * permit child bvar elements.
193 */
194 MathMLBvarElement setBoundVariable(MathMLBvarElement newBVar, int index)
195 throws DOMException;
196
197 /**
198 * This method deletes the index-th MathMLBvarElement child of the
199 * MathMLElement. This has the effect of removing this bound variable from
200 * the list of qualifiers affecting the element this represents.
201 *
202 * @param index
203 * The one-based index into the bound variable children of this
204 * element of the MathMLBvarElement to be removed.
205 */
206 void deleteBoundVariable(int index);
207
208 /**
209 * This method removes the index-th MathMLBvarElement child of the
210 * MathMLElement and returns it to the caller. This has the effect of
211 * removing this bound variable from the list of qualifiers affecting the
212 * element this represents.
213 *
214 * @param index
215 * The one-based index into the bound variable children of this
216 * element of the MathMLBvarElement to be removed.
217 * @return The MathMLBvarElement being removed.
218 */
219 MathMLBvarElement removeBoundVariable(int index);
220 };