Package | Description |
---|---|
cn.hutool.cron.pattern.matcher | |
cn.hutool.cron.pattern.parser |
定时任务表达式解析器,内部使用
|
Modifier and Type | Class and Description |
---|---|
class |
AlwaysTrueMatcher
所有值匹配,始终返回
true |
class |
BoolArrayMatcher
将表达式中的数字值列表转换为Boolean数组,匹配时匹配相应数组位
|
class |
DayOfMonthMatcher
每月第几天匹配
考虑每月的天数不同,且存在闰年情况,日匹配单独使用 |
class |
YearValueMatcher
年匹配
考虑年数字太大,不适合boolean数组,单独使用 LinkedHashSet 匹配 |
Modifier and Type | Method and Description |
---|---|
PartMatcher |
PatternMatcher.get(Part part)
根据表达式位置,获取对应的
PartMatcher |
Constructor and Description |
---|
PatternMatcher(PartMatcher secondMatcher,
PartMatcher minuteMatcher,
PartMatcher hourMatcher,
PartMatcher dayOfMonthMatcher,
PartMatcher monthMatcher,
PartMatcher dayOfWeekMatcher,
PartMatcher yearMatcher)
构造
|
Modifier and Type | Method and Description |
---|---|
PartMatcher |
PartParser.parse(String value)
将表达式解析为
PartMatcher * 或者 ? 返回 AlwaysTrueMatcher
Part.DAY_OF_MONTH 返回DayOfMonthMatcher
Part.YEAR 返回YearValueMatcher
其他 返回BoolArrayMatcher
|
Copyright © 2024. All rights reserved.