added dependencies, and added a generic query method