add getObjects method with filter