set int from segments.

@param segments target segments.
@param offset value offset.
429403
public static void setInt(MemorySegment[] segments, int offset, int value) {
		if (inFirstSegment(segments, offset, 4)) {
			segments[0].putInt(offset, value);
		} else {
			setIntMultiSegments(segments, offset, value);
		}
	}
891434
public void setDatabits(String databits) {
        if (!ModbusUtil.isBlank(databits) && databits.matches("[0-9]+")) {
            this.databits = Integer.parseInt(databits);
        }
        else {
            this.databits = 8;
        }
    }
897333
@Override
    public void setInt(int parameterIndex, int x) throws SQLException
    {
        checkParameterBounds(parameterIndex);
        this.parameters[parameterIndex-1] = x;
    }
927277
@Override
	public void setReadPosition(long pointer) {
		final int bufferNum = (int) (pointer >>> this.segmentSizeBits);
		final int offset = (int) (pointer & segmentSizeMask);

		this.currentBufferNum = bufferNum;

		seekInput(this.partitionBuffers[bufferNum], offset,
				bufferNum < partitionBuffers.length - 1 ? segmentSize : finalBufferLimit);
	}
802951
void set(int index, int value) {
        int chunk = assertSpace(index);
        chunks[chunk][index & mask] = value;
    }
899507
public static void setByte(MemorySegment[] segments, int offset, byte value) {
		if (inFirstSegment(segments, offset, 1)) {
			segments[0].put(offset, value);
		} else {
			setByteMultiSegments(segments, offset, value);
		}
	}
1322086
public void setValue(CharSequence value, int offset, int len) {
		Validate.notNull(value);
		if (offset < 0 || len < 0 || offset > value.length() - len) {
			throw new IndexOutOfBoundsException("offset: " + offset + " len: " + len + " value.len: " + len);
		}

		ensureSize(len);
		this.len = len;		
		for (int i = 0; i < len; i++) {
			this.value[i] = value.charAt(offset + i);
		}
		this.len = len;
		this.hashCode = 0;
	}
292045
protected void selectSegment(Segment segment) {
    if(segment.isUnpaired()) {
      // remember selected unpaired segment
      for(Segment other : segments.getPairedSegments(segment)) {
        indirectSelections.put(other, segment);
        selectSegment(other);
      }
    }
    else {
      if(!selectedSegments.contains(segment)) {
        selectedSegments.add(segment);
        if(segment.getDBIDs() != null) {
          unselectedObjects.removeDBIDs(segment.getDBIDs());
        }
      }
    }
  }
200802
public void setRegions(java.util.Collection<String> regions) {
        if (regions == null) {
            this.regions = null;
            return;
        }

        this.regions = new java.util.ArrayList<String>(regions);
    }
1276141
@Override
  public Boolean setbit(final byte[] key, final long offset, final boolean value) {
    checkIsInMultiOrPipeline();
    client.setbit(key, offset, value);
    return client.getIntegerReply() == 1;
  }
817888
protected boolean removeSegment(int segmentIndex) {
		if ((this.values == null) || (segmentIndex < 0)
				|| (segmentIndex >= this.values.length - 1)) {
			return false;
		}

		if (this.values.length == 2) {
			this.values = null;
			this.size = 0;
		} else {
			final int count = this.values[segmentIndex + 1] - this.values[segmentIndex] + 1;
			final int[] newTab = new int[this.values.length - 2];
			System.arraycopy(this.values, 0, newTab, 0, segmentIndex);
			System.arraycopy(this.values, segmentIndex + 2, newTab, segmentIndex, this.values.length - segmentIndex);
			this.values = newTab;
			this.size -= count;
		}

		return true;
	}
923611
public static long getLong(MemorySegment[] segments, int offset) {
		if (inFirstSegment(segments, offset, 8)) {
			return segments[0].getLong(offset);
		} else {
			return getLongMultiSegments(segments, offset);
		}
	}
257159
public synchronized void replaceSegments(Collection<Segment> segments, Segment segment) {
    // Update the segment descriptor and lock the segment.
    segment.descriptor().update(System.currentTimeMillis());
    segment.descriptor().lock();

    // Iterate through old segments and remove them from the segments list.
    for (Segment oldSegment : segments) {
      if (!this.segments.containsKey(oldSegment.index())) {
        throw new IllegalArgumentException("unknown segment at index: " + oldSegment.index());
      }
      this.segments.remove(oldSegment.index());
    }

    // Put the new segment in the segments list.
    this.segments.put(segment.index(), segment);

    resetCurrentSegment();
  }
264915
public void setValue(CharSequence value, int offset, int len) {
		checkNotNull(value);
		if (offset < 0 || len < 0 || offset > value.length() - len) {
			throw new IndexOutOfBoundsException("offset: " + offset + " len: " + len + " value.len: " + len);
		}

		ensureSize(len);
		this.len = len;		
		for (int i = 0; i < len; i++) {
			this.value[i] = value.charAt(offset + i);
		}
		this.hashCode = 0;
	}
48382
public void set(byte[] buff, int offset, int length){
        if(offset<0)
            throw new IndexOutOfBoundsException("ByteSequence index out of range: "+offset);
        if(length<0)
            throw new IndexOutOfBoundsException("ByteSequence index out of range: "+length);
        if(offset>buff.length-length)
            throw new StringIndexOutOfBoundsException("ByteSequence index out of range: "+(offset+length));

        this.buff = buff;
        this.offset = offset;
        this.length = length;
    }
1102077
public void setCurve (double[] coords, int offset) {
        setCurve(coords[offset + 0], coords[offset + 1], coords[offset + 2], coords[offset + 3],
                 coords[offset + 4], coords[offset + 5], coords[offset + 6], coords[offset + 7]);
    }
494029
public void set(int idx) {
    idx -= _bitoff;
    assert (idx >= 0 && idx < _nbits): "Must have "+_bitoff+" <= idx <= " + (_bitoff+_nbits-1) + ": " + idx;
    _val[_byteoff+(idx >> 3)] |= ((byte)1 << (idx & 7));
  }