@VisibleForTesting
  boolean hasAttribute(int attributesRecordId,
                       int fileId,
                       int attributeId) throws IOException {
    if (!storage.hasRecord(attributesRecordId)) {
      return false;
    }
    return storage.readRecord(attributesRecordId, buffer -> {
      AttributesRecord attributesRecord = new AttributesRecord(buffer);
      attributesRecord.checkBackrefFile(attributesRecordId, fileId);
      if (!attributesRecord.hasDirectory()) {
        throw new IllegalArgumentException("record(" + attributesRecordId + ") is not a directory record: " +
                                           "(" + attributesRecord.backRefFileId + ", " + attributesRecord.dedicatedAttributeId + ")");
      }
      if (!attributesRecord.findAttributeInDirectoryRecord(attributeId)) {
        return false;
      }

      AttributeEntry attributeEntry = attributesRecord.currentEntry();
      if (attributeEntry.isValueInlined()) {
        return true;
      }
      else {
        int dedicatedRecordId = attributeEntry.dedicatedValueRecordId();
        return storage.hasRecord(dedicatedRecordId);
      }
    });
  }
@VisibleForTesting
  boolean hasAttribute(int attributesRecordId,
                       int fileId,
                       int attributeId)