OCFL / ocfl-java

A Java OCFL implementation
MIT License
16 stars 12 forks source link

Method name does not match javadoc description #2

Closed awoods closed 4 years ago

awoods commented 4 years ago

Based on the javadocs and the method parameters, it would seem that this method should be named something like putFile() instead of getFile().

https://github.com/UW-Madison-Library/ocfl-java/blob/31129b8ccdd1b9f52a9cbfcfdb6353ec90944e47/ocfl-java-api/src/main/java/edu/wisc/library/ocfl/api/OcflObjectReader.java#L41

pwinckles commented 4 years ago

It's getting a file out of an OCFL object. I'm open to renaming pretty much anything, but I don't think put is a good fit here. In my mind, I put files into the repository and get them out.

awoods commented 4 years ago

Thanks for clarifying. Maybe the minor update in the javadoc from:

Writes a specific file to the given destinationPath

to:

Writes a specific file to the given destinationPath outside of the OCFL Storage Root

..would have corrected my assumptions.

pwinckles commented 4 years ago

Thanks, I updated the text. Let me know if you find anything else that's unclear.