Skip to content

M_RailwaySharp_ErrorHandling_Trial_Flatten__2

Moh.Hassan edited this page Oct 10, 2019 · 1 revision

Trial.Flatten(TSuccess, TMessage) Method

Flattens a nested result given the Failure types are equal.

Namespace: RailwaySharp.ErrorHandling
Assembly: CommandLine (in CommandLine.dll) Version: 0.0.0

Syntax

C#

public static Result<TSuccess, TMessage> Flatten<TSuccess, TMessage>(
	Result<Result<TSuccess, TMessage>, TMessage> result
)

VB

Public Shared Function Flatten(Of TSuccess, TMessage) ( 
	result As Result(Of Result(Of TSuccess, TMessage), TMessage)
) As Result(Of TSuccess, TMessage)

C++

public:
generic<typename TSuccess, typename TMessage>
static Result<TSuccess, TMessage>^ Flatten(
	Result<Result<TSuccess, TMessage>^, TMessage>^ result
)

F#

static member Flatten : 
        result : Result<Result<'TSuccess, 'TMessage>, 'TMessage> -> Result<'TSuccess, 'TMessage> 

Parameters

 

result
Type: RailwaySharp.ErrorHandling.Result(Result(TSuccess, TMessage), TMessage)

Type Parameters

 

TSuccess
TMessage

Return Value

Type: Result(TSuccess, TMessage)

See Also

Reference

Trial Class
RailwaySharp.ErrorHandling Namespace

Clone this wiki locally