/// <summary>Appends four values at the end of a tuple</summary> public static IVarTuple Append <T1, T2, T3, T4>(this IVarTuple tuple, T1 value1, T2 value2, T3 value3, T4 value4) { Contract.NotNullAllowStructs(tuple, nameof(tuple)); return(new JoinedTuple(tuple, STuple.Create <T1, T2, T3, T4>(value1, value2, value3, value4))); }
public static ITuple Append <T1, T2, T3, T4>([NotNull] this ITuple tuple, T1 value1, T2 value2, T3 value3, T4 value4) { Contract.NotNull(tuple, nameof(tuple)); return(new JoinedTuple(tuple, STuple.Create <T1, T2, T3, T4>(value1, value2, value3, value4))); }
/// <summary>Appends two values at the end of a tuple</summary> public static IVarTuple Append <T1, T2>(this IVarTuple tuple, T1 value1, T2 value2) { Contract.NotNullAllowStructs(tuple); return(new JoinedTuple(tuple, STuple.Create(value1, value2))); }
public static ITuple Append <T1, T2>([NotNull] this ITuple tuple, T1 value1, T2 value2) { Contract.NotNull(tuple, nameof(tuple)); return(new JoinedTuple(tuple, STuple.Create(value1, value2))); }
public ITuple ToTuple(T key) { return(STuple.Create(key)); }