code: static File createSegmentFile(String name, File directory, long id, long version) {
      return new File(directory, String.format("%s-%d-%d.log", Assert.notNull(name, "name"), id, version));
    }
docs: Creates a segment file for the given directory, log name, segment ID, and segment version.