Removed visitor pattern used for one test only
[Mograsim.git] / net.mograsim.logic.ui / src / net / mograsim / logic / ui / model / components / SimpleRectangularSubmodelComponent.java
index 04a6fcc..59d800a 100644 (file)
@@ -12,7 +12,6 @@ import net.haspamelodica.swt.helper.gcs.GeneralGC;
 import net.haspamelodica.swt.helper.swtobjectwrappers.Font;
 import net.haspamelodica.swt.helper.swtobjectwrappers.Point;
 import net.haspamelodica.swt.helper.swtobjectwrappers.Rectangle;
-import net.mograsim.logic.ui.model.ModelVisitor;
 import net.mograsim.logic.ui.model.ViewModelModifiable;
 import net.mograsim.logic.ui.model.wires.MovablePin;
 import net.mograsim.logic.ui.model.wires.Pin;
@@ -129,8 +128,8 @@ public class SimpleRectangularSubmodelComponent extends SubmodelComponent
                ret.type = SimpleRectangularSubmodelComponent.class.getSimpleName();
                Map<String, Object> m = new TreeMap<>();
                m.put(kLabel, label);
-               m.put(kInCount, inputPinNames.size());
-               m.put(kOutCount, outputPinNames.size());
+               m.put(kInCount, inputPinNames.toArray());
+               m.put(kOutCount, outputPinNames.toArray());
                m.put(kLogicWidth, logicWidth);
                ret.specialized = m;
                return ret;
@@ -156,10 +155,4 @@ public class SimpleRectangularSubmodelComponent extends SubmodelComponent
                throw new UnsupportedOperationException(
                                "Can't set the size of a SimpleRectangularSubmodelComponent directly, call setInputPins / setOutputPins instead");
        }
-
-       @Override
-       public void accept(ModelVisitor mv)
-       {
-               mv.visit(this);
-       }
 }
\ No newline at end of file