You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
30 lines
522 B
30 lines
522 B
2 years ago
|
|
||
|
class ExamineInstance{
|
||
|
|
||
|
factory ExamineInstance() => _getInstance();
|
||
|
|
||
|
static ExamineInstance get instance => _getInstance();
|
||
|
|
||
1 month ago
|
static ExamineInstance? _instance;
|
||
2 years ago
|
|
||
1 month ago
|
late bool _isExamine;
|
||
2 years ago
|
|
||
1 month ago
|
bool get isExamine => _isExamine;
|
||
2 years ago
|
|
||
|
set isExamine(bool value) {
|
||
|
this._isExamine = value;
|
||
|
}
|
||
|
|
||
|
ExamineInstance._internal(){
|
||
|
//单例初始化
|
||
2 years ago
|
_isExamine = true;
|
||
2 years ago
|
}
|
||
|
|
||
|
static ExamineInstance _getInstance(){
|
||
1 month ago
|
if (_instance == null) {
|
||
|
_instance = ExamineInstance._internal();
|
||
|
}
|
||
|
return _instance!;
|
||
2 years ago
|
}
|
||
|
|
||
|
}
|