@Override public final Range deserialize(final JsonParser p, final DeserializationContext ctx) throws IOException, JsonProcessingException { return new Range(p.getValueAsString()); } }
@Override @SuppressWarnings("unchecked") public void readExternal(final ObjectInput in) throws IOException, ClassNotFoundException { super.readExternal(in); dataInput = item.getDataInput(); contentSize = in.readLong(); int n = in.readInt(); if(n == 0) { fixedRanges = null; } else { fixedRanges = new ArrayList<>(n); for(int i = 0; i < n; i ++) { fixedRanges.add(new Range(in.readLong(), in.readLong(), in.readLong())); } } randomRangesCount = in.readInt(); markedRangesMaskPair[0].or(BitSet.valueOf(new long[] {in.readLong()})); markedRangesMaskPair[1].or(BitSet.valueOf(new long[] {in.readLong()})); countBytesDone = in.readLong(); respDataTimeStart = in.readLong(); n = in.readInt(); if(n > 0) { srcItemsToConcat = new ArrayList<>(n); for(int i = 0; i < n; i ++) { srcItemsToConcat.add((T) in.readObject()); } } } }
public RangesConfig(final RangesConfig other) { final List<String> otherRanges = other.getFixed(); this.concat = other.getConcat(); if(this.concat != null) { this.concat = new Range(this.concat); } this.fixed = otherRanges == null ? null : new ArrayList<>(otherRanges); this.random = other.getRandom(); this.threshold = new SizeInBytes(other.getThreshold()); }
.invoke(config, sizeValue); } else if(fieldType.equals(Range.class)) { final Range rangeValue = new Range((String) value); configCls .getMethod("set" + capitalize(key), Range.class)
fixedRanges.add(new Range(0L, item.size() - 1, -1));
fixedRanges.add(new Range(0L, item.size() - 1, -1));
final Range srcItemsCountRange = new Range(itemDataRangesConcatConfig); final long srcItemsCountMin = srcItemsCountRange.getBeg(); final long srcItemsCountMax = srcItemsCountRange.getEnd();