X-Git-Url: https://mograsim.net/gitweb/?a=blobdiff_plain;f=era.mi%2Fsrc%2Fmograsim%2Flogic%2Fcore%2Fcomponents%2FComponent.java;fp=era.mi%2Fsrc%2Fmograsim%2Flogic%2Fcore%2Fcomponents%2FComponent.java;h=54109df7ed2b3bc152c7e0772ebd59c5907c1774;hb=a28f7aa0dab4248e99159c5a647676170cb17a4e;hp=0000000000000000000000000000000000000000;hpb=80bfbd8ebf0ad8a7ad98584544a0c73f43e6f3b6;p=Mograsim.git diff --git a/era.mi/src/mograsim/logic/core/components/Component.java b/era.mi/src/mograsim/logic/core/components/Component.java new file mode 100644 index 00000000..54109df7 --- /dev/null +++ b/era.mi/src/mograsim/logic/core/components/Component.java @@ -0,0 +1,28 @@ +package mograsim.logic.core.components; + +import java.util.List; + +import mograsim.logic.core.timeline.Timeline; +import mograsim.logic.core.wires.Wire.ReadEnd; +import mograsim.logic.core.wires.Wire.ReadWriteEnd; + +public abstract class Component +{ + protected Timeline timeline; + + public Component(Timeline timeline) + { + this.timeline = timeline; + } + + /** + * Returns immutable list of all inputs to the {@link Component} (including e.g. the select bits to a MUX). Intended for visualization + * in the UI. + */ + public abstract List getAllInputs(); + + /** + * Returns immutable list of all outputs to the {@link Component}. Intended for visualization in the UI. + */ + public abstract List getAllOutputs(); +}