@Override
    public void set(int inputId, short value) throws StorageException {
      ByteBuffer dataBuf = ByteBuffer.allocate(ELEMENT_BYTES);
      try {
        ensureCapacity(inputId);
        dataBuf.putShort(value);
        dataBuf.flip();
        int bytesWritten = 0;
        while (bytesWritten < ELEMENT_BYTES) {
          bytesWritten += myFileChannel.write(dataBuf, offsetInFile(inputId) + bytesWritten);
        }
      }
      catch (IOException e) {
        throw closeWithException(new StorageException(e));
      }
      //noinspection NonAtomicOperationOnVolatileField
      myModificationsCounter++;
    }
@Override
    public void set(int inputId, short value)