Use functional style in SimpleRelationFilter