WildcardMatchExpression expr = new WildcardMatchExpression(searchString); nameSearchMatches.clear(); Set keySet = nameToCallListMap.keySet(); Log.debug(LOG, "Searching for ", searchString, " in ", keySet); for ( Iterator i = keySet.iterator(); i.hasNext(); ) { String name = (String)i.next(); if ( expr.match(name) ) { Log.debug(LOG, "Search matches ", name); nameSearchMatches.add(name); } }
invalidateSearch();
	public void setNameSearchString(String newSearchString)	{		if ( newSearchString == null )			newSearchString = "";				if ( !newSearchString.equals(searchString) )		{			String oldSearchString = searchString;			searchString = newSearchString;			WildcardMatchExpression expr = new WildcardMatchExpression(searchString);			nameSearchMatches.clear();			Set keySet = nameToCallListMap.keySet();			Log.debug(LOG, "Searching for ", searchString, " in ", keySet);			for ( Iterator i = keySet.iterator(); i.hasNext(); )			{				String name = (String)i.next();				if ( expr.match(name) )				{					Log.debug(LOG, "Search matches ", name);					nameSearchMatches.add(name);				}			}			changeSupport.firePropertyChange(NAME_SEARCH_STRING_PROPERTY, oldSearchString, searchString);		}	}