Struct DelegatingSupplier<T, TResult>
Assembly: DotNext.dll
Syntax
public readonly struct DelegatingSupplier<T, TResult> : ISupplier<T, TResult>, IFunctional, IEquatable<DelegatingSupplier<T, TResult>> where T : allows ref struct where TResult : allows ref struct
Type Parameters
| Name |
Description |
| T |
The type of the argument.
|
| TResult |
The type of the result.
|
Constructors
View Source
DelegatingSupplier(Func<T, TResult>)
Wraps the delegate instance.
Declaration
public DelegatingSupplier(Func<T, TResult> func)
Parameters
| Type |
Name |
Description |
| Func<T, TResult> |
func |
The delegate instance.
|
Exceptions
Properties
View Source
IsEmpty
Gets a value indicating that the underlying delegate is null.
Declaration
public bool IsEmpty { get; }
Property Value
Methods
View Source
Equals(DelegatingSupplier<T, TResult>)
Declaration
public bool Equals(DelegatingSupplier<T, TResult> other)
Parameters
Returns
View Source
Equals(object)
Declaration
public override bool Equals(object obj)
Parameters
| Type |
Name |
Description |
| object |
obj |
|
Returns
Overrides
View Source
GetHashCode()
Declaration
public override int GetHashCode()
Returns
Overrides
View Source
ToString()
Declaration
public override string? ToString()
Returns
Overrides
Operators
View Source
operator ==(DelegatingSupplier<T, TResult>, DelegatingSupplier<T, TResult>)
Declaration
public static bool operator ==(DelegatingSupplier<T, TResult> left, DelegatingSupplier<T, TResult> right)
Parameters
Returns
View Source
implicit operator DelegatingSupplier<T, TResult>(Func<T, TResult>)
Wraps the delegate instance.
Declaration
public static implicit operator DelegatingSupplier<T, TResult>(Func<T, TResult> func)
Parameters
| Type |
Name |
Description |
| Func<T, TResult> |
func |
The delegate instance.
|
Returns
Exceptions
View Source
operator !=(DelegatingSupplier<T, TResult>, DelegatingSupplier<T, TResult>)
Declaration
public static bool operator !=(DelegatingSupplier<T, TResult> left, DelegatingSupplier<T, TResult> right)
Parameters
Returns
Implements
Extension Methods