Adding API call, and modifying handler to store and query handler state (timestamp).

Methods that change the state will have to update the m_ts variable.