org.qtunes.core
Class ServiceMatcher

java.lang.Object
  extended by org.qtunes.core.util.AbstractMatcher<Service>
      extended by org.qtunes.core.ServiceMatcher
All Implemented Interfaces:
java.io.Serializable

public final class ServiceMatcher
extends AbstractMatcher<Service>

See Also:
Serialized Form

Constructor Summary
ServiceMatcher(java.lang.String filter)
           
 
Method Summary
 java.util.Map<java.lang.String,java.lang.String> getProperties()
           
 java.lang.Object getProperty(Service service, java.lang.String key)
          Return the specified Property from the source object being tested
 boolean test(java.lang.String key, java.lang.String op, java.lang.String testval, java.lang.Object propval)
          Compare two values
 
Methods inherited from class org.qtunes.core.util.AbstractMatcher
equals, getFilter, hashCode, isUniversal, matches, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ServiceMatcher

public ServiceMatcher(java.lang.String filter)
Method Detail

getProperty

public java.lang.Object getProperty(Service service,
                                    java.lang.String key)
Description copied from class: AbstractMatcher
Return the specified Property from the source object being tested

Specified by:
getProperty in class AbstractMatcher<Service>

test

public boolean test(java.lang.String key,
                    java.lang.String op,
                    java.lang.String testval,
                    java.lang.Object propval)
Description copied from class: AbstractMatcher
Compare two values

Overrides:
test in class AbstractMatcher<Service>
Parameters:
key - the key the values are stored under
op - the operation, one of "=", "!=", "<", ">", "<=", ">=", "=~" or "!~"
testval - the value specified in the test
propval - the property value that we're testing, as returned from AbstractMatcher.getProperty(E, java.lang.String)

getProperties

public java.util.Map<java.lang.String,java.lang.String> getProperties()