absolutePath property

String get absolutePath

Get file absolute path.

Implementation

String get absolutePath {
  if (p.isAbsolute(path)) return path;
  if (source == FileSource.project) {
    return p.join(Directory.current.path, path);
  }
  if (source == FileSource.system32) return p.joinAll([...system32, path]);
  // this package is not supposed to arrive to this line, but just in case.
  throw ArgumentError('Invalid FileSource: $source');
}