filter constructor