Turned the crawler into a class so it can be used more easily by client code