this.regEx = regEx;
this.pattern = pattern;
    public FindRegExCmd(HiViewer model, String regEx, int index)    {        if (model == null)            throw new IllegalArgumentException("No model.");        if (regEx == null)            throw new IllegalArgumentException("No regular expression.");        if (!checkIndex(index))            throw new IllegalArgumentException("Search index not valid.");        this.model = model;        this.regEx = regEx;        this.index = index;    }