FileDocCategorySizeDatePackage
SetContextPropertiesRule.javaAPI DocGlassfish v2 API3343Fri May 04 22:32:30 BST 2007org.apache.catalina.startup

SetContextPropertiesRule

public class SetContextPropertiesRule extends com.sun.org.apache.commons.digester.Rule
Rule that uses the introspection utils to set properties of a context (everything except "path").
author
Remy Maucherat

Fields Summary
Constructors Summary
Methods Summary
public voidbegin(java.lang.String namespace, java.lang.String nameX, org.xml.sax.Attributes attributes)
Handle the beginning of an XML element.

param
attributes The attributes of this element
exception
Exception if a processing error occurs


        for (int i = 0; i < attributes.getLength(); i++) {
            String name = attributes.getLocalName(i);
            if ("".equals(name)) {
                name = attributes.getQName(i);
            }
            if ("path".equals(name)) { 
                continue;
            }
            String value = attributes.getValue(i);
            IntrospectionUtils.setProperty(digester.peek(), name, value);
        }