Skip to content

Commit dabb66e

Browse files
committed
Backport new Session.getKeys() from v5 to v4
1 parent 9688cb0 commit dabb66e

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/main/java/com/googlecode/objectify/impl/Session.java

+8
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
import com.googlecode.objectify.util.ResultNow;
55
import java.util.HashMap;
66
import java.util.Map;
7+
import java.util.Set;
78
import java.util.logging.Level;
89
import java.util.logging.Logger;
910

@@ -69,4 +70,11 @@ public void clear() {
6970
public String toString() {
7071
return map.toString();
7172
}
73+
74+
75+
/**
76+
* @return all the keys currently in the session. If you really want this data, subclass ObjectifyImpl and
77+
* use the protected getSession() method.
78+
*/
79+
public Set<Key<?>> keys() { return map.keySet(); }
7280
}

0 commit comments

Comments
 (0)