private void swapInIfNeed() {
        if (this.swappedOut) {
            swapIn();
        }
    }
Read data from the position.

@param logIndex the log index
@param pos      the position to read
@return read data
jraft-core/src/main/java/com/alipay/sofa/jraft/storage/log/SegmentFile.java