split paging api into files, added todo list
split some thread API functions into separate source files
split some thread API functions into separate source files