form.addField("e", tf);
// regular expressions
tf = new TextField("A field, must match the regular expression a.*b.*c");
tf.addValidator(new RegexpValidator("a.*b.*c",
"{0} does not match the regular expression"));
tf.setValue("aagsabeqgc");
form.addField("f", tf);
tf = new TextField(
"A field, must contain the regular expression a.*b.*c");
tf.addValidator(new RegexpValidator("a.*b.*c", false,
"{0} does not contain the regular expression"));
tf.setValue("aagsabeqgc");
form.addField("g", tf);
tf = new TextField(
"A field, must match the regular expression ^a.*b.*c$");
tf.addValidator(new RegexpValidator("^a.*b.*c$", false,
"{0} does not match the regular expression with ^ and $"));
tf.setValue("aagsabeqgc");
form.addField("h", tf);
tf = new TextField(
"A field, must contain the regular expression ^a.*b.*c$");
tf.addValidator(new RegexpValidator("^a.*b.*c$", false,
"{0} does not contain the regular expression with ^ and $"));
tf.setValue("aagsabeqgc");
form.addField("i", tf);
// TODO CompositeValidator