CORAL-137: moved integrity check from constructor to buildQuery method
to cyclic dependency: resource class -> handler -> declared attributes
-> resource class