@Test public void testIsVarIDAllowed() { System.out.println("isVarIDAllowed"); String id = "test"; InternalTypeContainer internalTypeContainer = new InternalTypeContainer(InternalTypeRep.INTEGER); SymbolicVariableList instance = new SymbolicVariableList(); assert (instance.isVarIDAllowed("test")); instance.addSymbolicVariable(id, internalTypeContainer); assert (!instance.isVarIDAllowed("test")); }
public synchronized boolean isVarIDAllowed(String id) { boolean varAllowed = true; if (!symbolicVariableList.isEmpty()) { for (SymbolicVariable var : symbolicVariableList) { if (var.getId().equals(id)) { varAllowed = false; break; } } } return varAllowed; }
SymbolicVariableList { public synchronized boolean isVarIDAllowed(String id) { boolean varAllowed = true; if (!symbolicVariableList.isEmpty()) { for (SymbolicVariable var : symbolicVariableList) { if (var.getId().equals(id)) { varAllowed = false; break; } } } return varAllowed; } }
SymbolicVariableList { public synchronized boolean isVarIDAllowed(String id) { boolean varAllowed = true; if (!symbolicVariableList.isEmpty()) { for (SymbolicVariable var : symbolicVariableList) { if (var.getId().equals(id)) { varAllowed = false; break; } } } return varAllowed; } SymbolicVariableList(); }
SymbolicVariableList { public synchronized boolean isVarIDAllowed(String id) { boolean varAllowed = true; if (!symbolicVariableList.isEmpty()) { for (SymbolicVariable var : symbolicVariableList) { if (var.getId().equals(id)) { varAllowed = false; break; } } } return varAllowed; } SymbolicVariableList(); synchronized void addSymbolicVariable(String id, InternalTypeContainer internalTypeContainer); synchronized boolean isVarIDAllowed(String id); synchronized void setSymbolicVariableList(List<SymbolicVariable> symbolicVariableList); synchronized List<SymbolicVariable> getSymbolicVariables(); synchronized List<SymbolicVariable> getSymbolicVariablesCloned(); synchronized boolean removeSymbolicVariable(String id); synchronized void removeSymbolicVariable(int index); synchronized void addListener(VariableListListener listener); synchronized void removeListener(VariableListListener listener); }
SymbolicVariableList { public synchronized boolean isVarIDAllowed(String id) { boolean varAllowed = true; if (!symbolicVariableList.isEmpty()) { for (SymbolicVariable var : symbolicVariableList) { if (var.getId().equals(id)) { varAllowed = false; break; } } } return varAllowed; } SymbolicVariableList(); synchronized void addSymbolicVariable(String id, InternalTypeContainer internalTypeContainer); synchronized boolean isVarIDAllowed(String id); synchronized void setSymbolicVariableList(List<SymbolicVariable> symbolicVariableList); synchronized List<SymbolicVariable> getSymbolicVariables(); synchronized List<SymbolicVariable> getSymbolicVariablesCloned(); synchronized boolean removeSymbolicVariable(String id); synchronized void removeSymbolicVariable(int index); synchronized void addListener(VariableListListener listener); synchronized void removeListener(VariableListListener listener);  }