Search in sources :

Example 1 with CoreNSUnawareAttribute

use of org.apache.axiom.core.CoreNSUnawareAttribute in project webservices-axiom by apache.

the class BuildableContext method processAttribute.

@Override
void processAttribute(String name, String value, String type, boolean specified) throws StreamException {
    if (passThroughHandler != null) {
        passThroughHandler.processAttribute(name, value, type, specified);
    } else {
        CoreNSUnawareAttribute attr = builderHandler.nodeFactory.createNode(CoreNSUnawareAttribute.class);
        attr.coreSetName(name);
        try {
            attr.coreSetCharacterData(value, null);
        } catch (CoreModelException ex) {
            throw new CoreModelStreamException(ex);
        }
        attr.coreSetType(type);
        attr.coreSetSpecified(specified);
        ((CoreElement) target).coreAppendAttribute(attr);
    }
}
Also used : CoreElement(org.apache.axiom.core.CoreElement) CoreModelException(org.apache.axiom.core.CoreModelException) CoreModelStreamException(org.apache.axiom.core.CoreModelStreamException) CoreNSUnawareAttribute(org.apache.axiom.core.CoreNSUnawareAttribute)

Aggregations

CoreElement (org.apache.axiom.core.CoreElement)1 CoreModelException (org.apache.axiom.core.CoreModelException)1 CoreModelStreamException (org.apache.axiom.core.CoreModelStreamException)1 CoreNSUnawareAttribute (org.apache.axiom.core.CoreNSUnawareAttribute)1