UDocMarkup.create constructor
UDocMarkup.create({})
Implementation
factory UDocMarkup.create({
required UDocMarkupKind kind,
required int pageIndex,
required Color color,
String groupId = "",
int blockIndex = -1,
int start = 0,
int end = 0,
String text = "",
List<Rect> rects = const <Rect>[],
String note = "",
Map<String, Object?> extra = const <String, Object?>{},
}) {
final DateTime now = DateTime.now();
return UDocMarkup(
id: _newId(),
groupId: groupId,
kind: kind,
pageIndex: pageIndex,
blockIndex: blockIndex,
start: start,
end: end,
text: text,
rects: rects,
color: color,
note: note,
createdAt: now,
updatedAt: now,
extra: extra,
);
}