package vaporize.library; import cs132.vapor.ast.*; import java.util.ArrayList; class Node { private VInstr instruction; private ArrayList sources; private ArrayList dests; protected Node(VInstr instruction) { this.instruction = instruction; this.sources = new ArrayList<>(); this.dests = new ArrayList<>(); } protected void addSource(Node node) { this.sources.add(node); } protected void addDest(Node node) { this.dests.add(node); } protected VInstr getInstruction() { return this.instruction; } protected ArrayList getSources() { return this.sources; } protected ArrayList getDests() { return this.dests; } }