TryDisposable 1.1.0

Wrap an object in a disposable decorator to attempt to dispose the object later. This is useful when retrieving an instance of an object from a factory or container while only having an interface reference. If the interface  does not implement IDisposable, but the concrete class does, this will allow you to dispose the instance.

There is a newer version of this package available.
See the version list below for details.
Install-Package TryDisposable -Version 1.1.0
dotnet add package TryDisposable --version 1.1.0
<PackageReference Include="TryDisposable" Version="1.1.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add TryDisposable --version 1.1.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: TryDisposable, 1.1.0"
#r directive can be used in F# Interactive, C# scripting and .NET Interactive. Copy this into the interactive tool or source code of the script to reference the package.
// Install TryDisposable as a Cake Addin
#addin nuget:?package=TryDisposable&version=1.1.0

// Install TryDisposable as a Cake Tool
#tool nuget:?package=TryDisposable&version=1.1.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

  • .NETStandard 2.0

    • No dependencies.
  • .NETStandard 2.1

    • No dependencies.

NuGet packages (9)

Showing the top 5 NuGet packages that depend on TryDisposable:

Package Downloads
Diamond.Patterns.WorkFlow
This library provides work-flow interfaces and abstract or default implementations for common patterns.
Diamond.Patterns.Decorator
This library provides a basic implementation of the decorator factory.
Diamond.Patterns.StateDictionary
This library provides an implementation of the state dictionary and provides seveal default type converters.
Diamond.Patterns.Mvc
Provides the Do pattern execution for MVC projects.
Diamond.Core.WorkFlow.State
This library provides an implementation of the state dictionary and provides several default type converters.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version History

Version Downloads Last updated
1.4.0 341 12/3/2020
1.3.1 433 4/14/2020
1.3.0 591 1/25/2020
1.2.0 226 1/12/2020
1.1.0 218 1/12/2020
1.0.0 805 5/28/2019