aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit/src/org/eclipse/jgit/lib/ObjectReader.java
diff options
context:
space:
mode:
authorShawn O. Pearce <spearce@spearce.org>2010-06-28 11:57:41 -0700
committerShawn O. Pearce <spearce@spearce.org>2010-06-28 11:57:41 -0700
commitaa4b06e08781f9f4e33259d92eb919b3c6da22ef (patch)
treeeee974b42e4da94702449d3094dfd8e786bc0a18 /org.eclipse.jgit/src/org/eclipse/jgit/lib/ObjectReader.java
parentacb7be2c5adb270d21182d389ce93f3bca38cd29 (diff)
downloadjgit-aa4b06e08781f9f4e33259d92eb919b3c6da22ef.tar.gz
jgit-aa4b06e08781f9f4e33259d92eb919b3c6da22ef.zip
Rename openObject, hasObject to just open, has
Similar to what we did on Repository, the openObject method already implied we wanted to open an object, given its main argument was of type AnyObjectId. Simplify the method name to just the action, has or open. Change-Id: If055e5e0d8de0e2424c18a773f6d2bc2f66054f4 Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Diffstat (limited to 'org.eclipse.jgit/src/org/eclipse/jgit/lib/ObjectReader.java')
-rw-r--r--org.eclipse.jgit/src/org/eclipse/jgit/lib/ObjectReader.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/lib/ObjectReader.java b/org.eclipse.jgit/src/org/eclipse/jgit/lib/ObjectReader.java
index 001b18c4c8..e9afc5043e 100644
--- a/org.eclipse.jgit/src/org/eclipse/jgit/lib/ObjectReader.java
+++ b/org.eclipse.jgit/src/org/eclipse/jgit/lib/ObjectReader.java
@@ -68,9 +68,9 @@ public abstract class ObjectReader {
* @throws IOException
* the object store cannot be accessed.
*/
- public boolean hasObject(AnyObjectId objectId) throws IOException {
+ public boolean has(AnyObjectId objectId) throws IOException {
try {
- openObject(objectId);
+ open(objectId);
return true;
} catch (MissingObjectException notFound) {
return false;
@@ -88,9 +88,9 @@ public abstract class ObjectReader {
* @throws IOException
* the object store cannot be accessed.
*/
- public ObjectLoader openObject(AnyObjectId objectId)
+ public ObjectLoader open(AnyObjectId objectId)
throws MissingObjectException, IOException {
- return openObject(objectId, OBJ_ANY);
+ return open(objectId, OBJ_ANY);
}
/**
@@ -111,7 +111,7 @@ public abstract class ObjectReader {
* @throws IOException
* the object store cannot be accessed.
*/
- public abstract ObjectLoader openObject(AnyObjectId objectId, int typeHint)
+ public abstract ObjectLoader open(AnyObjectId objectId, int typeHint)
throws MissingObjectException, IncorrectObjectTypeException,
IOException;