Drop get prefixes from almost all things #3332
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
SpongeAPI | Sponge
Hey look. An evening to myself!
As much as I dislike this, a decision has been made to drop the
get
prefix from our methods. So, I've done that for the command API - we need to get this ball rolling properly. I'd also like to resolve the question of builders before I pull this, but please let's not do that here, I'm really not interested in another flame war about whether it should beset
oradd
or whatever - the leads can decide that.I haven't done it for anything else because there may be instances where renaming has other unintentional side effects. See
SpongeStringReader
for an example here - some of the methods were shared with the Brig string reader and we're not transforming Brig.getRead
had to becomeparsed
(better name welcome). Thus, I think the best way to do this big rename is on a package basis where those who are in the know about their stuff does it.I went and cobbled together an IntelliJ plugin to create an inspection and quick fix to help speed up the process of refactoring - https://github.com/dualspiral/drop-get-plugin - I'm not publishing it but if anyone else wants to use it/improve it, be my guest (or if we want to clean it up and pull it into the Sponge org, I don't mind).