Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions lib/src/main/java/sim/core/Circuit.java
Original file line number Diff line number Diff line change
Expand Up @@ -290,4 +290,22 @@ public List<Gate> getPrimaryOutputs() {
public List<Wire> getWires() {
return new ArrayList<>(wires);
}

/**
* Returns a copy of the primary input bindings map.
*
* <p>The returned map preserves insertion order of primary inputs but is a
* shallow copy. Modifications to the returned map or its lists will not
* affect the circuit's internal state.</p>
*/
public Map<String, List<InputBinding>> getPrimaryInputBindings() {
return new LinkedHashMap<>(primaryInputBindings);
}

/**
* Returns a copy of the list of gates designated as primary outputs.
*/
public List<Gate> getPrimaryOutputs() {
return new ArrayList<>(primaryOutputs);
}
}
Loading