Finite Reality
7597cf5baa
Fix CalculateScore throwing on missing parameters ( #727 )
* Fix CalculateScore throwing on missing parameters
* Bump to version 1.0.1
8 years ago
Finite Reality
032aba9129
Update commands with C#7 features ( #689 )
* C#7 features in commands, CommandInfo in ModuleBase
* Update TypeReaders with C#7 features and IServiceProvider
* Add best-choice command selection to CommandService
* Normalize type reader scores correctly
* Fix logic error and rebase onto dev
* Change GetMethod for SetMethod in ReflectionUtils
Should be checking against setters, not getters
* Ensure args/params scores do not overwhelm Priority
* Remove possibility of NaNs
8 years ago
FiniteReality
00895b1227
Remove CommandService.BuildServiceCollection
💥
8 years ago
RogueException
ba1982a3f9
Replaced DependencyMap with ServiceCollection and IServiceProvider ( #625 )
8 years ago
Bond-009
cb4f6e37f6
Overloaded AddModuleAsync with Type ( #581 )
* Overloaded AddModuleAsync with Type
* Overloaded RemoveModuleAsync with Type
* Use expression-bodied method for consistency
8 years ago
Finite Reality
ca18eb0eb4
Replace TryGetValue call with TryRemove call ( #586 )
Resolves #584
8 years ago
RogueException
3fb21e06c2
Fixed RunMode.Sync running Async. Added ThrowOnError option.
8 years ago
RogueException
a2b12520b2
Added CommandService logging
8 years ago
Finite Reality
3ddb01a5a2
Fix order of iteration in ExecuteAsync ( #534 )
8 years ago
Christopher F
f3aa546407
Throw an InvalidOp if a user tries to set the DefaultRunMode to Default
never overestimate the end user
8 years ago
FiniteReality
0715cb6623
Actually use HashSet<T> to initialize _moduleDefs
8 years ago
FiniteReality
a65ba095af
Replace ConcurrentBag<T> with HashSet<T>
Fixes #487
8 years ago
RogueException
2c075e186a
Added support for custom ModuleBase command contexts. Added SocketCommandContext/RpcCommandContext.
8 years ago
RogueException
1965c0539a
Added support for concrete Rest/Socket/RPC classes in command params
8 years ago
RogueException
5663e47db6
Added command separator char, improved passing search results to parser
8 years ago
Christopher F
604d69fb7f
Revert "Implement configurable command node separators"
8 years ago
RogueException
18de2ecac7
Merge pull request #412 from FiniteReality/issue/304-v2
Implement configurable command node separators
8 years ago
RogueException
b01200f929
Cleaned up primitive type readers. Fixed TimeSpan reader.
8 years ago
Finite Reality
9aa924f75c
Remove blank line
8 years ago
FiniteReality
70d30efb94
Implement configurable command node separators
This fixes #304 over foxbot's PR for the same issue.
8 years ago
RogueException
803b65212e
Merge pull request #364 from FiniteReality/feature/parameter-tweaks
Parameter preconditions and typereader overriding
8 years ago
Aux
d4d8e721db
Resolves #390
Fix case insensitive commands forcing parameters to return lowercase
8 years ago
FiniteReality
704b2b75f4
Fix changes after review
8 years ago
FiniteReality
254e874c99
Fix OverrideTypeReader
This commit also adds a TypeReaders property to CommandService, so
it is possible to see all of the registered TypeReaders. This makes
it possible for users to implement their own parsing instead of
using the built-in parsing.
8 years ago
james7132
3e35666186
Add TimeSpan TypeReader
8 years ago
Christopher F
ecc3d9c729
Add configuration option for case insensitive commands
Currently, commands are case-sensitive. This PR allows for commands to be case insensitive (which is now the default option).
8 years ago
Christopher F
55f6efd080
Merge branch 'issue/365'
Conflicts:
src/Discord.Net.Commands/CommandService.cs
8 years ago
Christopher F
f9c5e229d0
Add CommandServiceConfig, DefaultRunMode
This adds an (optional) CommandServiceConfig, as well as a DefaultRunMode for commands.
This resolves #368 (for commands where a RunMode is not explicitly specified, a custom default value should be used)
8 years ago
FiniteReality
05fb81c617
Fix a bunch of issues with aliases
8 years ago
RogueException
593ba46f1c
Cleaned up command builders and async func names
8 years ago
FiniteReality
de645548a9
Complete command builders implementation
In theory this should just work, more testing is needed though
8 years ago
FiniteReality
6d46347ebc
Finish implementation of command builders
8 years ago
RogueException
b8102a6767
Default DependencyMap to an empty map when not supplied
8 years ago
FiniteReality
a7cefbcf9f
Move DI stuff around to support scoped DI
8 years ago
james7132
3841eb616c
Fix #311
TypeInfo.BaseType will likely return the same Type if all modules derive from
ModuleBase or some common subclass of it. Making it appear as if only one module
is registered.
Changed to TypeInfo.AsType for expected behavior.
8 years ago
RogueException
8c8ac47887
Merge pull request #308 from Joe4evr/AutoLoadFix
Exclude abstract types from being loaded as modules.
8 years ago
RogueException
8ebc437674
Exposed IDependencyMap in CommandService.Execute
8 years ago
Joe4evr
bc45c0b6a4
Exclude abstract types from being loaded as modules.
8 years ago
RogueException
635819b89f
Reduced command module lifetime to a single command execution. Removed ModuleAttribute.
8 years ago
RogueException
5c33e28757
Added missing ConfigureAwaits
8 years ago
RogueException
98475302af
Added bool/char typereaders
8 years ago
RogueException
3c3e790edd
Replaced several arrays with immutables
8 years ago
RogueException
708f9fe514
Added CommandContext, fixed commands compile errors
8 years ago
FiniteReality
accb3e27b8
Add PriorityAttribute and sortby priority in Search
8 years ago
RogueException
23a0316252
Split IMessage into IUserMessage and ISystemMessage
8 years ago
RogueException
f6d8659a2e
Removed ParamList null checks
8 years ago
RogueException
324664917d
Added new parameter scoring, support multiple matches
8 years ago
FiniteReality
610a3a26ab
Add DI support to command Groups
8 years ago
RogueException
0b25554c31
Unknown overload should return UnknownCommand instead of ParseFailed
8 years ago
RogueException
94d6acc00e
Exposed reflection classes on commands, modules and parameters
8 years ago