class UserSearchUtils {

	public static Pattern createStartsWithPattern(String input, boolean allowGlobbing,
			int options) {

		Pattern wildCardPattern = createSingleStarPattern(input, allowGlobbing, options);
		if (wildCardPattern != null) {
			return wildCardPattern;
		}

		String converted = convertUserInputToRegex(input, allowGlobbing);
		Pattern p = Pattern.compile(converted + ".*", options);
		return p;
	}

}