@Test(expected=IllegalArgumentException.class) public void shouldRejectNullParameterName() { Transformation t = new Transformation(); t.addParameter(null, "foo"); }
public void addParameter(String name, Object value) { if (name == null) { throw new IllegalArgumentException("name must not be null"); } params.put(name, value); }
Transformation { public void addParameter(String name, Object value) { if (name == null) { throw new IllegalArgumentException("name must not be null"); } params.put(name, value); } }
Transformation { public void addParameter(String name, Object value) { if (name == null) { throw new IllegalArgumentException("name must not be null"); } params.put(name, value); } Transformation();  Transformation(Source s); }
Transformation { public void addParameter(String name, Object value) { if (name == null) { throw new IllegalArgumentException("name must not be null"); } params.put(name, value); } Transformation();  Transformation(Source s); void setSource(Source s); void setStylesheet(Source s); void addOutputProperty(String name, String value); void clearOutputProperties(); void addParameter(String name, Object value); void clearParameters(); void setFactory(TransformerFactory f); void setURIResolver(URIResolver r); void setErrorListener(ErrorListener l); void transformTo(Result r); String transformToString(); Document transformToDocument(); }
Transformation { public void addParameter(String name, Object value) { if (name == null) { throw new IllegalArgumentException("name must not be null"); } params.put(name, value); } Transformation();  Transformation(Source s); void setSource(Source s); void setStylesheet(Source s); void addOutputProperty(String name, String value); void clearOutputProperties(); void addParameter(String name, Object value); void clearParameters(); void setFactory(TransformerFactory f); void setURIResolver(URIResolver r); void setErrorListener(ErrorListener l); void transformTo(Result r); String transformToString(); Document transformToDocument();  }