Add doc for group_id

CURA-6483
This commit is contained in:
Lipu Fei 2019-04-30 12:53:45 +02:00
parent 40d26bbb6e
commit 0cc00efa79

View file

@ -35,6 +35,11 @@ class GlobalStack(CuraContainerStack):
super().__init__(container_id)
self.setMetaDataEntry("type", "machine") # For backward compatibility
# TL;DR: If Cura is looking for printers that belong to the same group, it should use "group_id".
# Each GlobalStack by default belongs to a group which is identified via "group_id". This group_id is used to
# figure out which GlobalStacks are in the printer cluster for example without knowing the implementation
# details such as the um_network_key or some other identifier that's used by the underlying device plugin.
self.setMetaDataEntry("group_id", str(uuid.uuid4())) # Assign a new GlobalStack to a unique group by default
self._extruders = {} # type: Dict[str, "ExtruderStack"]