com.bagri.server.hazelcast.predicate.PropertyPredicate Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of bagri-server-hazelcast Show documentation
Show all versions of bagri-server-hazelcast Show documentation
Bagri DB Cache: Hazelcast implementation
The newest version!
package com.bagri.server.hazelcast.predicate;
import java.util.Map;
import java.util.Properties;
import com.hazelcast.query.Predicate;
public class PropertyPredicate implements Predicate {
private String pName;
private String pValue;
public PropertyPredicate() {
//
}
public PropertyPredicate(String pName, String pValue) {
this.pName = pName;
this.pValue = pValue;
}
@Override
public boolean apply(Map.Entry mapEntry) {
Properties props = mapEntry.getValue();
String prop = props.getProperty(pName);
return prop != null && prop.equals(pValue);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy