Class MethodCommand<S>

java.lang.Object
com.simsilica.lemur.MethodCommand<S>
All Implemented Interfaces:
Command<S>

public class MethodCommand<S> extends Object implements Command<S>
A Command implementation that calls a configured no-argument method through reflection.
  • Constructor Details

    • MethodCommand

      public MethodCommand(Object delegate, String methodName)
    • MethodCommand

      public MethodCommand(Object delegate, Method method)
  • Method Details

    • execute

      public void execute(S source)
      Specified by:
      execute in interface Command<S>