Class PurePathMatchExtensions
Provides functional matching methods for IPurePath implementations.
public static class PurePathMatchExtensions
- Inheritance
-
PurePathMatchExtensions
- Inherited Members
Methods
Match<T, TOut>(IPurePath, Func<T, TOut>, Func<TOut>)
Matches the given IPurePath instance against a single type and returns a result.
public static TOut Match<T, TOut>(this IPurePath path, Func<T, TOut> action, Func<TOut> fallback) where T : IPurePath
Parameters
Returns
- TOut
Type Parameters
TTOut
Match<T1, T2, TOut>(IPurePath, Func<T1, TOut>, Func<T2, TOut>, Func<TOut>)
Matches the given IPurePath instance against two possible types and returns a result.
public static TOut Match<T1, T2, TOut>(this IPurePath path, Func<T1, TOut> action1, Func<T2, TOut> action2, Func<TOut> fallback) where T1 : IPurePath where T2 : IPurePath
Parameters
Returns
- TOut
Type Parameters
T1T2TOut
Match<T1, T2, T3, TOut>(IPurePath, Func<T1, TOut>, Func<T2, TOut>, Func<T3, TOut>, Func<TOut>)
Matches the given IPurePath instance against three possible types and returns a result.
public static TOut Match<T1, T2, T3, TOut>(this IPurePath path, Func<T1, TOut> action1, Func<T2, TOut> action2, Func<T3, TOut> action3, Func<TOut> fallback) where T1 : IPurePath where T2 : IPurePath where T3 : IPurePath
Parameters
pathIPurePathaction1Func<T1, TOut>action2Func<T2, TOut>action3Func<T3, TOut>fallbackFunc<TOut>
Returns
- TOut
Type Parameters
T1T2T3TOut