if ((effective & desired) != desired) {
return false;
}
/* Get our filter */
Filter f = filter;
if (f == null) {
// it's "*"
return true;
}
/* is requested a wildcard filter? */
if (requested.subsystem == null) {
return false;
}
Map<String, Object> requestedProperties = requested.getProperties();
if (requestedProperties == null) {
/*
* If the requested properties are null, then we have detected a
* recursion getting the subsystem location. So we return true to
* permit the subsystem location request in the SubsystemPermission
* check up the stack to succeed.
*/
return true;
}
return f.matches(requestedProperties);
}