AbstractGeometryItem.fromJson constructor

AbstractGeometryItem.fromJson(
  1. Map<String, dynamic> json
)

Deserializes a JSON-compatible map to create an instance.

Used internally, not intended for direct use by consumers. The expected map structure may change without notice.

Implementation

factory AbstractGeometryItem.fromJson(final Map<String, dynamic> json) {
  return AbstractGeometryItem(
    arrowType: ArrowTypeExtension.fromId(json['arrowtype']),
    beginArrowDirection: ArrowDirectionExtension.fromId(
      json['beginarrowdirection'],
    ),
    beginSlot: json['beginslot'],
    endArrowDirection: ArrowDirectionExtension.fromId(
      json['endarrowdirection'],
    ),
    endSlot: json['endslot'],
    restrictionType: RestrictionTypeExtension.fromId(json['restrictiontype']),
    shapeForm: ShapeFormExtension.fromId(json['shapeform']),
    shapeType: ShapeTypeExtension.fromId(json['shapetype']),
    slotAllocation: json['slotallocation'],
  );
}