termField = in.readString(); updateField = in.readString();
static ParsedScrollId parseScrollId(String scrollId) { try { byte[] bytes = Base64.getUrlDecoder().decode(scrollId); ByteArrayDataInput in = new ByteArrayDataInput(bytes); String type = in.readString(); ScrollIdForNode[] context = new ScrollIdForNode[in.readVInt()]; for (int i = 0; i < context.length; ++i) { long id = in.readLong(); String target = in.readString(); String clusterAlias; final int index = target.indexOf(RemoteClusterAware.REMOTE_CLUSTER_INDEX_SEPARATOR); if (index == -1) { clusterAlias = null; } else { clusterAlias = target.substring(0, index); target = target.substring(index+1); } context[i] = new ScrollIdForNode(clusterAlias, target, id); } if (in.getPosition() != bytes.length) { throw new IllegalArgumentException("Not all bytes were read"); } return new ParsedScrollId(scrollId, type, context); } catch (Exception e) { throw new IllegalArgumentException("Cannot parse scroll id", e); } }
static ParsedScrollId parseScrollId(String scrollId) { try { byte[] bytes = Base64.getUrlDecoder().decode(scrollId); ByteArrayDataInput in = new ByteArrayDataInput(bytes); String type = in.readString(); ScrollIdForNode[] context = new ScrollIdForNode[in.readVInt()]; for (int i = 0; i < context.length; ++i) { long id = in.readLong(); String target = in.readString(); String clusterAlias; final int index = target.indexOf(RemoteClusterAware.REMOTE_CLUSTER_INDEX_SEPARATOR); if (index == -1) { clusterAlias = null; } else { clusterAlias = target.substring(0, index); target = target.substring(index+1); } context[i] = new ScrollIdForNode(clusterAlias, target, id); } if (in.getPosition() != bytes.length) { throw new IllegalArgumentException("Not all bytes were read"); } return new ParsedScrollId(scrollId, type, context); } catch (Exception e) { throw new IllegalArgumentException("Cannot parse scroll id", e); } }
static ParsedScrollId parseScrollId(String scrollId) { try { byte[] bytes = Base64.getUrlDecoder().decode(scrollId); ByteArrayDataInput in = new ByteArrayDataInput(bytes); String type = in.readString(); ScrollIdForNode[] context = new ScrollIdForNode[in.readVInt()]; for (int i = 0; i < context.length; ++i) { long id = in.readLong(); String target = in.readString(); context[i] = new ScrollIdForNode(target, id); } if (in.getPosition() != bytes.length) { throw new IllegalArgumentException("Not all bytes were read"); } return new ParsedScrollId(scrollId, type, context); } catch (Exception e) { throw new IllegalArgumentException("Cannot parse scroll id", e); } }
static ParsedScrollId parseScrollId(String scrollId) { try { byte[] bytes = Base64.getUrlDecoder().decode(scrollId); ByteArrayDataInput in = new ByteArrayDataInput(bytes); String type = in.readString(); ScrollIdForNode[] context = new ScrollIdForNode[in.readVInt()]; for (int i = 0; i < context.length; ++i) { long id = in.readLong(); String target = in.readString(); String clusterAlias; final int index = target.indexOf(RemoteClusterAware.REMOTE_CLUSTER_INDEX_SEPARATOR); if (index == -1) { clusterAlias = null; } else { clusterAlias = target.substring(0, index); target = target.substring(index+1); } context[i] = new ScrollIdForNode(clusterAlias, target, id); } if (in.getPosition() != bytes.length) { throw new IllegalArgumentException("Not all bytes were read"); } return new ParsedScrollId(scrollId, type, context); } catch (Exception e) { throw new IllegalArgumentException("Cannot parse scroll id", e); } }
termField = in.readString(); updateField = in.readString();