public void eraseStorage(FilenameFilter filter) throws IOException {
        for (File brokerDir : brokerStorageDirectories) {
            for (File file : Objects.requireNonNull(brokerDir.listFiles(filter))) {
                Utils.delete(file);
            }
        }
    }
Check if the given offset is present in the first local segment of the given topic-partition.
@param topicPartition The topic-partition to check.
@param firstLogFileBaseOffset The base offset of the first local segment.
@param offsetToSearch The offset to search.
@return true if the offset is present in the first local segment, false otherwise.
storage/src/test/java/org/apache/kafka/tiered/storage/utils/BrokerLocalStorage.java