Skip to content
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

♻️ Refactor internal command data classes #358

Merged
merged 1 commit into from
Dec 14, 2024

Conversation

nevans
Copy link
Collaborator

@nevans nevans commented Nov 25, 2024

The new CommandData superclass uses Data (prereq: #352) to add the pattern matching and equality methods while also simplifying the implementation. Specifically, I wanted RawData#deconstruct for the basic ESEARCH support branch (#333). It seemed reasonable to apply the same change to all of the internal command data classes.

Please note: this does change these objects to be frozen. However, these classes are explicitly undocumented (:nodoc), never returned by any public methods, and considered "internal", so this will not be treated as a "breaking change". I've extracted this from #333 into its own PR purely for documentation (release notes, etc).

@nevans nevans requested a review from shugo November 25, 2024 17:13
@nevans nevans force-pushed the refactor-command-data-classes branch 2 times, most recently from 839c1b7 to 606e4d9 Compare December 14, 2024 15:20
The new `CommandData` superclass uses `Data` to add the pattern matching
and equality methods while also simplifying the implementation.

Specifically, I wanted RawData#deconstruct for the basic `ESEARCH`
support branch.  It seemed reasonable to apply the same change to all of
the internal command data classes.

Please note: this does change these objects to be frozen.  However,
these classes are explicitly undocumented and considered "internal", so
this will _not_ be treated as a "breaking change".
@nevans nevans force-pushed the refactor-command-data-classes branch from 606e4d9 to e344454 Compare December 14, 2024 15:31
@nevans nevans merged commit ca72ac4 into master Dec 14, 2024
30 checks passed
@nevans nevans deleted the refactor-command-data-classes branch December 14, 2024 15:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant