@FunctionalInterface public interface ParameterParser
| 限定符和类型 | 方法和说明 |
|---|---|
default boolean |
check(MethodMeta meta)
编写自定义参数解析器实现的时候,可以重写这个方法,检查方法参数是否符合要求,以便在运行之初抛出异常方便检查
|
ResultWrapper |
parse(MethodMeta meta,
List<String> args) |
ResultWrapper parse(MethodMeta meta, List<String> args)
meta - 需要提供参数的方法对象args - 命令参数每段都用空格分隔,这里已经预先分隔成了列表default boolean check(MethodMeta meta)
meta - 方法中的有效信息Copyright © 2021. All rights reserved.