fromEntity static method

Implementation

static Future<LabelledBodyComponentModel?> fromEntity(
    String documentID, LabelledBodyComponentEntity? entity) async {
  if (entity == null) return null;
  return LabelledBodyComponentModel(
    documentID: documentID,
    label: entity.label,
    componentName: entity.componentName,
    componentId: entity.componentId,
  );
}