Esempio n. 1
0
        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);
        }
Esempio n. 2
0
        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);
        }