1 19 package org.netbeans.modules.xslt.model.impl; 20 21 import java.util.List ; 22 23 import javax.xml.namespace.QName ; 24 25 import org.netbeans.modules.xslt.model.ApplyTemplateChild; 26 import org.netbeans.modules.xslt.model.ApplyTemplates; 27 import org.netbeans.modules.xslt.model.XslComponent; 28 import org.netbeans.modules.xslt.model.XslVisitor; 29 import org.w3c.dom.Element ; 30 31 32 36 class ApplyTemplatesImpl extends SequenceElementImpl implements 37 ApplyTemplates 38 { 39 40 ApplyTemplatesImpl( XslModelImpl model, Element element ) { 41 super( model , element ); 42 } 43 44 ApplyTemplatesImpl( XslModelImpl model ) { 45 super( model , XslElements.APPLY_TEMPLATES); 46 } 47 48 51 @Override 52 public void accept( XslVisitor visitor ) 53 { 54 visitor.visit( this ); 55 } 56 57 60 @Override 61 public Class <? extends XslComponent> getComponentType() 62 { 63 return ApplyTemplates.class; 64 } 65 66 69 public void addChildElement( ApplyTemplateChild child, int position ) { 70 insertAtIndex( CHILD_ELEMENTS, child , position ); 71 } 72 73 76 public void appendChildElement( ApplyTemplateChild child ) { 77 appendChild( CHILD_ELEMENTS, child); 78 } 79 80 83 public List <ApplyTemplateChild> getChildrenElements() { 84 return getChildren( ApplyTemplateChild.class ); 85 } 86 87 90 public void removeChildElement( ApplyTemplateChild child ) { 91 removeChild( CHILD_ELEMENTS , child ); 92 } 93 94 97 public QName getMode() { 98 return QNameBuilder.createQName( this, XslAttributes.MODE ); 99 } 100 101 104 public void setMode( QName mode ) { 105 setAttribute( XslAttributes.MODE, mode ); 106 } 107 108 } 109 | Popular Tags |