Lamp

A modern annotations-driven commands framework for Java and Kotlin

MIT License

Stars
197
Committers
16

Bot releases are visible (Hide)

Lamp - Auto completer fixes, utility methods on ValueResolverContext

Published by Revxrsal about 3 years ago

  • Minor fixes on the auto-completer
  • Added utility methods: popInt(), popDouble(), popLong(), and popFloat() to ValueResolverCondext

Contextualization:

  • ContextResolvers and ValueResolvers now accept a single parameter, ContextResolverContext and ValueResolverContext respectively.
  • Both contexts extend from ParameterResolverContext, which exposes the CommandActor, CommandParameter, as well as other useful elements
  • Contexts provide the ability to refer to the arguments that have already been resolved.
  • Contexts should make it easier to introduce additions to resolvers without breaking old code
  • This update is not backwards-compatible!

  • Automatically infer responses of type java.util.function.Supplier
  • Fix response types not allowing nesting, for example a CompletableFuture<Optional<String>>.
  • Add ArgumentStack#asImmutableCopy() for gaining independent copies.
Lamp - ArgumentStack fixes, Sponge update

Published by Revxrsal about 3 years ago

  • Fixed some ArgumentStack#of() methods not respecting quotes and joining strings into one.
  • Added ArgumentStack#empty()
  • Fixed Sponge implementation
  • Allow response types of java.util.Optional
  • Optimize CommandPath#getCategoryPath()
  • Pass ArgumentStack#asImmutableView() to command conditions
  • more fixes

Full Changelog: https://github.com/Revxrsal/Lamp/compare/1.2...1.3

Lamp - Exceptions and actors update

Published by Revxrsal about 3 years ago

Changelog:

  • Replaced inaccurate chat colorizing
  • Added XYZCommandActor#wrap(...) methods
  • Exposed CommandActor to CommandExceptionHandler#handleException
  • Removed #getActor() from exceptions
  • Added support for Sponge's TextMessageException.
  • Created a default exception handler for Velocity
  • SendableExceptions no longer require a CommandActor to be supplied.
Lamp - Initial release

Published by Revxrsal about 3 years ago