KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > netbeans > modules > xslt > model > impl > OutputImpl


1 /*
2  * The contents of this file are subject to the terms of the Common Development
3  * and Distribution License (the License). You may not use this file except in
4  * compliance with the License.
5  *
6  * You can obtain a copy of the License at http://www.netbeans.org/cddl.html
7  * or http://www.netbeans.org/cddl.txt.
8  *
9  * When distributing Covered Code, include this CDDL Header Notice in each file
10  * and include the License file at http://www.netbeans.org/cddl.txt.
11  * If applicable, add the following below the CDDL Header, with the fields
12  * enclosed by brackets [] replaced by your own identifying information:
13  * "Portions Copyrighted [year] [name of copyright owner]"
14  *
15  * The Original Software is NetBeans. The Initial Developer of the Original
16  * Software is Sun Microsystems, Inc. Portions Copyright 1997-2007 Sun
17  * Microsystems, Inc. All Rights Reserved.
18  */

19 package org.netbeans.modules.xslt.model.impl;
20
21 import java.util.List JavaDoc;
22
23 import org.netbeans.modules.xslt.model.CharacterMap;
24 import org.netbeans.modules.xslt.model.Output;
25 import org.netbeans.modules.xslt.model.XslComponent;
26 import org.netbeans.modules.xslt.model.XslReference;
27 import org.netbeans.modules.xslt.model.XslVisitor;
28 import org.netbeans.modules.xslt.model.enums.Standalone;
29 import org.netbeans.modules.xslt.model.enums.TBoolean;
30 import org.w3c.dom.Element JavaDoc;
31
32
33 /**
34  * @author ads
35  *
36  */

37 class OutputImpl extends QNameableImpl implements Output {
38
39     OutputImpl( XslModelImpl model, Element JavaDoc element ) {
40         super( model , element );
41     }
42
43     OutputImpl( XslModelImpl model ) {
44         super( model , XslElements.OUTPUT );
45     }
46
47     /* (non-Javadoc)
48      * @see org.netbeans.modules.xslt.model.impl.XslComponentImpl#accept(org.netbeans.modules.xslt.model.XslVisitor)
49      */

50     @Override JavaDoc
51     public void accept( XslVisitor visitor )
52     {
53         visitor.visit( this );
54     }
55
56     /* (non-Javadoc)
57      * @see org.netbeans.modules.xslt.model.impl.XslComponentImpl#getComponentType()
58      */

59     @Override JavaDoc
60     public Class JavaDoc<? extends XslComponent> getComponentType()
61     {
62         return Output.class;
63     }
64
65     /* (non-Javadoc)
66      * @see org.netbeans.modules.xslt.model.EncodingSpec#getEncoding()
67      */

68     public String JavaDoc getEncoding() {
69         return getAttribute( XslAttributes.ENCODING );
70     }
71
72     /* (non-Javadoc)
73      * @see org.netbeans.modules.xslt.model.EncodingSpec#setEncoding(java.lang.String)
74      */

75     public void setEncoding( String JavaDoc encoding ) {
76         setAttribute( XslAttributes.ENCODING, encoding );
77     }
78
79     /* (non-Javadoc)
80      * @see org.netbeans.modules.xslt.model.IndentSpec#getIndent()
81      */

82     public TBoolean getIndent() {
83         return TBoolean.forString( getAttribute( XslAttributes.INDENT ) );
84     }
85
86     /* (non-Javadoc)
87      * @see org.netbeans.modules.xslt.model.IndentSpec#setIndent(org.netbeans.modules.xslt.model.enums.TBoolean)
88      */

89     public void setIndent( TBoolean value ) {
90         setAttribute( XslAttributes.INDENT, value );
91     }
92
93     /* (non-Javadoc)
94      * @see org.netbeans.modules.xslt.model.Output#getStandalone()
95      */

96     public Standalone getStandalone() {
97         return Standalone.forString( getAttribute( XslAttributes.STANDALONE ));
98     }
99
100     /* (non-Javadoc)
101      * @see org.netbeans.modules.xslt.model.Output#setStandalone(org.netbeans.modules.xslt.model.enums.Standalone)
102      */

103     public void setStandalone( Standalone value ) {
104         setAttribute( XslAttributes.STANDALONE, value );
105     }
106
107     /* (non-Javadoc)
108      * @see org.netbeans.modules.xslt.model.Output#getUndeclarePrefixes()
109      */

110     public TBoolean getUndeclarePrefixes() {
111         return TBoolean.forString( getAttribute( XslAttributes.UNDECLARE_PREFIXES));
112     }
113
114     /* (non-Javadoc)
115      * @see org.netbeans.modules.xslt.model.Output#setUndeclarePrefixes(org.netbeans.modules.xslt.model.enums.TBoolean)
116      */

117     public void setUndeclarePrefixes( TBoolean value ) {
118         setAttribute( XslAttributes.UNDECLARE_PREFIXES, value );
119     }
120
121     /* (non-Javadoc)
122      * @see org.netbeans.modules.xslt.model.UseCharacterMapsSpec#getUseCharacterMaps()
123      */

124     public List JavaDoc<XslReference<CharacterMap>> getUseCharacterMaps() {
125         return resolveGlobalReferenceList( CharacterMap.class,
126                 XslAttributes.USE_CHARACTER_MAPS );
127     }
128
129     /* (non-Javadoc)
130      * @see org.netbeans.modules.xslt.model.UseCharacterMapsSpec#setUseCharacterMaps(java.util.List)
131      */

132     public void setUseCharacterMaps( List JavaDoc<XslReference<CharacterMap>> list ) {
133         setAttribute( XslAttributes.USE_CHARACTER_MAPS, list );
134     }
135
136 }
137
Popular Tags