private List<LogSegmentName> getSegmentNames(long count, List<LogSegmentName> existingNames) {
    List<LogSegmentName> segmentNames = new ArrayList<>();
    if (existingNames != null) {
      segmentNames.addAll(existingNames);
    }
    if (count == segmentNames.size()) {
      return segmentNames;
    } else if (segmentNames.size() == 0) {
      segmentNames.add(LogSegmentName.generateFirstSegmentName(count > 1));
    }
    for (int i = segmentNames.size(); i < count; i++) {
      LogSegmentName nextSegmentName = segmentNames.get(i - 1).getNextPositionName();
      segmentNames.add(nextSegmentName);
    }
    return segmentNames;
  }
Returns {@code count} number of expected segment file names.
@param count the number of total segment names needed (including the ones in {@code existingNames}).
@param existingNames the names of log segments that are already known.
@return expected segment file names of {@code count} segment files.
ambry-store/src/test/java/com/github/ambry/store/LogTest.java