-
Notifications
You must be signed in to change notification settings - Fork 97
Add DeprecatedGroup and ObsoleteGroup implementations with unit tests #3919
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
base: develop
Are you sure you want to change the base?
Conversation
| GEOS_LOG_RANK_0( GEOS_FMT( | ||
| "\n" | ||
| "********************************************************************************\n" | ||
| "* DEPRECATION WARNING\n" | ||
| "* Group: {}\n" | ||
| "* {}\n" | ||
| "********************************************************************************", | ||
| className, message ) ); |
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.
Why not using a true GEOS_WARNING?
| GEOS_LOG_RANK_0( GEOS_FMT( | ||
| "\n" | ||
| "********************************************************************************\n" | ||
| "* OBSOLETE GROUP WARNING\n" | ||
| "* Group: {}\n" | ||
| "* {}\n" | ||
| "* This group has been removed and will cause an error if used.\n" | ||
| "* (Group object created for input parsing compatibility only)\n" | ||
| "********************************************************************************", | ||
| className, message ) ); |
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.
Same remark, why not GEOS_WARNING?
| * @tparam T The type that would normally be wrapped | ||
| */ | ||
| template< typename T > | ||
| class NoopWrapper final : public WrapperBase |
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.
As metadata function as another wrapper, could it be used to document some aspects of a given Group?
If yes, it would be cool to have this class in its own file :)
If not, maybe it should be named after its final role (i.e. DeprecatedWrapper)
Just putting this up for review for the moment, not married to any design decisions and I assume we'll want to change output message structure.
This basically just introduces mechanisms to lifecycle internal types that have been replaced/supplanted while informing the user in obvious ways and maintaining the schema generation/documentation and parse>init process for that type until it drops completely from the project.
To deprecate any
Groupsubclass just, for e.g.class Foo : public ExecutableGroup(inherits from any group subclass):It basically just injects itself into the inheritance hierarchy and adds the deprecation/obsolescence behavior.