added the total matching algorithm

This algorithm is used to determine whether an entire string matches the
regular expression. Prefix matching, searching, and other related methods
will be added soon.