/* $Id: SpreadSelectionListIdentifierGrammarChecker.java 344 2011-09-08 13:43:20Z shayashi $ */
package smart_gs.spread_selection;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
//import java.io.*;


public class SpreadSelectionListIdentifierGrammarChecker {
	String sslIdDefString = "([A-z]|[^ -~¡-ß])([^ -~¡-ß]|[0-9]|[A-z]|[_\\-\\+=\\.&~:])+";

	private Pattern pattern;
	private Matcher matcher;

	public SpreadSelectionListIdentifierGrammarChecker() {
		 pattern = Pattern.compile(sslIdDefString);
	}
	
	public boolean checks(String string) {
		matcher = pattern.matcher(string);
		return matcher.matches();
	}
}
