private void handleStartProperty() { confName = null; confValue = null; confFinal = false; confTag = null; confSource.clear(); // First test for short format configuration int attrCount = reader.getAttributeCount(); for (int i = 0; i < attrCount; i++) { String propertyAttr = reader.getAttributeLocalName(i); if ("name".equals(propertyAttr)) { confName = StringInterner.weakIntern( reader.getAttributeValue(i)); } else if ("value".equals(propertyAttr)) { confValue = StringInterner.weakIntern( reader.getAttributeValue(i)); } else if ("final".equals(propertyAttr)) { confFinal = "true".equals(reader.getAttributeValue(i)); } else if ("source".equals(propertyAttr)) { confSource.add(StringInterner.weakIntern( reader.getAttributeValue(i))); } else if ("tag".equals(propertyAttr)) { confTag = StringInterner .weakIntern(reader.getAttributeValue(i)); } } }
List<ParsedItem> items; for (int i = 0; i < attrCount; i++) { String attrName = reader.getAttributeLocalName(i); if ("href".equals(attrName)) { confInclude = reader.getAttributeValue(i);
public void writeAttribute(XMLStreamReader2 reader, XMLStreamWriter2 writer, int i, String value) throws XMLStreamException { String ns = reader.getAttributeNamespace(i); String nsPrefix = reader.getAttributePrefix(i); if(ns != null && nsPrefix != null) { writer.writeAttribute(nsPrefix, ns, reader.getAttributeLocalName(i), value); // xmlns } else if(nsPrefix != null && !nsPrefix.isEmpty()){ writer.writeAttribute(nsPrefix + ':' + reader.getAttributeLocalName(i), value); } else { writer.writeAttribute(reader.getAttributeLocalName(i), value); } }
/** * Method that can be called when this cursor points to START_ELEMENT, * and returns local name * of the attribute at specified index. * Index has to be between [0, {@link #getAttrCount}[; otherwise * {@link IllegalArgumentException} will be thrown. * * @param index Index of the attribute * * @throws XMLStreamException if either the underlying parser has * problems (cursor not valid or not pointing to START_ELEMENT), * or if invalid attribute * @throws IllegalArgumentException if attribute index is invalid * (less than 0 or greater than the last valid index * [getAttributeCount()-1]) */ public String getAttrLocalName(int index) throws XMLStreamException { if (!readerAccessible()) { throw _notAccessible("getAttrLocalName"); } return _streamReader.getAttributeLocalName(index); }
/** * Method that can be called when this cursor points to START_ELEMENT, * and returns local name * of the attribute at specified index. * Index has to be between [0, {@link #getAttrCount}[; otherwise * {@link IllegalArgumentException} will be thrown. * * @param index Index of the attribute * * @throws XMLStreamException if either the underlying parser has * problems (cursor not valid or not pointing to START_ELEMENT), * or if invalid attribute * @throws IllegalArgumentException if attribute index is invalid * (less than 0 or greater than the last valid index * [getAttributeCount()-1]) */ public String getAttrLocalName(int index) throws XMLStreamException { if (!readerAccessible()) { throw _notAccessible("getAttrLocalName"); } return _streamReader.getAttributeLocalName(index); }
for(int i = 0; i < numAttributes; i++) String localName = xmlStreamReader.getAttributeLocalName(i); switch(localName)
for(int i = 0; i < numAttributes; i++) String localName = xmlStreamReader.getAttributeLocalName(i); switch(localName)
for(int i = 0; i < numAttributes; i++) String localName = xmlStreamReader.getAttributeLocalName(i); switch(localName)
for(int i = 0; i < numAttributes; i++) String localName = xmlStreamReader.getAttributeLocalName(i); switch(localName)
for(int i = 0; i < numAttributes; i++) String localName = xmlStreamReader.getAttributeLocalName(i); switch(localName)
for(int i = 0; i < numAttributes; i++) String localName = xmlStreamReader.getAttributeLocalName(i); switch(localName)
String attr = xmlReader.getAttributeLocalName(i); if(attr.equals("lang")) { lang = xmlReader.getAttributeValue(i);
ln = sr.getAttributeLocalName(i); if (nsAware) { String prefix = sr.getAttributePrefix(i);
ln = sr.getAttributeLocalName(i); if (nsAware) { String prefix = sr.getAttributePrefix(i);
for(int i = 0; i < numAttributes; i++) String localName = xmlStreamReader.getAttributeLocalName(i); switch(localName)
_localName = _xmlReader.getAttributeLocalName(_nextAttributeIndex); _namespaceURI = _xmlReader.getAttributeNamespace(_nextAttributeIndex); _textValue = _xmlReader.getAttributeValue(_nextAttributeIndex);
if(matchXPath(reader.getAttributeLocalName(i), attribute)) { writeAttribute(reader, writer, i, CharArrayFilter.FILTER_ANONYMIZE_MESSAGE); } else {
_localName = _xmlReader.getAttributeLocalName(_nextAttributeIndex); _namespaceURI = _xmlReader.getAttributeNamespace(_nextAttributeIndex); _textValue = _xmlReader.getAttributeValue(_nextAttributeIndex);
_localName = _xmlReader.getAttributeLocalName(_nextAttributeIndex); _namespaceURI = _xmlReader.getAttributeNamespace(_nextAttributeIndex); _textValue = _xmlReader.getAttributeValue(_nextAttributeIndex);