base class for searching