import { IDisposable } from "../../../base/common/lifecycle.js"; import { IPath } from "../../../base/common/path.js"; import { OperatingSystem } from "../../../base/common/platform.js"; import { URI } from "../../../sessions/sessions.web.main.internal.js"; import { IResourcePathProvider } from "./pathService.js"; export declare const IPathService: import("../../instantiation/common/instantiation.js").ServiceIdentifier; /** * Provides access to path related properties that match the target environment. */ export interface IPathService { readonly _serviceBrand: undefined; /** * The correct path library to use for the ambient target environment. */ readonly path: Promise; /** * Determines the best default URI scheme for the current workspace. */ readonly defaultUriScheme: string; /** * Converts the given path to a file URI for the ambient target environment. */ fileURI(path: string): Promise; /** * Resolves the user-home directory for the ambient target environment. */ userHome(options: { preferLocal: true; }): URI; userHome(options?: { preferLocal: boolean; }): Promise; /** * Figures out if the provided resource has a valid file name for the operating system the file is saved to. */ hasValidBasename(resource: URI, basename?: string): Promise; hasValidBasename(resource: URI, os: OperatingSystem, basename?: string): boolean; /** * Resolves the operating system whose path semantics apply to a resource. */ getOperatingSystem(resource: URI): Promise; /** * Resolves the path implementation whose semantics apply to a resource. */ getPath(resource: URI): Promise; /** * Registers path semantics for a URI scheme. */ registerPathProvider(scheme: string, provider: IResourcePathProvider): IDisposable; /** * @deprecated use `userHome` instead. */ readonly resolvedUserHome: URI | undefined; }