Package com.hazelcast.config.matcher
Class MatchingPointConfigPatternMatcher
- java.lang.Object
-
- com.hazelcast.config.matcher.MatchingPointConfigPatternMatcher
-
- All Implemented Interfaces:
ConfigPatternMatcher
public class MatchingPointConfigPatternMatcher extends java.lang.Object implements ConfigPatternMatcher
ThisConfigPatternMatcher
supports a simplified wildcard matching. See "Config.md ## Using Wildcard" for details about the syntax options.In addition the candidates are weighted by the best match. The best result is returned. Throws
InvalidConfigurationException
is multiple configurations are found.
-
-
Constructor Summary
Constructors Constructor Description MatchingPointConfigPatternMatcher()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object o)
int
hashCode()
java.lang.String
matches(java.lang.Iterable<java.lang.String> configPatterns, java.lang.String itemName)
Returns the best match for an item name out of a list of configuration patterns.
-
-
-
Method Detail
-
matches
public java.lang.String matches(java.lang.Iterable<java.lang.String> configPatterns, java.lang.String itemName) throws InvalidConfigurationException
Description copied from interface:ConfigPatternMatcher
Returns the best match for an item name out of a list of configuration patterns.- Specified by:
matches
in interfaceConfigPatternMatcher
- Parameters:
configPatterns
- list of known configuration patternsitemName
- item name to match- Returns:
- a key of configPatterns which matches
the item name or
null
if there is no match - Throws:
InvalidConfigurationException
- if ambiguous configurations are found
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-