public Map<Object, MutableInt> match(CharSequence text){
		Map<Object, MutableInt> result = null;
		if (text != null && text.length() > 0){
			int i = 0;
			while (i < text.length()){
				Object o = matcher.match(text, i);
				if (o == null){
					i ++;
				}else{
					KeywordDefinition keyword = (KeywordDefinition) o;
					String word = keyword.getKeyword();
					Object attachment = keyword.getAttachement();
					i += word.length();
					if (result == null){
						result = new HashMap<Object, MutableInt>(); 
					}
					if (result.containsKey(attachment)){
						result.get(attachment).increment();
					}else{
						result.put(attachment, new MutableInt(1));
					}
				}
			}
		}
		return result;
	}
public Map < Object , MutableInt > match ( CharSequence text ) { Map < Object , MutableInt > result = null ; if ( text != null && text . length ( ) > 0 ) { int i = 0 ; while ( i < text . length ( ) ) { Object o = matcher . match ( text , i ) ; if ( o == null ) { i ++ ; } else { KeywordDefinition keyword = ( KeywordDefinition ) o ; String word = keyword . getKeyword ( ) ; Object attachment = keyword . getAttachement ( ) ; i += word . length ( ) ; if ( result == null ) { result = new HashMap < Object , MutableInt > ( ) ; } if ( result . containsKey ( attachment ) ) { result . get ( attachment ) . increment ( ) ; } else { result . put ( attachment , new MutableInt ( 1 ) ) ; } } } } return result ; }
Do the matching test, find out which keywords can be matched, and how many occurrences of each
keyword can be found.<br>
进行匹配，返回所匹配上的关键词，以及匹配的次数。

@param text 	the text string to be tested<br>待匹配的文本
@return	For all the keywords that can be found in the text, return their attachments (as the Key
in the Map) and occurrences count (as the Value in the Map).<br>
返回匹配上的全部关键词所对应的attachment（在Map的Key中），以及它们出现的次数（在Map的Value中）。