344 def BlockCompatibility(self, startblock=None, endblock=None, direction=None): |
344 def BlockCompatibility(self, startblock=None, endblock=None, direction=None): |
345 if startblock is not None and endblock is not None and \ |
345 if startblock is not None and endblock is not None and \ |
346 (isinstance(startblock, SFC_Objects) or isinstance(endblock, SFC_Objects)): |
346 (isinstance(startblock, SFC_Objects) or isinstance(endblock, SFC_Objects)): |
347 # Full "SFC_StandardRules" table would be symmetrical and |
347 # Full "SFC_StandardRules" table would be symmetrical and |
348 # to avoid duplicate records and minimize the table only upper part is defined. |
348 # to avoid duplicate records and minimize the table only upper part is defined. |
349 if (direction == SOUTH or direction == EAST): |
349 if direction == SOUTH or direction == EAST: |
350 startblock, endblock = endblock, startblock |
350 startblock, endblock = endblock, startblock |
351 start = self.GetBlockName(startblock) |
351 start = self.GetBlockName(startblock) |
352 end = self.GetBlockName(endblock) |
352 end = self.GetBlockName(endblock) |
353 for val in self.SFC_StandardRules[start]: |
353 for val in self.SFC_StandardRules[start]: |
354 if end in val: |
354 if end in val: |