LottoConfig class final
摇奖配置;例如 LottoConfig.superLotto()。
- Annotations
Constructors
-
LottoConfig({required List<
LottoPool> pools, LottoOptions options = const LottoOptions(), LottoStyle style = const LottoStyle()}) -
创建一个或多个号码池;列表及其内容在使用期间应保持不可变。
const
- LottoConfig.superLotto({LottoOptions options = const LottoOptions(), LottoStyle style = const LottoStyle()})
-
创建唯一内置预设:前区 35 选 5,后区 12 选 2。
factory
Properties
- hashCode → int
-
与相等性一致的哈希。
no setteroverride
- options → LottoOptions
-
动画与排序选项。
final
-
pools
→ List<
LottoPool> -
按出球顺序排列的号码池。
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- style → LottoStyle
-
机身外观。
final
Methods
-
copyWith(
{List< LottoPool> ? pools, LottoOptions? options, LottoStyle? style}) → LottoConfig -
返回替换非空参数的副本,例如
config.copyWith(style: style)。 -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
validate(
) → void - 校验池与动画参数;非法配置抛出 ArgumentError。
Operators
-
operator ==(
Object other) → bool -
按池顺序与配置值比较。
override