System.Web.PowerShell.HttpPowerShellPSObjectConverter.AsDisposable C# (CSharp) Method

AsDisposable() public static method

public static AsDisposable ( this collection ) : IDisposableEnumerable
collection this
return IDisposableEnumerable
        public static IDisposableEnumerable<PSObject> AsDisposable(this IEnumerable<PSObject> collection)
        {
            return new DisposableCollection<PSObject>(collection, obj => obj.BaseObject as IDisposable);
        }
    }