{"action":"created","issue":{"url":"https://api.github.com/repos/ajgilbert/ICHiggsTauTau/issues/94","labels_url":"https://api.github.com/repos/ajgilbert/ICHiggsTauTau/issues/94/labels{/name}","comments_url":"https://api.github.com/repos/ajgilbert/ICHiggsTauTau/issues/94/comments","events_url":"https://api.github.com/repos/ajgilbert/ICHiggsTauTau/issues/94/events","html_url":"https://github.com/ajgilbert/ICHiggsTauTau/pull/94","id":109501208,"number":94,"title":"Adding complex filter module","user":{"login":"pjdunne","id":4669927,"avatar_url":"https://avatars.githubusercontent.com/u/4669927?v=3","gravatar_id":"","url":"https://api.github.com/users/pjdunne","html_url":"https://github.com/pjdunne","followers_url":"https://api.github.com/users/pjdunne/followers","following_url":"https://api.github.com/users/pjdunne/following{/other_user}","gists_url":"https://api.github.com/users/pjdunne/gists{/gist_id}","starred_url":"https://api.github.com/users/pjdunne/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pjdunne/subscriptions","organizations_url":"https://api.github.com/users/pjdunne/orgs","repos_url":"https://api.github.com/users/pjdunne/repos","events_url":"https://api.github.com/users/pjdunne/events{/privacy}","received_events_url":"https://api.github.com/users/pjdunne/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-10-02T14:26:57Z","updated_at":"2015-10-02T14:54:32Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/ajgilbert/ICHiggsTauTau/pulls/94","html_url":"https://github.com/ajgilbert/ICHiggsTauTau/pull/94","diff_url":"https://github.com/ajgilbert/ICHiggsTauTau/pull/94.diff","patch_url":"https://github.com/ajgilbert/ICHiggsTauTau/pull/94.patch"},"body":"Adding a module which can filter an object collection using information held in a different object, e.g. the event info.\r\n\r\nIt takes two function predicates one which returns a bool and has two parameters of types A and B and another predicate which returns type B and has one parameter of type C.\r\n\r\nThe use case implemented in HiggsNuNu is getting the jet_rho (which is a double) from the EventInfo, and using it as an input to the PhotonID functions."},"comment":{"url":"https://api.github.com/repos/ajgilbert/ICHiggsTauTau/issues/comments/145050210","html_url":"https://github.com/ajgilbert/ICHiggsTauTau/pull/94#issuecomment-145050210","issue_url":"https://api.github.com/repos/ajgilbert/ICHiggsTauTau/issues/94","id":145050210,"user":{"login":"ajgilbert","id":1001931,"avatar_url":"https://avatars.githubusercontent.com/u/1001931?v=3","gravatar_id":"","url":"https://api.github.com/users/ajgilbert","html_url":"https://github.com/ajgilbert","followers_url":"https://api.github.com/users/ajgilbert/followers","following_url":"https://api.github.com/users/ajgilbert/following{/other_user}","gists_url":"https://api.github.com/users/ajgilbert/gists{/gist_id}","starred_url":"https://api.github.com/users/ajgilbert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ajgilbert/subscriptions","organizations_url":"https://api.github.com/users/ajgilbert/orgs","repos_url":"https://api.github.com/users/ajgilbert/repos","events_url":"https://api.github.com/users/ajgilbert/events{/privacy}","received_events_url":"https://api.github.com/users/ajgilbert/received_events","type":"User","site_admin":false},"created_at":"2015-10-02T14:54:32Z","updated_at":"2015-10-02T14:54:32Z","body":"I was thinking more a Module that can be constructed like this:\r\n\r\n~~~cpp\r\nGenericModule(\"GenericModule\")\r\n    .set_event_function([](ic::TreeEvent *evt) {\r\n        auto & x = evt->GetPtrVec(\"blah\");\r\n        auto & y = evt->GetPtr(\"blah2\");\r\n        ic::erase_if(x, [](XType *z) { return SomeFunc(z, y); });\r\n        return 0;\r\n    });\r\n~~~\r\nIt would be a way of quickly creating a completely generic module that does not require any persistent state, i.e. not needed class members, and so not needed a full class to implement."}}