use of io.lettuce.core.dynamic.parameter.MethodParametersAccessor in project lettuce-core by lettuce-io.
the class CommandSegmentCommandFactory method createCommand.
@Override
public RedisCommand<Object, Object, Object> createCommand(Object[] parameters) {
MethodParametersAccessor parametersAccessor = new CodecAwareMethodParametersAccessor(new DefaultMethodParametersAccessor(commandMethod.getParameters(), parameters), typeContext);
CommandArgs<Object, Object> args = new CommandArgs<>(redisCodec);
CommandOutput<Object, Object, ?> output = outputFactory.create(redisCodec);
Command<Object, Object, ?> command = new Command<>(this.segments.getCommandType(), output, args);
parameterBinder.bind(args, redisCodec, segments, parametersAccessor);
return (Command) command;
}
Aggregations