-
Notifications
You must be signed in to change notification settings - Fork 432
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add returns filter #1853
Add returns filter #1853
Conversation
filters/ReturnsFilter.cpp
Outdated
onlyView->appendPoint(*inView.get(), idx); | ||
} | ||
|
||
if (firstView->size()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems like if you've asked for certain sets, you should get them, regardless of whether they're empty or not. I think this will omit the intermediate view, even if you've asked for it, as an example.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm happy to make that change. I'm struggling to come up with a scenario in which an empty PointView would be useful. Would it be more useful to log a warning, at least acknowledging the request and explaining why it was not fulfilled?
filters/ReturnsFilter.hpp
Outdated
#include <map> | ||
#include <string> | ||
|
||
extern "C" int32_t ReturnsFilter_ExitFunc(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This boilerplate is no longer necessary.
filters/ReturnsFilter.hpp
Outdated
static const int returnLast = 4; | ||
static const int returnOnly = 8; | ||
|
||
static void* create(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This create(), destroy() boilerplate is no longer necessary.
filters/ReturnsFilter.hpp
Outdated
virtual void prepared(PointTableRef table); | ||
virtual PointViewSet run(PointViewPtr view); | ||
|
||
ReturnsFilter& operator=(const ReturnsFilter&); // not implemented |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can probably explictly delete these now. I think Windows is OK with it.
…lugin boilerplate
Users can create PointViews that contain first, intermediate, last, and only returns (based on ReturnNumber and NumberOfReturns).