protected override void BeginProcessing() { if (!string.IsNullOrEmpty(Path)) Path = GetUnresolvedProviderPathFromPSPath(Path); FileCollection collection; if (Simple) collection = new SimpleFileCollection(Path, FileFormat); else collection = new NormalFileCollection(Path, FileFormat); collection.Read(NewCollection); SessionState.PSVariable.Set(CollectionVariable ?? Actor.CollectionVariable, collection); }
protected override void BeginProcessing() { if (!string.IsNullOrEmpty(Path)) { Path = GetUnresolvedProviderPathFromPSPath(Path); } FileCollection collection; if (Simple) { collection = new SimpleFileCollection(Path, FileFormat); } else { collection = new NormalFileCollection(Path, FileFormat); } collection.Read(NewCollection); SessionState.PSVariable.Set(CollectionVariable ?? Actor.CollectionVariable, collection); }