diff --git a/prism/src/automata/DA.java b/prism/src/automata/DA.java index ee02a2ff..034d62b2 100644 --- a/prism/src/automata/DA.java +++ b/prism/src/automata/DA.java @@ -73,6 +73,14 @@ public class DA } } + /** + * Construct a DRA with zero states, use addState to add states. + */ + public DA() + { + this(0); + } + /** * Construct a DRA of fixed size (i.e. fixed number of states). */ @@ -109,6 +117,17 @@ public class DA // Mutators + /** + * Add a state. + * @return index of the fresh state + */ + public int addState() + { + edges.add(new ArrayList()); + size++; + return size-1; + } + /** * Set the start state (index) */