for (int i = 0, size = refs.size(); i < size; i++) {
SomeHandle ref = refs.get(i);
if (ref.handle() != contextRef.longValue()) {
continue;
}
ContextHandle contextHandle;
try {
contextHandle = ref.asContextHandle();
} catch (JsonProtocolParseException e) {
throw new RuntimeException(e);
}