TryOperationResult<TValue>

Namespace: ASPSecurityKit
Assembly: ASPSecurityKit.dll

Summary

Represents a result of calling a safe try method.

Generic Types
Name Description
TValue Type of the value.

Constructors

#ctor(value)

Summary

Initializes a new instance of the TryOperationResult<TValue> class as a succeeded result.

Parameters
Name Type Description
value TValue The value resulted upon successful operation execution.

Properties

Succeeded

Summary

Gets a value indicating whether the operation represented by this result instance succeeded.

Value

true if the operation represented by this result instance succeeded; otherwise, false.

Value

Summary

Gets a value resulted when the operation succeeds.

Value

The resulted value if the operation succeeds; otherwise, default.

Failed

Summary

Shortcut method to get an instance of TryOperationResult<TValue> initialized as a failed result.

Value

An instance of TryOperationResult<TValue> initialized as a failed result.