<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _RawGlobPathSpecWithAlphabeticalSchema( file_system, parent_path_spec, segment_format, location, segment_length, upper_case=False):
 """Globs for path specifications according to an alphabetical naming schema. Args: file_system (FileSystem):
 file system. parent_path_spec (PathSpec):
 parent path specification. segment_format (str):
 naming schema of the segment file location. location (str):
 the base segment file location string. segment_length (int):
 length (number of characters) of the segment indicator. upper_case (Optional[bool]):
 True if the segment name is in upper case. Returns: list[PathSpec]: path specifications that match the glob. """

  segment_number = 0
  segment_files = []

  while True:
    segment_index = segment_number
    segment_letters = []
    while len(segment_letters) < segment_length:
      segment_index, remainder = divmod(segment_index, 26)
      if upper_case:
        segment_letters.append(chr(ord('A') + remainder))
      else:
        segment_letters.append(chr(ord('a') + remainder))

    # Reverse the segment letters list to form the extension.
    segment_letters = ''.join(segment_letters[::-1])
    segment_location = segment_format.format(location, segment_letters)

    # Note that we don't want to set the keyword arguments when not used
    # because the path specification base class will check for unused
    # keyword arguments and raise.
    kwargs = path_spec_factory.Factory.GetProperties(parent_path_spec)

    kwargs['location'] = segment_location
    if parent_path_spec.parent is not None:
      kwargs['parent'] = parent_path_spec.parent

    segment_path_spec = path_spec_factory.Factory.NewPathSpec(
        parent_path_spec.type_indicator, **kwargs)

    if not file_system.FileEntryExistsByPathSpec(segment_path_spec):
      break

    segment_files.append(segment_path_spec)

    segment_number += 1

  return segment_files