Closed nanounanue closed 4 years ago
Definitely a better default behavior and makes sense to me generally. Only question is whether it might be a little cleaner structurally to have a "no-op" importance method rather than a separate class?
Totally agree, I don' t like it either, but that's how triage
does it :( . (See LabelGeneratorNoOp
, EntityDateTableGeneratorNoOp
, ProtectedGroupsGeneratorNoOp
, etc)
I need to change the structure (and incorporate the class instead of many args, etc). I will do a new issue for all of this
Ah, didn't realize that pattern was used elsewhere -- makes sense to be consistent in that case. I'll go ahead and merge in that case!
The null object pattern used here is so the interface between components can stay the same regardless. If you make a no-op method on each instead, it means you have to make if statements buried in loops in different places. Using null objects like these, the if statements can be in one place: when you build the components based on config.
Closes #643