Framework for creating queries based on method names