Qwylt

java.lang.module.spi.query
Class AttributeExists

java.lang.Object
  extended by java.lang.module.ModuleQuery
      extended by java.lang.module.spi.query.AttributeExists
All Implemented Interfaces:
java.lang.Iterable<ModuleQuery>, Matcher<ModuleArchive>
Direct Known Subclasses:
AttributeEquals

public class AttributeExists
extends ModuleQuery

A ModuleQuery that tests whether or not a given attribute exists in a ModuleArchive.

Since:
Dec 12, 2008
Author:
Bryan Atsatt

Field Summary
 
Fields inherited from class java.lang.module.ModuleQuery
ANY, NONE
 
Constructor Summary
AttributeExists(java.lang.String attributeName)
          Constructor.
 
Method Summary
 java.lang.String getAttributeName()
          Returns the attribute name.
 boolean matches(ModuleArchive target)
          Tests if the specified target matches this instance.
 java.lang.String toString()
          Returns a string representation of this instance.
 
Methods inherited from class java.lang.module.ModuleQuery
addTo, addTo, and, and, any, asList, attributeEquals, attributeExists, exports, exportsPackage, exportsPackage, find, find, findIndexable, instanceOf, iterator, moduleNameAndVersionMatch, moduleNameEquals, not, not, or, or, versionMatches
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AttributeExists

public AttributeExists(java.lang.String attributeName)
Constructor.

Parameters:
attributeName - The attribute name to check for.
Method Detail

getAttributeName

public java.lang.String getAttributeName()
Returns the attribute name.

Returns:
The attribute name.

matches

public boolean matches(ModuleArchive target)
Tests if the specified target matches this instance.

Specified by:
matches in interface Matcher<ModuleArchive>
Specified by:
matches in class ModuleQuery
Parameters:
target - The target instance.
Returns:
true if the specified target matches this instance; false otherwise.

toString

public java.lang.String toString()
Returns a string representation of this instance.

Overrides:
toString in class java.lang.Object
Returns:
The string.

Qwylt

Send comments or questions to Bryan Atsatt