init static method
void
init(
{ - String title = "日志",
- required bool isDebug,
- int? limitLength,
})
Implementation
static void init(
{String title = "日志", required bool isDebug, int? limitLength}) {
_title = title;
_isDebug = isDebug;
_limitLength = limitLength ??= _limitLength;
_startLine = "$_split$_title$_split";
var endLineStr = StringBuffer();
var cnCharReg = RegExp("[\u4e00-\u9fa5]");
for (int i = 0; i < _startLine.length; i++) {
if (cnCharReg.stringMatch(_startLine[i]) != null) {
endLineStr.write(_separator);
}
endLineStr.write(_separator);
}
_endLine = endLineStr.toString();
}