public class LargeAttributeMap extends java.lang.Object implements AttributeMap
Constructor and Description |
---|
LargeAttributeMap(java.util.List<AttributeInfo> atts) |
Modifier and Type | Method and Description |
---|---|
java.util.ArrayList<AttributeInfo> |
asList()
Get the contents of the AttributeMap as a list of
AttributeInfo objects. |
AttributeInfo |
get(NodeName name)
Get the attribute with a given name, if it exists
|
AttributeInfo |
get(java.lang.String uri,
java.lang.String local)
Get the attribute with a given name, if it exists
|
AttributeInfo |
getByFingerprint(int fingerprint,
NamePool namePool) |
java.util.Iterator<AttributeInfo> |
iterator() |
AttributeMap |
put(AttributeInfo att)
Replace or add an attribute, to create a new AttributeMap
|
AttributeMap |
remove(NodeName name)
Remove an existing attribute, to create a new AttributeMap
|
int |
size()
Return the number of attributes in the map.
|
java.lang.String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
public LargeAttributeMap(java.util.List<AttributeInfo> atts)
public int size()
size
in interface AttributeMap
public AttributeInfo get(NodeName name)
AttributeMap
get
in interface AttributeMap
name
- the name of the required attributepublic AttributeInfo get(java.lang.String uri, java.lang.String local)
AttributeMap
get
in interface AttributeMap
uri
- the namespace part of the name of the required attributelocal
- the local part of the name of the required attributepublic AttributeInfo getByFingerprint(int fingerprint, NamePool namePool)
getByFingerprint
in interface AttributeMap
public AttributeMap put(AttributeInfo att)
AttributeMap
put
in interface AttributeMap
att
- the attribute to be added or replacedpublic AttributeMap remove(NodeName name)
AttributeMap
remove
in interface AttributeMap
name
- the name of the attribute to be removed (if it exists)public java.util.Iterator<AttributeInfo> iterator()
iterator
in interface java.lang.Iterable<AttributeInfo>
public java.util.ArrayList<AttributeInfo> asList()
AttributeMap
AttributeInfo
objects.
The order of the returned list must be consistent with document order, with
the order of the attribute axis, and with position-based retrieval of individual
AttributeInfo
objects; multiple calls are not required to return the
same list, but they must be consistent in their ordering.
Modifying the returned list has no effect on the AttributeMap
asList
in interface AttributeMap
public java.lang.String toString()
toString
in class java.lang.Object
Copyright (c) 2004-2022 Saxonica Limited. All rights reserved.