Package org.openl.rules.cmatch.matcher
Class BooleanPrimitiveMatch
- java.lang.Object
-
- org.openl.rules.cmatch.matcher.BooleanPrimitiveMatch
-
- All Implemented Interfaces:
IMatcher,IMatcherBuilder
public class BooleanPrimitiveMatch extends Object implements IMatcherBuilder, IMatcher
-
-
Field Summary
-
Fields inherited from interface org.openl.rules.cmatch.matcher.IMatcherBuilder
OP_MATCH, OP_MAX, OP_MIN
-
-
Constructor Summary
Constructors Constructor Description BooleanPrimitiveMatch()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ObjectfromString(String checkValue)Parse matching object from string.IMatchergetInstanceIfSupports(IOpenClass type)Get instance of matcher for a given type.StringgetName()Get name of match operation.booleanmatch(Object var, Object checkValue)Check whether actual value and check value are match or satisfy matching operation.
-
-
-
Method Detail
-
fromString
public Object fromString(String checkValue)
Description copied from interface:IMatcherParse matching object from string.Note that type of return value can depend on format of checkValue. For example, it can be Integer or IntRange.
- Specified by:
fromStringin interfaceIMatcher- Parameters:
checkValue- string value of a cell- Returns:
- matching value
-
getInstanceIfSupports
public IMatcher getInstanceIfSupports(IOpenClass type)
Description copied from interface:IMatcherBuilderGet instance of matcher for a given type.It can create new instance of the matcher each time or return *itself* if one matcher is enough. It is useful for enums and e.t.c
- Specified by:
getInstanceIfSupportsin interfaceIMatcherBuilder- Parameters:
type- variable's class- Returns:
- null if type is not supported; or instance of a matcher
-
getName
public String getName()
Description copied from interface:IMatcherBuilderGet name of match operation.- Specified by:
getNamein interfaceIMatcherBuilder- Returns:
- name of operation
-
-