KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > openbravo > xmlEngine > FunctionSubtractTemplate


1 /*
2  ************************************************************************************
3  * Copyright (C) 2001-2006 Openbravo S.L.
4  * Licensed under the Apache Software License version 2.0
5  * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6  * Unless required by applicable law or agreed to in writing, software distributed
7  * under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
8  * CONDITIONS OF ANY KIND, either express or implied. See the License for the
9  * specific language governing permissions and limitations under the License.
10  ************************************************************************************
11 */

12 package org.openbravo.xmlEngine;
13
14 import java.text.DecimalFormat JavaDoc;
15
16 import org.apache.log4j.Logger ;
17
18 class FunctionSubtractTemplate extends FunctionTemplate {
19
20   static Logger log4jFunctionSubtractTemplate = Logger.getLogger(FunctionSubtractTemplate.class);
21
22   public FunctionSubtractTemplate(String JavaDoc fieldName, DecimalFormat JavaDoc formatOutput, DecimalFormat JavaDoc formatSimple,
23       DataTemplate dataTemplate,
24       XmlComponentTemplate arg1, XmlComponentTemplate arg2) {
25     super(fieldName, formatOutput, formatSimple, dataTemplate, arg1, arg2);
26   }
27
28   public FunctionValue createFunctionValue(XmlDocument xmlDocument) {
29     FunctionValue functionValue = searchFunction(xmlDocument);
30     if (functionValue == null) {
31       log4jFunctionSubtractTemplate.info("New FunctionSubtractValue");
32       functionValue = new FunctionSubtractValue(this, xmlDocument);
33     }
34     return functionValue;
35   }
36
37 }
38
Popular Tags