Skip to content

Commit

Permalink
Minor cosmetic changes wrt tests for #2013
Browse files Browse the repository at this point in the history
  • Loading branch information
cowtowncoder committed Feb 27, 2021
1 parent 7f1d04e commit eb6d2b1
Show file tree
Hide file tree
Showing 5 changed files with 187 additions and 208 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -804,9 +804,9 @@ public JsonGenerator createGenerator(File f, JsonEncoding enc) throws JacksonExc
*
* @since 3.0
*/
public JsonGenerator createGenerator(Path p, JsonEncoding enc) throws JacksonException {
_assertNotNull("p", p);
return _streamFactory.createGenerator(_serializerProvider(), p, enc);
public JsonGenerator createGenerator(Path path, JsonEncoding enc) throws JacksonException {
_assertNotNull("path", path);
return _streamFactory.createGenerator(_serializerProvider(), path, enc);
}

/**
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/com/fasterxml/jackson/databind/ObjectReader.java
Original file line number Diff line number Diff line change
Expand Up @@ -1224,17 +1224,17 @@ public <T> T readValue(File f) throws JacksonException
* Value return is either newly constructed, or root value that
* was specified with {@link #withValueToUpdate(Object)}.
*
* @param p Path that contains content to read
* @param path Path that contains content to read
*
* @since 3.0
*/
@SuppressWarnings("unchecked")
public <T> T readValue(Path p) throws JacksonException
public <T> T readValue(Path path) throws JacksonException
{
_assertNotNull("p", p);
_assertNotNull("path", path);
DeserializationContextExt ctxt = _deserializationContext();
return (T) _bindAndClose(ctxt,
_considerFilter(_parserFactory.createParser(ctxt, p), false));
_considerFilter(_parserFactory.createParser(ctxt, path), false));
}

/**
Expand Down Expand Up @@ -1749,9 +1749,9 @@ protected InputStream _inputStream(File f) throws JacksonException {
}
}

protected InputStream _inputStream(Path p) throws JacksonException {
protected InputStream _inputStream(Path path) throws JacksonException {
try {
return Files.newInputStream(p);
return Files.newInputStream(path);
} catch (IOException e) {
throw WrappedIOException.construct(e);
}
Expand Down
Loading

0 comments on commit eb6d2b1

Please sign in to comment.