text: 
  
  from core.himesis import Himesis, HimesisPreConditionPatternLHS
  
  class HM4ThenClausePart2CompleteLHS(HimesisPreConditionPatternLHS):
      def __init__(self):
          """
          Creates the himesis graph representing the AToM3 model HM4ThenClausePart2CompleteLHS.
          """
          # Flag this instance as compiled now
          self.is_compiled = True
          
          super(HM4ThenClausePart2CompleteLHS, self).__init__(name='HM4ThenClausePart2CompleteLHS', num_nodes=5, edges=[])
          
          # Add the edges
          self.add_edges([[3, 1], [4, 2], [0, 3], [0, 4]])
          # Set the graph attributes
          self["mm__"] = ['MT_pre__GM2AUTOSAR_MM', 'MoTifRule']
          self["MT_constraint__"] = """if PreNode('4')['associationType']=='ecuInstance' and PreNode('5')['associationType']=='ecuInstance':
      return True
  return False
  """
          self["name"] = """M4ThenClausePart2Complete"""
          self["GUID__"] = 1312833549040115022
          
          # Set the node attributes
          self.vs[0]["MT_pre__name"] = """
  #===============================================================================
  # This code is executed when evaluating if a node shall be matched by this rule.
  # You can access the value of the current node's attribute value by: attr_value.
  # You can access any attribute x of this node by: this['x'].
  # If the constraint relies on attribute values from other nodes,
  # use the LHS/NAC constraint instead.
  # The given constraint must evaluate to a boolean expression.
  #===============================================================================
  
  return True
  """
          self.vs[0]["MT_subtypeMatching__"] = False
          self.vs[0]["MT_pre__classtype"] = """
  #===============================================================================
  # This code is executed when evaluating if a node shall be matched by this rule.
  # You can access the value of the current node's attribute value by: attr_value.
  # You can access any attribute x of this node by: this['x'].
  # If the constraint relies on attribute values from other nodes,
  # use the LHS/NAC constraint instead.
  # The given constraint must evaluate to a boolean expression.
  #===============================================================================
  
  return True
  """
          self.vs[0]["MT_pivotIn__"] = """element1"""
          self.vs[0]["MT_label__"] = """1"""
          self.vs[0]["mm__"] = """MT_pre__SwcToEcuMapping"""
          self.vs[0]["MT_subtypes__"] = []
          self.vs[0]["MT_dirty__"] = False
          self.vs[0]["MT_pre__cardinality"] = """
  #===============================================================================
  # This code is executed when evaluating if a node shall be matched by this rule.
  # You can access the value of the current node's attribute value by: attr_value.
  # You can access any attribute x of this node by: this['x'].
  # If the constraint relies on attribute values from other nodes,
  # use the LHS/NAC constraint instead.
  # The given constraint must evaluate to a boolean expression.
  #===============================================================================
  
  return True
  """
          self.vs[0]["GUID__"] = 1906300579858015864
          self.vs[1]["MT_pre__name"] = """
  #===============================================================================
  # This code is executed when evaluating if a node shall be matched by this rule.
  # You can access the value of the current node's attribute value by: attr_value.
  # You can access any attribute x of this node by: this['x'].
  # If the constraint relies on attribute values from other nodes,
  # use the LHS/NAC constraint instead.
  # The given constraint must evaluate to a boolean expression.
  #===============================================================================
  
  return True
  """
          self.vs[1]["MT_subtypeMatching__"] = False
          self.vs[1]["MT_pre__classtype"] = """
  #===============================================================================
  # This code is executed when evaluating if a node shall be matched by this rule.
  # You can access the value of the current node's attribute value by: attr_value.
  # You can access any attribute x of this node by: this['x'].
  # If the constraint relies on attribute values from other nodes,
  # use the LHS/NAC constraint instead.
  # The given constraint must evaluate to a boolean expression.
  #===============================================================================
  
  return True
  """
          self.vs[1]["MT_pivotIn__"] = """element2"""
          self.vs[1]["MT_label__"] = """2"""
          self.vs[1]["mm__"] = """MT_pre__EcuInstance"""
          self.vs[1]["MT_subtypes__"] = []
          self.vs[1]["MT_dirty__"] = False
          self.vs[1]["MT_pre__cardinality"] = """
  #===============================================================================
  # This code is executed when evaluating if a node shall be matched by this rule.
  # You can access the value of the current node's attribute value by: attr_value.
  # You can access any attribute x of this node by: this['x'].
  # If the constraint relies on attribute values from other nodes,
  # use the LHS/NAC constraint instead.
  # The given constraint must evaluate to a boolean expression.
  #===============================================================================
  
  return True
  """
          self.vs[1]["GUID__"] = 7247056355179952571
          self.vs[2]["MT_pre__name"] = """
  #===============================================================================
  # This code is executed when evaluating if a node shall be matched by this rule.
  # You can access the value of the current node's attribute value by: attr_value.
  # You can access any attribute x of this node by: this['x'].
  # If the constraint relies on attribute values from other nodes,
  # use the LHS/NAC constraint instead.
  # The given constraint must evaluate to a boolean expression.
  #===============================================================================
  
  return True
  """
          self.vs[2]["MT_subtypeMatching__"] = False
          self.vs[2]["MT_pre__classtype"] = """
  #===============================================================================
  # This code is executed when evaluating if a node shall be matched by this rule.
  # You can access the value of the current node's attribute value by: attr_value.
  # You can access any attribute x of this node by: this['x'].
  # If the constraint relies on attribute values from other nodes,
  # use the LHS/NAC constraint instead.
  # The given constraint must evaluate to a boolean expression.
  #===============================================================================
  
  return True
  """
          self.vs[2]["MT_label__"] = """3"""
          self.vs[2]["mm__"] = """MT_pre__EcuInstance"""
          self.vs[2]["MT_subtypes__"] = []
          self.vs[2]["MT_dirty__"] = False
          self.vs[2]["MT_pre__cardinality"] = """
  #===============================================================================
  # This code is executed when evaluating if a node shall be matched by this rule.
  # You can access the value of the current node's attribute value by: attr_value.
  # You can access any attribute x of this node by: this['x'].
  # If the constraint relies on attribute values from other nodes,
  # use the LHS/NAC constraint instead.
  # The given constraint must evaluate to a boolean expression.
  #===============================================================================
  
  return True
  """
          self.vs[2]["GUID__"] = 4758685999985802472
          self.vs[3]["MT_subtypeMatching__"] = False
          self.vs[3]["MT_pre__associationType"] = """
  #===============================================================================
  # This code is executed when evaluating if a node shall be matched by this rule.
  # You can access the value of the current node's attribute value by: attr_value.
  # You can access any attribute x of this node by: this['x'].
  # If the constraint relies on attribute values from other nodes,
  # use the LHS/NAC constraint instead.
  # The given constraint must evaluate to a boolean expression.
  #===============================================================================
  
  return True
  """
          self.vs[3]["MT_label__"] = """4"""
          self.vs[3]["mm__"] = """MT_pre__directLink_T"""
          self.vs[3]["MT_subtypes__"] = []
          self.vs[3]["MT_dirty__"] = False
          self.vs[3]["GUID__"] = 9157926243168088171
          self.vs[4]["MT_subtypeMatching__"] = False
          self.vs[4]["MT_pre__associationType"] = """
  #===============================================================================
  # This code is executed when evaluating if a node shall be matched by this rule.
  # You can access the value of the current node's attribute value by: attr_value.
  # You can access any attribute x of this node by: this['x'].
  # If the constraint relies on attribute values from other nodes,
  # use the LHS/NAC constraint instead.
  # The given constraint must evaluate to a boolean expression.
  #===============================================================================
  
  return True
  """
          self.vs[4]["MT_label__"] = """5"""
          self.vs[4]["mm__"] = """MT_pre__directLink_T"""
          self.vs[4]["MT_subtypes__"] = []
          self.vs[4]["MT_dirty__"] = False
          self.vs[4]["GUID__"] = 5976210329179018018
  
      def eval_name1(self, attr_value, this):
          
          #===============================================================================
          # This code is executed when evaluating if a node shall be matched by this rule.
          # You can access the value of the current node's attribute value by: attr_value.
          # You can access any attribute x of this node by: this['x'].
          # If the constraint relies on attribute values from other nodes,
          # use the LHS/NAC constraint instead.
          # The given constraint must evaluate to a boolean expression.
          #===============================================================================
          
          return True
  
  
      def eval_classtype1(self, attr_value, this):
          
          #===============================================================================
          # This code is executed when evaluating if a node shall be matched by this rule.
          # You can access the value of the current node's attribute value by: attr_value.
          # You can access any attribute x of this node by: this['x'].
          # If the constraint relies on attribute values from other nodes,
          # use the LHS/NAC constraint instead.
          # The given constraint must evaluate to a boolean expression.
          #===============================================================================
          
          return True
  
  
      def eval_cardinality1(self, attr_value, this):
          
          #===============================================================================
          # This code is executed when evaluating if a node shall be matched by this rule.
          # You can access the value of the current node's attribute value by: attr_value.
          # You can access any attribute x of this node by: this['x'].
          # If the constraint relies on attribute values from other nodes,
          # use the LHS/NAC constraint instead.
          # The given constraint must evaluate to a boolean expression.
          #===============================================================================
          
          return True
  
  
      def eval_name2(self, attr_value, this):
          
          #===============================================================================
          # This code is executed when evaluating if a node shall be matched by this rule.
          # You can access the value of the current node's attribute value by: attr_value.
          # You can access any attribute x of this node by: this['x'].
          # If the constraint relies on attribute values from other nodes,
          # use the LHS/NAC constraint instead.
          # The given constraint must evaluate to a boolean expression.
          #===============================================================================
          
          return True
  
  
      def eval_classtype2(self, attr_value, this):
          
          #===============================================================================
          # This code is executed when evaluating if a node shall be matched by this rule.
          # You can access the value of the current node's attribute value by: attr_value.
          # You can access any attribute x of this node by: this['x'].
          # If the constraint relies on attribute values from other nodes,
          # use the LHS/NAC constraint instead.
          # The given constraint must evaluate to a boolean expression.
          #===============================================================================
          
          return True
  
  
      def eval_cardinality2(self, attr_value, this):
          
          #===============================================================================
          # This code is executed when evaluating if a node shall be matched by this rule.
          # You can access the value of the current node's attribute value by: attr_value.
          # You can access any attribute x of this node by: this['x'].
          # If the constraint relies on attribute values from other nodes,
          # use the LHS/NAC constraint instead.
          # The given constraint must evaluate to a boolean expression.
          #===============================================================================
          
          return True
  
  
      def eval_name3(self, attr_value, this):
          
          #===============================================================================
          # This code is executed when evaluating if a node shall be matched by this rule.
          # You can access the value of the current node's attribute value by: attr_value.
          # You can access any attribute x of this node by: this['x'].
          # If the constraint relies on attribute values from other nodes,
          # use the LHS/NAC constraint instead.
          # The given constraint must evaluate to a boolean expression.
          #===============================================================================
          
          return True
  
  
      def eval_classtype3(self, attr_value, this):
          
          #===============================================================================
          # This code is executed when evaluating if a node shall be matched by this rule.
          # You can access the value of the current node's attribute value by: attr_value.
          # You can access any attribute x of this node by: this['x'].
          # If the constraint relies on attribute values from other nodes,
          # use the LHS/NAC constraint instead.
          # The given constraint must evaluate to a boolean expression.
          #===============================================================================
          
          return True
  
  
      def eval_cardinality3(self, attr_value, this):
          
          #===============================================================================
          # This code is executed when evaluating if a node shall be matched by this rule.
          # You can access the value of the current node's attribute value by: attr_value.
          # You can access any attribute x of this node by: this['x'].
          # If the constraint relies on attribute values from other nodes,
          # use the LHS/NAC constraint instead.
          # The given constraint must evaluate to a boolean expression.
          #===============================================================================
          
          return True
  
  
      def eval_associationType4(self, attr_value, this):
          
          #===============================================================================
          # This code is executed when evaluating if a node shall be matched by this rule.
          # You can access the value of the current node's attribute value by: attr_value.
          # You can access any attribute x of this node by: this['x'].
          # If the constraint relies on attribute values from other nodes,
          # use the LHS/NAC constraint instead.
          # The given constraint must evaluate to a boolean expression.
          #===============================================================================
          
          return True
  
  
      def eval_associationType5(self, attr_value, this):
          
          #===============================================================================
          # This code is executed when evaluating if a node shall be matched by this rule.
          # You can access the value of the current node's attribute value by: attr_value.
          # You can access any attribute x of this node by: this['x'].
          # If the constraint relies on attribute values from other nodes,
          # use the LHS/NAC constraint instead.
          # The given constraint must evaluate to a boolean expression.
          #===============================================================================
          
          return True
  
  
      def constraint(self, PreNode, graph):
          """
              Executable constraint code. 
              @param PreNode: Function taking an integer as parameter
                              and returns the node corresponding to that label.
          """
          if PreNode('4')['associationType']=='ecuInstance' and PreNode('5')['associationType']=='ecuInstance':
              return True
          return False
  
  