Modifier and Type | Field and Description |
---|---|
protected java.lang.String |
name
The element name
|
protected Namespace |
namespace
The element namespace
|
Constructor and Description |
---|
ElementFilter()
Filter out the Elements.
|
ElementFilter(Namespace namespace)
Filter out the Elements with the supplied Namespace.
|
ElementFilter(java.lang.String name)
Filter out the Elements with the supplied name in any Namespace.
|
ElementFilter(java.lang.String name,
Namespace namespace)
Filter out the Elements with the supplied name and Namespace.
|
Modifier and Type | Method and Description |
---|---|
boolean |
canAdd(java.lang.Object obj)
Only allow the adding of Element objects.
|
boolean |
canRemove(java.lang.Object obj)
Check to see if the object can be removed from the list.
|
boolean |
equals(java.lang.Object obj)
Returns true if object is instance of ElementFilter and has
the same parent Element, name, and namespace as this filter.
|
boolean |
matches(java.lang.Object obj)
Check to see if the object matches a predefined set of rules.
|
protected java.lang.String name
protected Namespace namespace
public ElementFilter()
Filter out the Elements.
public ElementFilter(java.lang.String name)
Filter out the Elements with the supplied name in any Namespace.
name
- The name of the Element.public ElementFilter(Namespace namespace)
Filter out the Elements with the supplied Namespace.
namespace
- The namespace the Element lives in.public ElementFilter(java.lang.String name, Namespace namespace)
Filter out the Elements with the supplied name and Namespace.
name
- The name of the Element.namespace
- The namespace the Element lives in.public boolean canAdd(java.lang.Object obj)
Only allow the adding of Element objects.
canAdd
in interface Filter
obj
- The object to verify.true
if the object can be added.IllegalAddException
- if the object can be added.public boolean canRemove(java.lang.Object obj)
Check to see if the object can be removed from the list.
public boolean matches(java.lang.Object obj)
Check to see if the object matches a predefined set of rules.
public boolean equals(java.lang.Object obj)
Returns true if object is instance of ElementFilter and has the same parent Element, name, and namespace as this filter.
equals
in class java.lang.Object
true
if the Filters are equalCopyright (c) 2017 Software AG. All Rights Reserved.