Some refactoring, and add method reload()