KickJava   Java API By Example, From Geeks To Geeks.

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


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 /**
15   A class with the elements of the estack of the elements of the XML template.
16
17  **/

18
19 class StackElement {
20   String JavaDoc strName;
21   boolean isSection;
22   boolean skipCharacters;
23   SectionTemplate previousSection;
24   boolean printEnabled = true;
25
26   public StackElement(String JavaDoc strName) {
27     this.strName = strName;
28     this.isSection = false;
29     this.skipCharacters = false;
30   }
31
32   public void setSection (SectionTemplate previousSection) {
33     isSection = true;
34     this.previousSection = previousSection;
35   }
36
37   public boolean isSection () {
38     return isSection;
39   }
40
41   public String JavaDoc name () {
42     return strName;
43   }
44
45   public SectionTemplate section () {
46     return previousSection;
47   }
48
49   public void setSkipCharacters() {
50     this.skipCharacters = true;
51   }
52
53   public boolean skipCharacters() {
54     return skipCharacters;
55   }
56
57   public void setPrintEnabled(boolean printEnabled) {
58     this.printEnabled = printEnabled;
59   }
60
61   public boolean printEnabled() {
62     return printEnabled;
63   }
64
65 }
66
Popular Tags