Extracted base class from RestQuery and RestQueryProvider to share some boilerplate code with query provider for extended resources in the future.