Table of Contents

Adjust Method

Definition

Namespace
Cuemon.Extensions
Assemblies
Cuemon.Extensions.Core.dll
Source
src/Cuemon.Extensions.Core/ObjectExtensions.cs

Adjust<T>(T, Func<T, T>)

Adjust the specified value with the function delegate converter.

public static T Adjust<T>(this T value, Func<T, T> converter)

Parameters

value T

The value to convert.

converter Func<T, T>

The function delegate that will convert the specified value.

Returns

T

The value in its original or converted form.

Type Parameters

T

The type of the value to convert.

Remarks

This is thought to be a more severe change than the one provided by Alter<T>(T, Action<T>) (e.g., potentially convert the entire value to a new instance).