public bool IsContainer(string path) { var runtime = new ProviderRuntime(SessionState); bool result = IsContainer(path, runtime); runtime.ThrowFirstErrorOrContinue(); return(result); }
public bool Exists(string path, bool force, bool literalPath) { var runtime = new ProviderRuntime(SessionState, force, literalPath); bool result = Exists(path, runtime); runtime.ThrowFirstErrorOrContinue(); return(result); }
public Collection <PathInfo> GetResolvedPSPathFromPSPath(string path) { var runtime = new ProviderRuntime(_sessionState); var res = GetResolvedPSPathFromPSPath(new [] { path }, runtime); runtime.ThrowFirstErrorOrContinue(); return(res); }
public PathInfo SetLocation(string path) { var runtime = new ProviderRuntime(_sessionState); var res = SetLocation(path, runtime); runtime.ThrowFirstErrorOrContinue(); return(res); }
public string ParseParent(string path, string root) { var runtime = new ProviderRuntime(_sessionState); var res = ParseParent(path, root, runtime); runtime.ThrowFirstErrorOrContinue(); return(res); }
public string ParseChildName(string path) { var runtime = new ProviderRuntime(_sessionState); var res = ParseChildName(path, runtime); runtime.ThrowFirstErrorOrContinue(); return(res); }
public string NormalizeRelativePath(string path, string basePath) { var runtime = new ProviderRuntime(_sessionState); var res = NormalizeRelativePath(path, basePath, runtime); runtime.ThrowFirstErrorOrContinue(); return(res); }
public Collection <PSObject> New(string[] paths, string name, string itemTypeName, object content, bool force) { // TODO: support globbing (e.g. * in filename) Path normalizedPath; var runtime = new ProviderRuntime(_cmdlet.ExecutionContext); runtime.Force = force; foreach (var path in paths) { var provider = GetContainerProviderByPath(path, name, out normalizedPath); provider.NewItem(normalizedPath, itemTypeName, content, runtime); } runtime.ThrowFirstErrorOrContinue(); return(runtime.RetreiveAllProviderData()); }