move the cursor methods out of the library