Allow shapes to carry an arbitrary identifier (Tuple)

This commit is contained in:
Jan Petykiewicz 2019-05-13 23:55:14 -07:00
parent 380393dbc3
commit 9ab1372c7b

View File

@ -34,6 +34,9 @@ class Shape(metaclass=ABCMeta):
# Dose # Dose
_dose = 1.0 # type: float _dose = 1.0 # type: float
# An arbitrary identifier for the shape, usually not set but used by Pattern.flatten()
identifier = () # type: Tuple
# --- Abstract methods # --- Abstract methods
@abstractmethod @abstractmethod
def to_polygons(self, num_vertices: int, max_arclen: float) -> List['Polygon']: def to_polygons(self, num_vertices: int, max_arclen: float) -> List['Polygon']: