1 16 package org.apache.cocoon.components.treeprocessor; 17 18 import org.apache.avalon.framework.configuration.Configurable; 19 import org.apache.avalon.framework.configuration.Configuration; 20 import org.apache.avalon.framework.configuration.ConfigurationException; 21 22 28 29 public class NamedContainerNodeBuilder extends ContainerNodeBuilder implements Configurable { 30 31 protected String nameAttr; 32 33 public void configure(Configuration config) throws ConfigurationException { 34 super.configure(config); 35 this.nameAttr = config.getChild("name-attribute").getValue("name"); 36 } 37 38 public ProcessingNode buildNode(Configuration config) throws Exception { 39 40 NamedContainerNode node = new NamedContainerNode(config.getAttribute(this.nameAttr)); 41 this.setupNode(node, config); 42 return node; 43 } 44 } 45 | Popular Tags |