BaseUnit constructor

BaseUnit({
  1. required String code,
  2. required String? codeUC,
  3. required String property,
  4. required String dim,
  5. bool? isMetric,
  6. String? name,
  7. List<String>? synonyms,
  8. String? printSymbol,
})

Constructor for BaseUnit.

Implementation

BaseUnit({
  required super.code,
  required super.codeUC,
  required super.property,
  required this.dim,
  super.isMetric,
  String? name,
  List<String>? synonyms,
  super.printSymbol,
}) : super(
          kind: ConceptKind.baseUnit,
          names: name != null || (synonyms != null && synonyms.isNotEmpty)
              ? <String>[
                  if (name != null) name,
                  if (synonyms != null && synonyms.isNotEmpty) ...synonyms
                ]
              : null);