@Test(expected = IllegalArgumentException.class) public void testAddChildNull() { Assignment newAssignment = assignment.addChild(null); }
public Assignment addChild(Assignment a) { if (a == null) { String msg = "Argument 'a' [Assignment] cannot be null"; throw new IllegalArgumentException(msg); } children.add(a); return this; }
Assignment implements Comparable<Assignment>, Serializable { public Assignment addChild(Assignment a) { if (a == null) { String msg = "Argument 'a' [Assignment] cannot be null"; throw new IllegalArgumentException(msg); } children.add(a); return this; } }
Assignment implements Comparable<Assignment>, Serializable { public Assignment addChild(Assignment a) { if (a == null) { String msg = "Argument 'a' [Assignment] cannot be null"; throw new IllegalArgumentException(msg); } children.add(a); return this; } Assignment(String principalId, JsonEntityBean principal);  Assignment(String principalId, JsonEntityBean principal, Type type); }
Assignment implements Comparable<Assignment>, Serializable { public Assignment addChild(Assignment a) { if (a == null) { String msg = "Argument 'a' [Assignment] cannot be null"; throw new IllegalArgumentException(msg); } children.add(a); return this; } Assignment(String principalId, JsonEntityBean principal);  Assignment(String principalId, JsonEntityBean principal, Type type); Assignment addChild(Assignment a); @Override int compareTo(Assignment a); Set<Assignment> getChildren(); JsonEntityBean getPrincipal(); Type getType(); void setType(Type type); Assignment findDecendentOrSelfIfExists(JsonEntityBean principal); String getPrincipalId(); }
Assignment implements Comparable<Assignment>, Serializable { public Assignment addChild(Assignment a) { if (a == null) { String msg = "Argument 'a' [Assignment] cannot be null"; throw new IllegalArgumentException(msg); } children.add(a); return this; } Assignment(String principalId, JsonEntityBean principal);  Assignment(String principalId, JsonEntityBean principal, Type type); Assignment addChild(Assignment a); @Override int compareTo(Assignment a); Set<Assignment> getChildren(); JsonEntityBean getPrincipal(); Type getType(); void setType(Type type); Assignment findDecendentOrSelfIfExists(JsonEntityBean principal); String getPrincipalId();  }