-
-
Notifications
You must be signed in to change notification settings - Fork 343
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
Updates to the Command API to support implementation #2066
Conversation
So effectively, |
src/main/java/org/spongepowered/api/command/manager/CommandManager.java
Outdated
Show resolved
Hide resolved
src/main/java/org/spongepowered/api/command/manager/CommandManager.java
Outdated
Show resolved
Hide resolved
I guess, though it doesn't really need to be a dispatcher so much. A registrar could conceivebly be a command executor - I don't put a restriction on it. Note that there are a couple of classes that don't have JDs. That's a mistake on my part, some API elements have made it through that were nowhere near ready. I won't be merging tonight as it is, so pick on anything and I'll review over the next couple of days. |
7fc207e
to
437bbf5
Compare
f36a5b3
to
456239f
Compare
d7582a3
to
35ca48a
Compare
e0cb097
to
0553016
Compare
ce7d33a
to
9d99d5b
Compare
bdf88ab
to
69b7ac3
Compare
69b7ac3
to
78c7d8d
Compare
78c7d8d
to
9cab778
Compare
src/main/java/org/spongepowered/api/command/parameter/CommandContext.java
Outdated
Show resolved
Hide resolved
e6f7079
to
2f912c9
Compare
* Added concept of CommandRegistrars to try to support external frameworks * Updates to some JavaDocs * Removed ArgumentReader parameter from completions, we just need to know what options there are. * Add ClientCompletionKeys to try to enable non-Sponge client completions * Update the CommandCause to directly implement Subject * Introduce the notion of a terminal parameter
2f912c9
to
0131ab9
Compare
The big thing here is the addition of a "CommandRegistrar". This is meant to be a lightweight interface that tries to give external command frameworks (Aikar's ACF, Katrix's Scammander, Faith's Butler, amongst others) a simple way to add their commands to Sponge. The idea of registrars was originally an implementation one - if you look at that code, you'll see that the vanilla brig system is separated from the Sponge one - it takes little work to add support for arbitary registrars, so why not add them?
The Javadocs should provide a fair amount of explanation. There will be more for client completions, I'm sure - though enabling that is the thing that is missing right now. That'll come later - it'll likely mimic Brig's suggestion provider with a tree like format to build the command elements up with.
This is simply for review of code style and Javadocs.