private void mapAttributes() { attributeCount = 0; int orgAttCount = super.getAttributeCount(); if (orgAttCount > 0) { QName elementQName = super.getName(); ParseFilter filter = parserOptions.getParseFilter(); for (int i=0; i<orgAttCount; i++) { if (filter.acceptable(elementQName, super.getAttributeName(i))) { if (attributeCount == attributeMap.length) { int[] newAttributeMap = new int[attributeMap.length*2]; System.arraycopy(attributeMap, 0, newAttributeMap, 0, attributeMap.length); attributeMap = newAttributeMap; } attributeMap[attributeCount++] = i; } } } }
FOMStAXFilter(XMLStreamReader parent, ParserOptions parserOptions) { super(parent); this.parserOptions = parserOptions; if (parserOptions != null) { ParseFilter parseFilter = parserOptions.getParseFilter(); if (parseFilter != null) { ignoreWhitespace = parseFilter.getIgnoreWhitespace(); ignoreComments = parseFilter.getIgnoreComments(); ignorePI = parseFilter.getIgnoreProcessingInstructions(); attributeMap = new int[8]; } } resetEvent(); }
ParseFilter filter = parserOptions.getParseFilter(); if (filter != null && !filter.acceptable(super.getName())) { depthInSkipElement = 1;