-bool ConnectedInterface::connectTo(ConnectedInterface *iface) {\r
-\r
- if (canConnectTo(iface)) {\r
- connectedTo.append(iface);\r
- return true;\r
+void ConnectedInterface::setOutputPattern(QList<char>* pattern) {\r
+ if (outputPattern != NULL) delete outputPattern;\r
+ outputPattern = pattern; \r
+}\r
+void ConnectedInterface::connectTo(ConnectedInterface *iface) {\r
+ \r
+ connectedTo.append(iface);\r
+ iface->connectedFrom = this;\r
+ ConnectedInterface* asso1 = (ConnectedInterface*)associatedIface;\r
+ ConnectedInterface* asso2 = (ConnectedInterface*)(iface->associatedIface);\r
+ if ((asso1 != NULL) && (asso2 != NULL)) {\r
+ asso1->connectedTo.append(asso2);\r
+ asso2->connectedFrom = asso1;\r