Soenneker.Utils.ResettableLazy 4.0.441

Prefix Reserved
dotnet add package Soenneker.Utils.ResettableLazy --version 4.0.441
                    
NuGet\Install-Package Soenneker.Utils.ResettableLazy -Version 4.0.441
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Soenneker.Utils.ResettableLazy" Version="4.0.441" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Soenneker.Utils.ResettableLazy" Version="4.0.441" />
                    
Directory.Packages.props
<PackageReference Include="Soenneker.Utils.ResettableLazy" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Soenneker.Utils.ResettableLazy --version 4.0.441
                    
#r "nuget: Soenneker.Utils.ResettableLazy, 4.0.441"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Soenneker.Utils.ResettableLazy@4.0.441
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Soenneker.Utils.ResettableLazy&version=4.0.441
                    
Install as a Cake Addin
#tool nuget:?package=Soenneker.Utils.ResettableLazy&version=4.0.441
                    
Install as a Cake Tool

alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image

alternate text is missing from this package README image Soenneker.Utils.ResettableLazy

A thread-safe resettable lazy implementation

Installation

dotnet add package Soenneker.Utils.ResettableLazy

Usage

var _httpClientLazy = new ResettableLazy<HttpClient>(() => httpClientFactory.CreateClient("", true);

// HttpClient is created from the factory at this point
_httpClientLazy.Value.GetAsync("http://google.com");

// flushes the lazy's cache
_httpClientLazy.Reset();

// A new HttpClient is created from the factory again since Reset() was called
_httpClientLazy.Value.GetAsync("http://google.com");

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net10.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
4.0.441 104 3/10/2026
4.0.440 92 3/9/2026
4.0.439 94 3/9/2026
4.0.438 95 3/4/2026
4.0.437 135 1/2/2026
4.0.436 439 11/20/2025
4.0.435 230 10/29/2025
3.0.434 265 9/3/2025
3.0.433 224 8/11/2025
3.0.432 215 7/3/2025
3.0.431 177 6/27/2025
3.0.430 248 5/27/2025
3.0.429 224 5/22/2025
3.0.428 259 5/7/2025
3.0.427 225 5/5/2025
3.0.426 213 5/5/2025
3.0.424 224 4/6/2025
3.0.423 188 3/1/2025
3.0.422 222 2/10/2025
3.0.421 192 2/7/2025
Loading failed