* @return String
   */
  public static String fileNameDirectory(String file) {
    { int start = 0;
      int length = file.length();
      char separator = Stella.directorySeparatorForFile(file);

      if (Stella.logicalPathnameP(file)) {
        start = Native.string_position(file, Stella.LOGICAL_HOST_SEPARATOR, 0) + 1;
      }
      while ((start < length) &&
          (Native.string_position(file, separator, start) != Stella.NULL_INTEGER)) {
        start = Native.string_position(file, separator, start) + 1;
      }
      return (Native.string_subsequence(file, 0, start));
    }
  }