From 7a1293977cadb4429ad4ec95a5b15b034dae45d5 Mon Sep 17 00:00:00 2001 From: Michael Mortensen Date: Wed, 16 Oct 2024 00:00:15 +0200 Subject: [PATCH 1/4] :pencil2: double the (typo) --- src/Cuemon.Core/BinaryPrefix.cs | 2 +- src/Cuemon.Core/DecimalPrefix.cs | 2 +- .../Extensions/Reflection/AssemblyDecoratorExtensions.cs | 2 +- src/Cuemon.Core/PrefixMultiple.cs | 2 +- src/Cuemon.Core/Runtime/Serialization/HierarchySerializer.cs | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Cuemon.Core/BinaryPrefix.cs b/src/Cuemon.Core/BinaryPrefix.cs index bc0703113..8874e0af6 100644 --- a/src/Cuemon.Core/BinaryPrefix.cs +++ b/src/Cuemon.Core/BinaryPrefix.cs @@ -83,7 +83,7 @@ public sealed class BinaryPrefix : PrefixMultiple /// Initializes a new instance of the struct. /// /// The name of the binary prefix. - /// The symbol of the the binary prefix. + /// The symbol of the binary prefix. /// The number that specifies a power. public BinaryPrefix(string name, string symbol, double exponent) : base(name, symbol, 2, exponent) { diff --git a/src/Cuemon.Core/DecimalPrefix.cs b/src/Cuemon.Core/DecimalPrefix.cs index 4f1e13dd2..3c5e8720e 100644 --- a/src/Cuemon.Core/DecimalPrefix.cs +++ b/src/Cuemon.Core/DecimalPrefix.cs @@ -167,7 +167,7 @@ public sealed class DecimalPrefix : PrefixMultiple /// Initializes a new instance of the struct. /// /// The name of the decimal prefix. - /// The symbol of the the decimal prefix. + /// The symbol of the decimal prefix. /// The number that specifies a power. public DecimalPrefix(string name, string symbol, double exponent) : base(name, symbol, 10, exponent) { diff --git a/src/Cuemon.Core/Extensions/Reflection/AssemblyDecoratorExtensions.cs b/src/Cuemon.Core/Extensions/Reflection/AssemblyDecoratorExtensions.cs index 79005d590..5f1d95915 100644 --- a/src/Cuemon.Core/Extensions/Reflection/AssemblyDecoratorExtensions.cs +++ b/src/Cuemon.Core/Extensions/Reflection/AssemblyDecoratorExtensions.cs @@ -19,7 +19,7 @@ public static class AssemblyDecoratorExtensions /// Determines whether the underlying of the is a debug build. /// /// The to extend. - /// true if the the underlying of the is a debug build; otherwise, false. + /// true if the underlying of the is a debug build; otherwise, false. /// /// cannot be null. /// diff --git a/src/Cuemon.Core/PrefixMultiple.cs b/src/Cuemon.Core/PrefixMultiple.cs index 344f292c6..b376ccbce 100644 --- a/src/Cuemon.Core/PrefixMultiple.cs +++ b/src/Cuemon.Core/PrefixMultiple.cs @@ -18,7 +18,7 @@ public abstract class PrefixMultiple : IPrefixMultiple /// Initializes a new instance of the struct. /// /// The name of the binary unit. - /// The symbol of the the unit prefix. + /// The symbol of the unit prefix. /// The number to be raised to a power. /// The number that specifies a power. protected PrefixMultiple(string name, string symbol, double value, double exponent) diff --git a/src/Cuemon.Core/Runtime/Serialization/HierarchySerializer.cs b/src/Cuemon.Core/Runtime/Serialization/HierarchySerializer.cs index 7b59af4f8..9189e0472 100644 --- a/src/Cuemon.Core/Runtime/Serialization/HierarchySerializer.cs +++ b/src/Cuemon.Core/Runtime/Serialization/HierarchySerializer.cs @@ -22,7 +22,7 @@ public HierarchySerializer(object source, Action setup = /// /// Gets the result of the . /// - /// The converted nodes of the the by constructor defined source object. + /// The converted nodes of the by constructor defined source object. public IHierarchy Nodes { get; } /// From a8e67c797bb64dac782315e1df9418a839dcb718 Mon Sep 17 00:00:00 2001 From: Michael Mortensen Date: Wed, 16 Oct 2024 02:41:29 +0200 Subject: [PATCH 2/4] :building_construction: major refactoring; abandon Template and TemplateFactory for MutableTuple and MutableTupleFactory; it has a better ring and closer to original vision --- src/Cuemon.Core/MutableTuple.cs | 1272 +++++++++++ ...plateFactory.cs => MutableTupleFactory.cs} | 22 +- src/Cuemon.Core/Template.cs | 1958 ----------------- .../Threading/AsyncActionFactory.cs | 8 +- src/Cuemon.Core/Threading/AsyncFuncFactory.cs | 8 +- src/Cuemon.Diagnostics/TimeMeasure.Async.cs | 4 +- src/Cuemon.Net/Mail/MailDistributor.cs | 8 +- .../TransientOperation.Async.cs | 4 +- .../ActionForEachSynchronousLoop.cs | 2 +- .../ActionForSynchronousLoop.cs | 2 +- .../ActionWhileSynchronousLoop.cs | 2 +- .../AdvancedParallelFactory.ForAsync.cs | 2 +- .../AdvancedParallelFactory.ForResultAsync.cs | 2 +- .../AdvancedParallelFactory.WhileAsync.cs | 2 +- ...dvancedParallelFactory.WhileResultAsync.cs | 2 +- src/Cuemon.Threading/AsyncActionFactory.cs | 64 +- src/Cuemon.Threading/AsyncFuncFactory.cs | 64 +- src/Cuemon.Threading/AsyncPatterns.cs | 4 +- .../ForEachSynchronousLoop.cs | 6 +- src/Cuemon.Threading/ForSynchronousLoop.cs | 6 +- .../FuncForEachSynchronousLoop.cs | 4 +- .../FuncForSynchronousLoop.cs | 4 +- .../FuncWhileSynchronousLoop.cs | 4 +- .../ParallelFactory.ForEachAsync.cs | 2 +- .../ParallelFactory.ForEachResultAsync.cs | 2 +- src/Cuemon.Threading/SynchronousLoop.cs | 6 +- src/Cuemon.Threading/WhileSynchronousLoop.cs | 6 +- .../Converters/DefaultXmlConverter.cs | 2 +- test/Cuemon.Core.Tests/MutableTupleTest.cs | 411 ++++ .../MutableTupleFactoryTest.cs} | 48 +- 30 files changed, 1828 insertions(+), 2103 deletions(-) create mode 100644 src/Cuemon.Core/MutableTuple.cs rename src/Cuemon.Core/{TemplateFactory.cs => MutableTupleFactory.cs} (73%) delete mode 100644 src/Cuemon.Core/Template.cs create mode 100644 test/Cuemon.Core.Tests/MutableTupleTest.cs rename test/{Cuemon.Core.Tests/TemplateTest.cs => Cuemon.Extensions.Core.Tests/MutableTupleFactoryTest.cs} (86%) diff --git a/src/Cuemon.Core/MutableTuple.cs b/src/Cuemon.Core/MutableTuple.cs new file mode 100644 index 000000000..67a560f65 --- /dev/null +++ b/src/Cuemon.Core/MutableTuple.cs @@ -0,0 +1,1272 @@ +using System; +using Cuemon.Collections.Generic; + +namespace Cuemon +{ + /// + /// Represents a with an empty value. + /// + public class MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + public MutableTuple() + { + } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public virtual object[] ToArray() + { + return Array.Empty(); + } + + /// + /// Returns an array of objects that represent the arguments passed to this instance concatenated with the specified . + /// + /// The additional arguments to concatenate with the objects that represent the arguments passed to this instance. + /// An array of objects that represent the arguments passed to this instance concatenated with the specified . + public object[] ToArray(params object[] additionalArgs) + { + return Arguments.Concat(ToArray(), additionalArgs); + } + + /// + /// Gets a value indicating whether this is empty. + /// + /// true if this is empty; otherwise, false. + public virtual bool IsEmpty => true; + + /// + /// Returns a that represents this instance. + /// + /// A that represents this instance. + public override string ToString() + { + return DelimitedString.Create(ToArray(), o => + { + o.Delimiter = ", "; + o.StringConverter = i => Generate.ObjectPortrayal(i); + }); + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public virtual MutableTuple Clone() + { + return new MutableTuple(); + } + } + + /// + /// Represents a with a single generic value. + /// + /// The type of the first parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the parameter of this . + public MutableTuple(T1 arg1) + { + Arg1 = arg1; + } + + /// + /// Gets or sets the first parameter of this instance. + /// + /// The first parameter of this instance. + public T1 Arg1 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1 }; + } + + /// + /// Gets a value indicating whether this is empty. + /// + /// true if this is empty; otherwise, false. + public override bool IsEmpty => false; + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1); + } + } + + /// + /// Represents a with two generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + public MutableTuple(T1 arg1, T2 arg2) : base(arg1) + { + Arg2 = arg2; + } + + /// + /// Gets or sets the second parameter of this instance. + /// + /// The second parameter of this instance. + public T2 Arg2 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2); + } + } + + /// + /// Represents a with three generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3) : base(arg1, arg2) + { + Arg3 = arg3; + } + + /// + /// Gets or sets the third parameter of this instance. + /// + /// The third parameter of this instance. + public T3 Arg3 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3); + } + } + + /// + /// Represents a with four generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4) : base(arg1, arg2, arg3) + { + Arg4 = arg4; + } + + /// + /// Gets or sets the fourth parameter of this instance. + /// + /// The fourth parameter of this instance. + public T4 Arg4 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4); + } + } + + /// + /// Represents a with five generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5) : base(arg1, arg2, arg3, arg4) + { + Arg5 = arg5; + } + + /// + /// Gets or sets the fifth parameter of this instance. + /// + /// The fifth parameter of this instance. + public T5 Arg5 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5); + } + } + + /// + /// Represents a with six generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6) : base(arg1, arg2, arg3, arg4, arg5) + { + Arg6 = arg6; + } + + /// + /// Gets or sets the sixth parameter of this instance. + /// + /// The sixth parameter of this instance. + public T6 Arg6 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6); + } + } + + /// + /// Represents a with seven generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7) : base(arg1, arg2, arg3, arg4, arg5, arg6) + { + Arg7 = arg7; + } + + /// + /// Gets or sets the seventh parameter of this instance. + /// + /// The seventh parameter of this instance. + public T7 Arg7 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7); + } + } + + /// + /// Represents a with eight generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7) + { + Arg8 = arg8; + } + + /// + /// Gets or sets the eighth parameter of this instance. + /// + /// The eighth parameter of this instance. + public T8 Arg8 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8); + } + } + + /// + /// Represents a with nine generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + /// The type of the ninth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + /// The value of the ninth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) + { + Arg9 = arg9; + } + + /// + /// Gets or sets the ninth parameter of this instance. + /// + /// The ninth parameter of this instance. + public T9 Arg9 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9); + } + } + + /// + /// Represents a with ten generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + /// The type of the ninth parameter of this . + /// The type of the tenth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + /// The value of the ninth parameter of this . + /// The value of the tenth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) + { + Arg10 = arg10; + } + + /// + /// Gets or sets the tenth parameter of this instance. + /// + /// The tenth parameter of this instance. + public T10 Arg10 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10); + } + } + + /// + /// Represents a with eleven generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + /// The type of the ninth parameter of this . + /// The type of the tenth parameter of this . + /// The type of the eleventh parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + /// The value of the ninth parameter of this . + /// The value of the tenth parameter of this . + /// The value of the eleventh parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10) + { + Arg11 = arg11; + } + + /// + /// Gets or sets the eleventh parameter of this instance. + /// + /// The eleventh parameter of this instance. + public T11 Arg11 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11); + } + } + + /// + /// Represents a with twelve generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + /// The type of the ninth parameter of this . + /// The type of the tenth parameter of this . + /// The type of the eleventh parameter of this . + /// The type of the twelfth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + /// The value of the ninth parameter of this . + /// The value of the tenth parameter of this . + /// The value of the eleventh parameter of this . + /// The value of the twelfth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11) + { + Arg12 = arg12; + } + + /// + /// Gets or sets the twelfth parameter of this instance. + /// + /// The twelfth parameter of this instance. + public T12 Arg12 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12); + } + } + + /// + /// Represents a with thirteen generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + /// The type of the ninth parameter of this . + /// The type of the tenth parameter of this . + /// The type of the eleventh parameter of this . + /// The type of the twelfth parameter of this . + /// The type of the thirteenth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + /// The value of the ninth parameter of this . + /// The value of the tenth parameter of this . + /// The value of the eleventh parameter of this . + /// The value of the twelfth parameter of this . + /// The value of the thirteenth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12) + { + Arg13 = arg13; + } + + /// + /// Gets or sets the thirteenth parameter of this instance. + /// + /// The thirteenth parameter of this instance. + public T13 Arg13 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13); + } + } + + /// + /// Represents a with fourteen generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + /// The type of the ninth parameter of this . + /// The type of the tenth parameter of this . + /// The type of the eleventh parameter of this . + /// The type of the twelfth parameter of this . + /// The type of the thirteenth parameter of this . + /// The type of the fourteenth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + /// The value of the ninth parameter of this . + /// The value of the tenth parameter of this . + /// The value of the eleventh parameter of this . + /// The value of the twelfth parameter of this . + /// The value of the thirteenth parameter of this . + /// The value of the fourteenth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13) + { + Arg14 = arg14; + } + + /// + /// Gets or sets the fourteenth parameter of this instance. + /// + /// The fourteenth parameter of this instance. + public T14 Arg14 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14); + } + } + + /// + /// Represents a with fifteen generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + /// The type of the ninth parameter of this . + /// The type of the tenth parameter of this . + /// The type of the eleventh parameter of this . + /// The type of the twelfth parameter of this . + /// The type of the thirteenth parameter of this . + /// The type of the fourteenth parameter of this . + /// The type of the fifteenth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + /// The value of the ninth parameter of this . + /// The value of the tenth parameter of this . + /// The value of the eleventh parameter of this . + /// The value of the twelfth parameter of this . + /// The value of the thirteenth parameter of this . + /// The value of the fourteenth parameter of this . + /// The value of the fifteenth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14) + { + Arg15 = arg15; + } + + /// + /// Gets or sets the fifteenth parameter of this instance. + /// + /// The fifteenth parameter of this instance. + public T15 Arg15 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15); + } + } + + /// + /// Represents a with sixteen generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + /// The type of the ninth parameter of this . + /// The type of the tenth parameter of this . + /// The type of the eleventh parameter of this . + /// The type of the twelfth parameter of this . + /// The type of the thirteenth parameter of this . + /// The type of the fourteenth parameter of this . + /// The type of the fifteenth parameter of this . + /// The type of the sixteenth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + /// The value of the ninth parameter of this . + /// The value of the tenth parameter of this . + /// The value of the eleventh parameter of this . + /// The value of the twelfth parameter of this . + /// The value of the thirteenth parameter of this . + /// The value of the fourteenth parameter of this . + /// The value of the fifteenth parameter of this . + /// The value of the sixteenth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15) + { + Arg16 = arg16; + } + + /// + /// Gets or sets the sixteenth parameter of this instance. + /// + /// The sixteenth parameter of this instance. + public T16 Arg16 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16); + } + } + + /// + /// Represents a with seventeen generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + /// The type of the ninth parameter of this . + /// The type of the tenth parameter of this . + /// The type of the eleventh parameter of this . + /// The type of the twelfth parameter of this . + /// The type of the thirteenth parameter of this . + /// The type of the fourteenth parameter of this . + /// The type of the fifteenth parameter of this . + /// The type of the sixteenth parameter of this . + /// The type of the seventeenth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + /// The value of the ninth parameter of this . + /// The value of the tenth parameter of this . + /// The value of the eleventh parameter of this . + /// The value of the twelfth parameter of this . + /// The value of the thirteenth parameter of this . + /// The value of the fourteenth parameter of this . + /// The value of the fifteenth parameter of this . + /// The value of the sixteenth parameter of this . + /// The value of the seventeenth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16, T17 arg17) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16) + { + Arg17 = arg17; + } + + /// + /// Gets or sets the seventeenth parameter of this instance. + /// + /// The seventeenth parameter of this instance. + public T17 Arg17 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17); + } + } + + /// + /// Represents a with eighteen generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + /// The type of the ninth parameter of this . + /// The type of the tenth parameter of this . + /// The type of the eleventh parameter of this . + /// The type of the twelfth parameter of this . + /// The type of the thirteenth parameter of this . + /// The type of the fourteenth parameter of this . + /// The type of the fifteenth parameter of this . + /// The type of the sixteenth parameter of this . + /// The type of the seventeenth parameter of this . + /// The type of the eighteenth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + /// The value of the ninth parameter of this . + /// The value of the tenth parameter of this . + /// The value of the eleventh parameter of this . + /// The value of the twelfth parameter of this . + /// The value of the thirteenth parameter of this . + /// The value of the fourteenth parameter of this . + /// The value of the fifteenth parameter of this . + /// The value of the sixteenth parameter of this . + /// The value of the seventeenth parameter of this . + /// The value of the eighteenth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16, T17 arg17, T18 arg18) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17) + { + Arg18 = arg18; + } + + /// + /// Gets or sets the eighteenth parameter of this instance. + /// + /// The eighteenth parameter of this instance. + public T18 Arg18 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18); + } + } + + /// + /// Represents a with nineteen generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + /// The type of the ninth parameter of this . + /// The type of the tenth parameter of this . + /// The type of the eleventh parameter of this . + /// The type of the twelfth parameter of this . + /// The type of the thirteenth parameter of this . + /// The type of the fourteenth parameter of this . + /// The type of the fifteenth parameter of this . + /// The type of the sixteenth parameter of this . + /// The type of the seventeenth parameter of this . + /// The type of the eighteenth parameter of this . + /// The type of the nineteenth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + /// The value of the ninth parameter of this . + /// The value of the tenth parameter of this . + /// The value of the eleventh parameter of this . + /// The value of the twelfth parameter of this . + /// The value of the thirteenth parameter of this . + /// The value of the fourteenth parameter of this . + /// The value of the fifteenth parameter of this . + /// The value of the sixteenth parameter of this . + /// The value of the seventeenth parameter of this . + /// The value of the eighteenth parameter of this . + /// The value of the nineteenth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16, T17 arg17, T18 arg18, T19 arg19) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17, arg18) + { + Arg19 = arg19; + } + + /// + /// Gets or sets the nineteenth parameter of this instance. + /// + /// The nineteenth parameter of this instance. + public T19 Arg19 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18, Arg19 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18, Arg19); + } + } + + /// + /// Represents a with twenty generic values. + /// + /// The type of the first parameter of this . + /// The type of the second parameter of this . + /// The type of the third parameter of this . + /// The type of the fourth parameter of this . + /// The type of the fifth parameter of this . + /// The type of the sixth parameter of this . + /// The type of the seventh parameter of this . + /// The type of the eighth parameter of this . + /// The type of the ninth parameter of this . + /// The type of the tenth parameter of this . + /// The type of the eleventh parameter of this . + /// The type of the twelfth parameter of this . + /// The type of the thirteenth parameter of this . + /// The type of the fourteenth parameter of this . + /// The type of the fifteenth parameter of this . + /// The type of the sixteenth parameter of this . + /// The type of the seventeenth parameter of this . + /// The type of the eighteenth parameter of this . + /// The type of the nineteenth parameter of this . + /// The type of the twentieth parameter of this . + public class MutableTuple : MutableTuple + { + /// + /// Initializes a new instance of the class. + /// + /// The value of the first parameter of this . + /// The value of the second parameter of this . + /// The value of the third parameter of this . + /// The value of the fourth parameter of this . + /// The value of the fifth parameter of this . + /// The value of the sixth parameter of this . + /// The value of the seventh parameter of this . + /// The value of the eighth parameter of this . + /// The value of the ninth parameter of this . + /// The value of the tenth parameter of this . + /// The value of the eleventh parameter of this . + /// The value of the twelfth parameter of this . + /// The value of the thirteenth parameter of this . + /// The value of the fourteenth parameter of this . + /// The value of the fifteenth parameter of this . + /// The value of the sixteenth parameter of this . + /// The value of the seventeenth parameter of this . + /// The value of the eighteenth parameter of this . + /// The value of the nineteenth parameter of this . + /// The value of the twentieth parameter of this . + public MutableTuple(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16, T17 arg17, T18 arg18, T19 arg19, T20 arg20) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17, arg18, arg19) + { + Arg20 = arg20; + } + + /// + /// Gets or sets the twentieth parameter of this instance. + /// + /// The twentieth parameter of this instance. + public T20 Arg20 { get; set; } + + /// + /// Returns an array of objects that represent the arguments passed to this instance. + /// + /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. + public override object[] ToArray() + { + return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18, Arg19, Arg20 }; + } + + /// + /// Creates a shallow copy of the current object. + /// + /// A new that is a copy of this instance. + /// When thread safety is required this is the method to invoke. + public override MutableTuple Clone() + { + return new MutableTuple(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18, Arg19, Arg20); + } + } +} diff --git a/src/Cuemon.Core/TemplateFactory.cs b/src/Cuemon.Core/MutableTupleFactory.cs similarity index 73% rename from src/Cuemon.Core/TemplateFactory.cs rename to src/Cuemon.Core/MutableTupleFactory.cs index 7b4b994fd..db2888bc5 100644 --- a/src/Cuemon.Core/TemplateFactory.cs +++ b/src/Cuemon.Core/MutableTupleFactory.cs @@ -7,15 +7,15 @@ namespace Cuemon /// /// Provides a base-class for delegate based factories. /// - /// The type of the n-tuple representation of a . - public abstract class TemplateFactory where TTuple : Template + /// The type of the n-tuple representation of a . + public abstract class MutableTupleFactory where TTuple : MutableTuple { /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class. /// - /// Then-tuple representation of a . + /// The n-tuple representation of a . /// true if this instance has a valid delegate; otherwise, false. - protected TemplateFactory(TTuple tuple, bool hasDelegate) + protected MutableTupleFactory(TTuple tuple, bool hasDelegate) { Validator.ThrowIfNull(tuple); GenericArguments = tuple; @@ -23,9 +23,9 @@ protected TemplateFactory(TTuple tuple, bool hasDelegate) } /// - /// Gets a n-tuple representation of a that represents the generic arguments passed to this instance. + /// Gets a n-tuple representation of a that represents the generic arguments passed to this instance. /// - /// The n-tuple representation of a that represents the generic arguments passed to this instance. + /// The n-tuple representation of a that represents the generic arguments passed to this instance. public TTuple GenericArguments { get; } /// @@ -67,10 +67,10 @@ protected void ThrowIfNoValidDelegate(bool delegateIsNull) } /// - /// Creates a shallow copy of the current object. + /// Creates a shallow copy of the current object. /// - /// A new implementation that is a copy of this instance. + /// A new implementation that is a copy of this instance. /// When thread safety is required this is the method to invoke. - public abstract TemplateFactory Clone(); + public abstract MutableTupleFactory Clone(); } -} \ No newline at end of file +} diff --git a/src/Cuemon.Core/Template.cs b/src/Cuemon.Core/Template.cs deleted file mode 100644 index e46c81ede..000000000 --- a/src/Cuemon.Core/Template.cs +++ /dev/null @@ -1,1958 +0,0 @@ -using System; -using Cuemon.Collections.Generic; - -namespace Cuemon -{ - /// - /// Represents a with an empty value. - /// - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template - { - /// - /// Creates a new 0-tuple, or empty tuple, representation of a . - /// - /// A 0-tuple (empty) with no value. - public static Template CreateZero() - { - return new Template(); - } - - /// - /// Creates a new 1-tuple, or single, representation of a . - /// - /// The type of the only parameter of the tuple. - /// The value of the only parameter of the tuple. - /// A 1-tuple (single) whose value is (arg1). - public static Template CreateOne(T arg) - { - return new Template(arg); - } - - /// - /// Creates a new 2-tuple, or double, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// A 2-tuple (double) whose value is (arg1, arg2). - public static Template CreateTwo(T1 arg1, T2 arg2) - { - return new Template(arg1, arg2); - } - - /// - /// Creates a new 3-tuple, or triple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// A 3-tuple (triple) whose value is (arg1, arg2, arg3). - public static Template CreateThree(T1 arg1, T2 arg2, T3 arg3) - { - return new Template(arg1, arg2, arg3); - } - - /// - /// Creates a new 4-tuple, or quadruple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// A 4-tuple (quadruple) whose value is (arg1, arg2, arg3, arg4). - public static Template CreateFour(T1 arg1, T2 arg2, T3 arg3, T4 arg4) - { - return new Template(arg1, arg2, arg3, arg4); - } - - /// - /// Creates a new 5-tuple, or quintuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// A 5-tuple (quintuple) whose value is (arg1, arg2, arg3, arg4, arg5). - public static Template CreateFive(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5) - { - return new Template(arg1, arg2, arg3, arg4, arg5); - } - - /// - /// Creates a new 6-tuple, or septuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// A 6-tuple (sextuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6). - public static Template CreateSix(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6); - } - - /// - /// Creates a new 7-tuple, or septuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// An 7-tuple (septuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7). - public static Template CreateSeven(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7); - } - - /// - /// Creates a new 8-tuple, or octuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// An 8-tuple (octuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8). - public static Template CreateEight(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8); - } - - /// - /// Creates a new 9-tuple, or nonuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The type of the ninth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// The value of the ninth parameter of the tuple. - /// A 9-tuple (nonuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9). - public static Template CreateNine(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9); - } - - /// - /// Creates a new 10-tuple, or decuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The type of the ninth parameter of the tuple. - /// The type of the tenth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// The value of the ninth parameter of the tuple. - /// The value of the tenth parameter of the tuple. - /// A 10-tuple (decuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10). - public static Template CreateTen(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10); - } - - /// - /// Creates a new 11-tuple, or undecuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The type of the ninth parameter of the tuple. - /// The type of the tenth parameter of the tuple. - /// The type of the eleventh parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// The value of the ninth parameter of the tuple. - /// The value of the tenth parameter of the tuple. - /// The value of the eleventh parameter of the tuple. - /// A 11-tuple (undecuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11). - public static Template CreateEleven(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11); - } - - /// - /// Creates a new 12-tuple, or duodecuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The type of the ninth parameter of the tuple. - /// The type of the tenth parameter of the tuple. - /// The type of the eleventh parameter of the tuple. - /// The type of the twelfth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// The value of the ninth parameter of the tuple. - /// The value of the tenth parameter of the tuple. - /// The value of the eleventh parameter of the tuple. - /// The value of the twelfth parameter of the tuple. - /// A 12-tuple (duodecuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12). - public static Template CreateTwelve(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12); - } - - /// - /// Creates a new 13-tuple, or tredecuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The type of the ninth parameter of the tuple. - /// The type of the tenth parameter of the tuple. - /// The type of the eleventh parameter of the tuple. - /// The type of the twelfth parameter of the tuple. - /// The type of the thirteenth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// The value of the ninth parameter of the tuple. - /// The value of the tenth parameter of the tuple. - /// The value of the eleventh parameter of the tuple. - /// The value of the twelfth parameter of the tuple. - /// The value of the thirteenth parameter of the tuple. - /// A 13-tuple (tredecuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13). - public static Template CreateThirteen(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13); - } - - /// - /// Creates a new 14-tuple, or quattuordecuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The type of the ninth parameter of the tuple. - /// The type of the tenth parameter of the tuple. - /// The type of the eleventh parameter of the tuple. - /// The type of the twelfth parameter of the tuple. - /// The type of the thirteenth parameter of the tuple. - /// The type of the fourteenth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// The value of the ninth parameter of the tuple. - /// The value of the tenth parameter of the tuple. - /// The value of the eleventh parameter of the tuple. - /// The value of the twelfth parameter of the tuple. - /// The value of the thirteenth parameter of the tuple. - /// The value of the fourteenth parameter of the tuple. - /// A 14-tuple (quattuordecuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14). - public static Template CreateFourteen(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14); - } - - /// - /// Creates a new 15-tuple, or quindecuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The type of the ninth parameter of the tuple. - /// The type of the tenth parameter of the tuple. - /// The type of the eleventh parameter of the tuple. - /// The type of the twelfth parameter of the tuple. - /// The type of the thirteenth parameter of the tuple. - /// The type of the fourteenth parameter of the tuple. - /// The type of the fifteenth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// The value of the ninth parameter of the tuple. - /// The value of the tenth parameter of the tuple. - /// The value of the eleventh parameter of the tuple. - /// The value of the twelfth parameter of the tuple. - /// The value of the thirteenth parameter of the tuple. - /// The value of the fourteenth parameter of the tuple. - /// The value of the fifteenth parameter of the tuple. - /// A 15-tuple (quindecuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15). - public static Template CreateFifteen(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15); - } - - /// - /// Creates a new 16-tuple, or sexdecuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The type of the ninth parameter of the tuple. - /// The type of the tenth parameter of the tuple. - /// The type of the eleventh parameter of the tuple. - /// The type of the twelfth parameter of the tuple. - /// The type of the thirteenth parameter of the tuple. - /// The type of the fourteenth parameter of the tuple. - /// The type of the fifteenth parameter of the tuple. - /// The type of the sixteenth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// The value of the ninth parameter of the tuple. - /// The value of the tenth parameter of the tuple. - /// The value of the eleventh parameter of the tuple. - /// The value of the twelfth parameter of the tuple. - /// The value of the thirteenth parameter of the tuple. - /// The value of the fourteenth parameter of the tuple. - /// The value of the fifteenth parameter of the tuple. - /// The value of the sixteenth parameter of the tuple. - /// A 16-tuple (sexdecuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16). - public static Template CreateSixteen(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16); - } - - /// - /// Creates a new 17-tuple, or septendecuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The type of the ninth parameter of the tuple. - /// The type of the tenth parameter of the tuple. - /// The type of the eleventh parameter of the tuple. - /// The type of the twelfth parameter of the tuple. - /// The type of the thirteenth parameter of the tuple. - /// The type of the fourteenth parameter of the tuple. - /// The type of the fifteenth parameter of the tuple. - /// The type of the sixteenth parameter of the tuple. - /// The type of the seventeenth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// The value of the ninth parameter of the tuple. - /// The value of the tenth parameter of the tuple. - /// The value of the eleventh parameter of the tuple. - /// The value of the twelfth parameter of the tuple. - /// The value of the thirteenth parameter of the tuple. - /// The value of the fourteenth parameter of the tuple. - /// The value of the fifteenth parameter of the tuple. - /// The value of the sixteenth parameter of the tuple. - /// The value of the seventeenth parameter of the tuple. - /// A 17-tuple (septendecuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17). - public static Template CreateSeventeen(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16, T17 arg17) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17); - } - - /// - /// Creates a new 18-tuple, or octodecuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The type of the ninth parameter of the tuple. - /// The type of the tenth parameter of the tuple. - /// The type of the eleventh parameter of the tuple. - /// The type of the twelfth parameter of the tuple. - /// The type of the thirteenth parameter of the tuple. - /// The type of the fourteenth parameter of the tuple. - /// The type of the fifteenth parameter of the tuple. - /// The type of the sixteenth parameter of the tuple. - /// The type of the seventeenth parameter of the tuple. - /// The type of the eighteenth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// The value of the ninth parameter of the tuple. - /// The value of the tenth parameter of the tuple. - /// The value of the eleventh parameter of the tuple. - /// The value of the twelfth parameter of the tuple. - /// The value of the thirteenth parameter of the tuple. - /// The value of the fourteenth parameter of the tuple. - /// The value of the fifteenth parameter of the tuple. - /// The value of the sixteenth parameter of the tuple. - /// The value of the seventeenth parameter of the tuple. - /// The value of the eighteenth parameter of the tuple. - /// An 18-tuple (octodecuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17, arg18). - public static Template CreateEighteen(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16, T17 arg17, T18 arg18) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17, arg18); - } - - /// - /// Creates a new 19-tuple, or novemdecuple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The type of the ninth parameter of the tuple. - /// The type of the tenth parameter of the tuple. - /// The type of the eleventh parameter of the tuple. - /// The type of the twelfth parameter of the tuple. - /// The type of the thirteenth parameter of the tuple. - /// The type of the fourteenth parameter of the tuple. - /// The type of the fifteenth parameter of the tuple. - /// The type of the sixteenth parameter of the tuple. - /// The type of the seventeenth parameter of the tuple. - /// The type of the eighteenth parameter of the tuple. - /// The type of the nineteenth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// The value of the ninth parameter of the tuple. - /// The value of the tenth parameter of the tuple. - /// The value of the eleventh parameter of the tuple. - /// The value of the twelfth parameter of the tuple. - /// The value of the thirteenth parameter of the tuple. - /// The value of the fourteenth parameter of the tuple. - /// The value of the fifteenth parameter of the tuple. - /// The value of the sixteenth parameter of the tuple. - /// The value of the seventeenth parameter of the tuple. - /// The value of the eighteenth parameter of the tuple. - /// The value of the nineteenth parameter of the tuple. - /// A 19-tuple (novemdecuple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17, arg18, arg19). - public static Template CreateNineteen(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16, T17 arg17, T18 arg18, T19 arg19) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17, arg18, arg19); - } - - /// - /// Creates a new 20-tuple, or viguple, representation of a . - /// - /// The type of the first parameter of the tuple. - /// The type of the second parameter of the tuple. - /// The type of the third parameter of the tuple. - /// The type of the fourth parameter of the tuple. - /// The type of the fifth parameter of the tuple. - /// The type of the sixth parameter of the tuple. - /// The type of the seventh parameter of the tuple. - /// The type of the eighth parameter of the tuple. - /// The type of the ninth parameter of the tuple. - /// The type of the tenth parameter of the tuple. - /// The type of the eleventh parameter of the tuple. - /// The type of the twelfth parameter of the tuple. - /// The type of the thirteenth parameter of the tuple. - /// The type of the fourteenth parameter of the tuple. - /// The type of the fifteenth parameter of the tuple. - /// The type of the sixteenth parameter of the tuple. - /// The type of the seventeenth parameter of the tuple. - /// The type of the eighteenth parameter of the tuple. - /// The type of the nineteenth parameter of the tuple. - /// The type of the twentieth parameter of the tuple. - /// The value of the first parameter of the tuple. - /// The value of the second parameter of the tuple. - /// The value of the third parameter of the tuple. - /// The value of the fourth parameter of the tuple. - /// The value of the fifth parameter of the tuple. - /// The value of the sixth parameter of the tuple. - /// The value of the seventh parameter of the tuple. - /// The value of the eighth parameter of the tuple. - /// The value of the ninth parameter of the tuple. - /// The value of the tenth parameter of the tuple. - /// The value of the eleventh parameter of the tuple. - /// The value of the twelfth parameter of the tuple. - /// The value of the thirteenth parameter of the tuple. - /// The value of the fourteenth parameter of the tuple. - /// The value of the fifteenth parameter of the tuple. - /// The value of the sixteenth parameter of the tuple. - /// The value of the seventeenth parameter of the tuple. - /// The value of the eighteenth parameter of the tuple. - /// The value of the nineteenth parameter of the tuple. - /// The value of the twentieth parameter of the tuple. - /// A 20-tuple (viguple) whose value is (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17, arg18, arg19, arg20). - public static Template CreateTwenty(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16, T17 arg17, T18 arg18, T19 arg19, T20 arg20) - { - return new Template(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17, arg18, arg19, arg20); - } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public virtual object[] ToArray() - { - return Array.Empty(); - } - - /// - /// Returns an array of objects that represent the arguments passed to this instance concatenated with the specified . - /// - /// The additional arguments to concatenate with the objects that represent the arguments passed to this instance. - /// An array of objects that represent the arguments passed to this instance concatenated with the specified . - public object[] ToArray(params object[] additionalArgs) - { - return Arguments.Concat(ToArray(), additionalArgs); - } - - /// - /// Gets a value indicating whether this is empty. - /// - /// true if this is empty; otherwise, false. - public virtual bool IsEmpty => true; - - /// - /// Returns a that represents this instance. - /// - /// A that represents this instance. - public override string ToString() - { - return DelimitedString.Create(ToArray(), o => - { - o.Delimiter = ", "; - o.StringConverter = i => Generate.ObjectPortrayal(i); - }); - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public virtual Template Clone() - { - return new Template(); - } - } - - /// - /// Represents a with a single generic value. - /// - /// The type of the first parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the parameter of this . - public Template(T1 arg1) - { - Arg1 = arg1; - } - - /// - /// Gets or sets the first parameter of this instance. - /// - /// The first parameter of this instance. - public T1 Arg1 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1 }; - } - - /// - /// Gets a value indicating whether this is empty. - /// - /// true if this is empty; otherwise, false. - public override bool IsEmpty => false; - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1); - } - } - - /// - /// Represents a with two generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - public Template(T1 arg1, T2 arg2) : base(arg1) - { - Arg2 = arg2; - } - - /// - /// Gets or sets the second parameter of this instance. - /// - /// The second parameter of this instance. - public T2 Arg2 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2); - } - } - - /// - /// Represents a with three generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3) : base(arg1, arg2) - { - Arg3 = arg3; - } - - /// - /// Gets or sets the third parameter of this instance. - /// - /// The third parameter of this instance. - public T3 Arg3 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3); - } - } - - /// - /// Represents a with four generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4) : base(arg1, arg2, arg3) - { - Arg4 = arg4; - } - - /// - /// Gets or sets the fourth parameter of this instance. - /// - /// The fourth parameter of this instance. - public T4 Arg4 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4); - } - } - - /// - /// Represents a with five generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5) : base(arg1, arg2, arg3, arg4) - { - Arg5 = arg5; - } - - /// - /// Gets or sets the fifth parameter of this instance. - /// - /// The fifth parameter of this instance. - public T5 Arg5 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5); - } - } - - /// - /// Represents a with six generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6) : base(arg1, arg2, arg3, arg4, arg5) - { - Arg6 = arg6; - } - - /// - /// Gets or sets the sixth parameter of this instance. - /// - /// The sixth parameter of this instance. - public T6 Arg6 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6); - } - } - - /// - /// Represents a with seven generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7) : base(arg1, arg2, arg3, arg4, arg5, arg6) - { - Arg7 = arg7; - } - - /// - /// Gets or sets the seventh parameter of this instance. - /// - /// The seventh parameter of this instance. - public T7 Arg7 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7); - } - } - - /// - /// Represents a with eight generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7) - { - Arg8 = arg8; - } - - /// - /// Gets or sets the eighth parameter of this instance. - /// - /// The eighth parameter of this instance. - public T8 Arg8 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8); - } - } - - /// - /// Represents a with nine generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// The type of the ninth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - /// The value of the ninth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) - { - Arg9 = arg9; - } - - /// - /// Gets or sets the ninth parameter of this instance. - /// - /// The ninth parameter of this instance. - public T9 Arg9 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9); - } - } - - /// - /// Represents a with ten generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// The type of the ninth parameter of this . - /// The type of the tenth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - /// The value of the ninth parameter of this . - /// The value of the tenth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) - { - Arg10 = arg10; - } - - /// - /// Gets or sets the tenth parameter of this instance. - /// - /// The tenth parameter of this instance. - public T10 Arg10 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10); - } - } - - /// - /// Represents a with eleven generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// The type of the ninth parameter of this . - /// The type of the tenth parameter of this . - /// The type of the eleventh parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - /// The value of the ninth parameter of this . - /// The value of the tenth parameter of this . - /// The value of the eleventh parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10) - { - Arg11 = arg11; - } - - /// - /// Gets or sets the eleventh parameter of this instance. - /// - /// The eleventh parameter of this instance. - public T11 Arg11 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11); - } - } - - /// - /// Represents a with twelve generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// The type of the ninth parameter of this . - /// The type of the tenth parameter of this . - /// The type of the eleventh parameter of this . - /// The type of the twelfth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - /// The value of the ninth parameter of this . - /// The value of the tenth parameter of this . - /// The value of the eleventh parameter of this . - /// The value of the twelfth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11) - { - Arg12 = arg12; - } - - /// - /// Gets or sets the twelfth parameter of this instance. - /// - /// The twelfth parameter of this instance. - public T12 Arg12 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12); - } - } - - /// - /// Represents a with thirteen generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// The type of the ninth parameter of this . - /// The type of the tenth parameter of this . - /// The type of the eleventh parameter of this . - /// The type of the twelfth parameter of this . - /// The type of the thirteenth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - /// The value of the ninth parameter of this . - /// The value of the tenth parameter of this . - /// The value of the eleventh parameter of this . - /// The value of the twelfth parameter of this . - /// The value of the thirteenth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12) - { - Arg13 = arg13; - } - - /// - /// Gets or sets the thirteenth parameter of this instance. - /// - /// The thirteenth parameter of this instance. - public T13 Arg13 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13); - } - } - - /// - /// Represents a with fourteen generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// The type of the ninth parameter of this . - /// The type of the tenth parameter of this . - /// The type of the eleventh parameter of this . - /// The type of the twelfth parameter of this . - /// The type of the thirteenth parameter of this . - /// The type of the fourteenth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - /// The value of the ninth parameter of this . - /// The value of the tenth parameter of this . - /// The value of the eleventh parameter of this . - /// The value of the twelfth parameter of this . - /// The value of the thirteenth parameter of this . - /// The value of the fourteenth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13) - { - Arg14 = arg14; - } - - /// - /// Gets or sets the fourteenth parameter of this instance. - /// - /// The fourteenth parameter of this instance. - public T14 Arg14 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14); - } - } - - /// - /// Represents a with fifteen generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// The type of the ninth parameter of this . - /// The type of the tenth parameter of this . - /// The type of the eleventh parameter of this . - /// The type of the twelfth parameter of this . - /// The type of the thirteenth parameter of this . - /// The type of the fourteenth parameter of this . - /// The type of the fifteenth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - /// The value of the ninth parameter of this . - /// The value of the tenth parameter of this . - /// The value of the eleventh parameter of this . - /// The value of the twelfth parameter of this . - /// The value of the thirteenth parameter of this . - /// The value of the fourteenth parameter of this . - /// The value of the fifteenth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14) - { - Arg15 = arg15; - } - - /// - /// Gets or sets the fifteenth parameter of this instance. - /// - /// The fifteenth parameter of this instance. - public T15 Arg15 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15); - } - } - - /// - /// Represents a with sixteen generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// The type of the ninth parameter of this . - /// The type of the tenth parameter of this . - /// The type of the eleventh parameter of this . - /// The type of the twelfth parameter of this . - /// The type of the thirteenth parameter of this . - /// The type of the fourteenth parameter of this . - /// The type of the fifteenth parameter of this . - /// The type of the sixteenth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - /// The value of the ninth parameter of this . - /// The value of the tenth parameter of this . - /// The value of the eleventh parameter of this . - /// The value of the twelfth parameter of this . - /// The value of the thirteenth parameter of this . - /// The value of the fourteenth parameter of this . - /// The value of the fifteenth parameter of this . - /// The value of the sixteenth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15) - { - Arg16 = arg16; - } - - /// - /// Gets or sets the sixteenth parameter of this instance. - /// - /// The sixteenth parameter of this instance. - public T16 Arg16 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16); - } - } - - /// - /// Represents a with seventeen generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// The type of the ninth parameter of this . - /// The type of the tenth parameter of this . - /// The type of the eleventh parameter of this . - /// The type of the twelfth parameter of this . - /// The type of the thirteenth parameter of this . - /// The type of the fourteenth parameter of this . - /// The type of the fifteenth parameter of this . - /// The type of the sixteenth parameter of this . - /// The type of the seventeenth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - /// The value of the ninth parameter of this . - /// The value of the tenth parameter of this . - /// The value of the eleventh parameter of this . - /// The value of the twelfth parameter of this . - /// The value of the thirteenth parameter of this . - /// The value of the fourteenth parameter of this . - /// The value of the fifteenth parameter of this . - /// The value of the sixteenth parameter of this . - /// The value of the seventeenth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16, T17 arg17) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16) - { - Arg17 = arg17; - } - - /// - /// Gets or sets the seventeenth parameter of this instance. - /// - /// The seventeenth parameter of this instance. - public T17 Arg17 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17); - } - } - - /// - /// Represents a with eighteen generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// The type of the ninth parameter of this . - /// The type of the tenth parameter of this . - /// The type of the eleventh parameter of this . - /// The type of the twelfth parameter of this . - /// The type of the thirteenth parameter of this . - /// The type of the fourteenth parameter of this . - /// The type of the fifteenth parameter of this . - /// The type of the sixteenth parameter of this . - /// The type of the seventeenth parameter of this . - /// The type of the eighteenth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - /// The value of the ninth parameter of this . - /// The value of the tenth parameter of this . - /// The value of the eleventh parameter of this . - /// The value of the twelfth parameter of this . - /// The value of the thirteenth parameter of this . - /// The value of the fourteenth parameter of this . - /// The value of the fifteenth parameter of this . - /// The value of the sixteenth parameter of this . - /// The value of the seventeenth parameter of this . - /// The value of the eighteenth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16, T17 arg17, T18 arg18) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17) - { - Arg18 = arg18; - } - - /// - /// Gets or sets the eighteenth parameter of this instance. - /// - /// The eighteenth parameter of this instance. - public T18 Arg18 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18); - } - } - - /// - /// Represents a with nineteen generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// The type of the ninth parameter of this . - /// The type of the tenth parameter of this . - /// The type of the eleventh parameter of this . - /// The type of the twelfth parameter of this . - /// The type of the thirteenth parameter of this . - /// The type of the fourteenth parameter of this . - /// The type of the fifteenth parameter of this . - /// The type of the sixteenth parameter of this . - /// The type of the seventeenth parameter of this . - /// The type of the eighteenth parameter of this . - /// The type of the nineteenth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - /// The value of the ninth parameter of this . - /// The value of the tenth parameter of this . - /// The value of the eleventh parameter of this . - /// The value of the twelfth parameter of this . - /// The value of the thirteenth parameter of this . - /// The value of the fourteenth parameter of this . - /// The value of the fifteenth parameter of this . - /// The value of the sixteenth parameter of this . - /// The value of the seventeenth parameter of this . - /// The value of the eighteenth parameter of this . - /// The value of the nineteenth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16, T17 arg17, T18 arg18, T19 arg19) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17, arg18) - { - Arg19 = arg19; - } - - /// - /// Gets or sets the nineteenth parameter of this instance. - /// - /// The nineteenth parameter of this instance. - public T19 Arg19 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18, Arg19 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18, Arg19); - } - } - - /// - /// Represents a with twenty generic values. - /// - /// The type of the first parameter of this . - /// The type of the second parameter of this . - /// The type of the third parameter of this . - /// The type of the fourth parameter of this . - /// The type of the fifth parameter of this . - /// The type of the sixth parameter of this . - /// The type of the seventh parameter of this . - /// The type of the eighth parameter of this . - /// The type of the ninth parameter of this . - /// The type of the tenth parameter of this . - /// The type of the eleventh parameter of this . - /// The type of the twelfth parameter of this . - /// The type of the thirteenth parameter of this . - /// The type of the fourteenth parameter of this . - /// The type of the fifteenth parameter of this . - /// The type of the sixteenth parameter of this . - /// The type of the seventeenth parameter of this . - /// The type of the eighteenth parameter of this . - /// The type of the nineteenth parameter of this . - /// The type of the twentieth parameter of this . - /// - /// Inspired by Tuple objects, Template, was chosen because of the naming conflict in newer version of the .NET Framework. - /// The name, Template, was inspired by the Variadic Template in C++. - /// - public class Template : Template - { - /// - /// Initializes a new instance of the class. - /// - /// The value of the first parameter of this . - /// The value of the second parameter of this . - /// The value of the third parameter of this . - /// The value of the fourth parameter of this . - /// The value of the fifth parameter of this . - /// The value of the sixth parameter of this . - /// The value of the seventh parameter of this . - /// The value of the eighth parameter of this . - /// The value of the ninth parameter of this . - /// The value of the tenth parameter of this . - /// The value of the eleventh parameter of this . - /// The value of the twelfth parameter of this . - /// The value of the thirteenth parameter of this . - /// The value of the fourteenth parameter of this . - /// The value of the fifteenth parameter of this . - /// The value of the sixteenth parameter of this . - /// The value of the seventeenth parameter of this . - /// The value of the eighteenth parameter of this . - /// The value of the nineteenth parameter of this . - /// The value of the twentieth parameter of this . - public Template(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16, T17 arg17, T18 arg18, T19 arg19, T20 arg20) : base(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, arg14, arg15, arg16, arg17, arg18, arg19) - { - Arg20 = arg20; - } - - /// - /// Gets or sets the twentieth parameter of this instance. - /// - /// The twentieth parameter of this instance. - public T20 Arg20 { get; set; } - - /// - /// Returns an array of objects that represent the arguments passed to this instance. - /// - /// An array of objects that represent the arguments passed to this instance. Returns an empty array if the current instance was constructed with no generic arguments. - public override object[] ToArray() - { - return new object[] { Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18, Arg19, Arg20 }; - } - - /// - /// Creates a shallow copy of the current object. - /// - /// A new that is a copy of this instance. - /// When thread safety is required this is the method to invoke. - public override Template Clone() - { - return new Template(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18, Arg19, Arg20); - } - } -} \ No newline at end of file diff --git a/src/Cuemon.Core/Threading/AsyncActionFactory.cs b/src/Cuemon.Core/Threading/AsyncActionFactory.cs index 075096cc9..bf4e6bc17 100644 --- a/src/Cuemon.Core/Threading/AsyncActionFactory.cs +++ b/src/Cuemon.Core/Threading/AsyncActionFactory.cs @@ -5,10 +5,10 @@ namespace Cuemon.Threading { /// - /// Provides an easy way of invoking an delegate regardless of the amount of parameters provided. + /// Provides a way of invoking an delegate regardless of the amount of parameters provided. /// - /// The type of the n-tuple representation of a . - public sealed class AsyncActionFactory : TemplateFactory where TTuple : Template + /// The type of the n-tuple representation of a . + public sealed class AsyncActionFactory : MutableTupleFactory where TTuple : MutableTuple { /// /// Initializes a new instance of the class. @@ -60,7 +60,7 @@ public Task ExecuteMethodAsync(CancellationToken ct) /// /// A new that is a copy of this instance. /// When thread safety is required this is the method to invoke. - public override TemplateFactory Clone() + public override MutableTupleFactory Clone() { return new AsyncActionFactory(Method, GenericArguments.Clone() as TTuple); } diff --git a/src/Cuemon.Core/Threading/AsyncFuncFactory.cs b/src/Cuemon.Core/Threading/AsyncFuncFactory.cs index 312e959b5..17ebc8240 100644 --- a/src/Cuemon.Core/Threading/AsyncFuncFactory.cs +++ b/src/Cuemon.Core/Threading/AsyncFuncFactory.cs @@ -5,11 +5,11 @@ namespace Cuemon.Threading { /// - /// Provides an easy way of invoking an function delegate regardless of the amount of parameters provided. + /// Provides a way of invoking an function delegate regardless of the amount of parameters provided. /// - /// The type of the n-tuple representation of a . + /// The type of the n-tuple representation of a . /// The type of the return value of the function delegate . - public sealed class AsyncFuncFactory : TemplateFactory where TTuple : Template + public sealed class AsyncFuncFactory : MutableTupleFactory where TTuple : MutableTuple { /// /// Initializes a new instance of the class. @@ -61,7 +61,7 @@ public Task ExecuteMethodAsync(CancellationToken ct) /// /// A new that is a copy of this instance. /// When thread safety is required this is the method to invoke. - public override TemplateFactory Clone() + public override MutableTupleFactory Clone() { return new AsyncFuncFactory(Method, GenericArguments.Clone() as TTuple); } diff --git a/src/Cuemon.Diagnostics/TimeMeasure.Async.cs b/src/Cuemon.Diagnostics/TimeMeasure.Async.cs index 59f1d6d22..1535cd2de 100644 --- a/src/Cuemon.Diagnostics/TimeMeasure.Async.cs +++ b/src/Cuemon.Diagnostics/TimeMeasure.Async.cs @@ -560,7 +560,7 @@ public static Task> WithFuncAsync WithActionAsyncCore(AsyncActionFactory factory, Action setup) where TTuple : Template + private static async Task WithActionAsyncCore(AsyncActionFactory factory, Action setup) where TTuple : MutableTuple { var options = Patterns.Configure(setup); var descriptor = options.MethodDescriptor?.Invoke() ?? new MethodDescriptor(factory.DelegateInfo); @@ -573,7 +573,7 @@ private static async Task WithActionAsyncCore(Async return profiler; } - private static async Task> WithFunctionAsyncCore(AsyncFuncFactory factory, Action setup) where TTuple : Template + private static async Task> WithFunctionAsyncCore(AsyncFuncFactory factory, Action setup) where TTuple : MutableTuple { var options = Patterns.Configure(setup); var descriptor = options.MethodDescriptor?.Invoke() ?? new MethodDescriptor(factory.DelegateInfo); diff --git a/src/Cuemon.Net/Mail/MailDistributor.cs b/src/Cuemon.Net/Mail/MailDistributor.cs index c8c6136cd..9d9c10f22 100644 --- a/src/Cuemon.Net/Mail/MailDistributor.cs +++ b/src/Cuemon.Net/Mail/MailDistributor.cs @@ -89,13 +89,13 @@ private static async Task SendAsync(Func carrierCallback, List, List>> PrepareShipment(MailDistributor distributor, IEnumerable mails, Func filter) + private static List, List>> PrepareShipment(MailDistributor distributor, IEnumerable mails, Func filter) { var partitionedMails = new PartitionerEnumerable(mails, distributor.DeliverySize); - var carriers = new List, List>>(); + var carriers = new List, List>>(); while (partitionedMails.HasPartitions) { - carriers.Add(Template.CreateTwo(distributor.Carrier, new List(filter == null + carriers.Add(new MutableTuple, List>(distributor.Carrier, new List(filter == null ? partitionedMails : partitionedMails.Where(filter) ))); @@ -103,4 +103,4 @@ private static List, List>> PrepareShipme return carriers; } } -} \ No newline at end of file +} diff --git a/src/Cuemon.Resilience/TransientOperation.Async.cs b/src/Cuemon.Resilience/TransientOperation.Async.cs index a073f4c24..6f004d195 100644 --- a/src/Cuemon.Resilience/TransientOperation.Async.cs +++ b/src/Cuemon.Resilience/TransientOperation.Async.cs @@ -391,12 +391,12 @@ public static Task WithActionAsync(Func(AsyncActionFactory factory, Action setup) where TTuple : Template + private static Task WithActionAsyncCore(AsyncActionFactory factory, Action setup) where TTuple : MutableTuple { return new AsyncActionTransientWorker(factory.DelegateInfo, factory.GenericArguments.ToArray(), setup).ResilientActionAsync(factory.ExecuteMethodAsync); } - private static Task WithFuncAsyncCore(AsyncFuncFactory factory, Action setup) where TTuple : Template + private static Task WithFuncAsyncCore(AsyncFuncFactory factory, Action setup) where TTuple : MutableTuple { return new AsyncFuncTransientWorker(factory.DelegateInfo, factory.GenericArguments.ToArray(), setup).ResilientFuncAsync(factory.ExecuteMethodAsync); } diff --git a/src/Cuemon.Threading/ActionForEachSynchronousLoop.cs b/src/Cuemon.Threading/ActionForEachSynchronousLoop.cs index 79795293b..1027d47a4 100644 --- a/src/Cuemon.Threading/ActionForEachSynchronousLoop.cs +++ b/src/Cuemon.Threading/ActionForEachSynchronousLoop.cs @@ -14,7 +14,7 @@ public ActionForEachSynchronousLoop(IEnumerable source, Action Partitioner { get; set; } - protected override void FillWorkQueueWorkerFactory(TemplateFactory worker, long sorter) + protected override void FillWorkQueueWorkerFactory(MutableTupleFactory worker, long sorter) { if (worker is ActionFactory wf) { wf.ExecuteMethod(); } } diff --git a/src/Cuemon.Threading/ActionForSynchronousLoop.cs b/src/Cuemon.Threading/ActionForSynchronousLoop.cs index 54fc8ce61..44467fd8b 100644 --- a/src/Cuemon.Threading/ActionForSynchronousLoop.cs +++ b/src/Cuemon.Threading/ActionForSynchronousLoop.cs @@ -8,7 +8,7 @@ public ActionForSynchronousLoop(ForLoopRuleset rules, Action(TemplateFactory worker) + protected override void FillWorkQueueWorkerFactory(MutableTupleFactory worker) { if (worker is ActionFactory wf) { wf.ExecuteMethod(); } } diff --git a/src/Cuemon.Threading/ActionWhileSynchronousLoop.cs b/src/Cuemon.Threading/ActionWhileSynchronousLoop.cs index dd831f0bd..4016e1433 100644 --- a/src/Cuemon.Threading/ActionWhileSynchronousLoop.cs +++ b/src/Cuemon.Threading/ActionWhileSynchronousLoop.cs @@ -9,7 +9,7 @@ public ActionWhileSynchronousLoop(ForwardIterator iterator, Ac } - protected override void FillWorkQueueWorkerFactory(TemplateFactory worker, long sorter) + protected override void FillWorkQueueWorkerFactory(MutableTupleFactory worker, long sorter) { if (worker is ActionFactory wf) { wf.ExecuteMethod(); } } diff --git a/src/Cuemon.Threading/AdvancedParallelFactory.ForAsync.cs b/src/Cuemon.Threading/AdvancedParallelFactory.ForAsync.cs index 426dc8ae7..77e7e971d 100644 --- a/src/Cuemon.Threading/AdvancedParallelFactory.ForAsync.cs +++ b/src/Cuemon.Threading/AdvancedParallelFactory.ForAsync.cs @@ -158,7 +158,7 @@ public static Task ForAsync(ForLoopRuleset(ForLoopRuleset rules, AsyncActionFactory workerFactory, Action setup) - where TWorker : Template + where TWorker : MutableTuple where TOperand : struct, IComparable, IEquatable, IConvertible { var from = rules.From; diff --git a/src/Cuemon.Threading/AdvancedParallelFactory.ForResultAsync.cs b/src/Cuemon.Threading/AdvancedParallelFactory.ForResultAsync.cs index a5c2a52af..b0b11023c 100644 --- a/src/Cuemon.Threading/AdvancedParallelFactory.ForResultAsync.cs +++ b/src/Cuemon.Threading/AdvancedParallelFactory.ForResultAsync.cs @@ -174,7 +174,7 @@ public static Task> ForResultAsync> ForResultCoreAsync(ForLoopRuleset rules, AsyncFuncFactory workerFactory, Action setup) - where TWorker : Template + where TWorker : MutableTuple where TOperand : struct, IComparable, IEquatable, IConvertible { var from = rules.From; diff --git a/src/Cuemon.Threading/AdvancedParallelFactory.WhileAsync.cs b/src/Cuemon.Threading/AdvancedParallelFactory.WhileAsync.cs index 4f0d310ac..7c6967db5 100644 --- a/src/Cuemon.Threading/AdvancedParallelFactory.WhileAsync.cs +++ b/src/Cuemon.Threading/AdvancedParallelFactory.WhileAsync.cs @@ -152,7 +152,7 @@ public static Task WhileAsync(TReader rea } private static async Task WhileCoreAsync(AsyncForwardIterator iterator, AsyncActionFactory workerFactory, Action setup) - where TWorker : Template + where TWorker : MutableTuple { var options = Patterns.Configure(setup); var readForward = true; diff --git a/src/Cuemon.Threading/AdvancedParallelFactory.WhileResultAsync.cs b/src/Cuemon.Threading/AdvancedParallelFactory.WhileResultAsync.cs index e7a568619..b2f65c0d5 100644 --- a/src/Cuemon.Threading/AdvancedParallelFactory.WhileResultAsync.cs +++ b/src/Cuemon.Threading/AdvancedParallelFactory.WhileResultAsync.cs @@ -167,7 +167,7 @@ public static Task> WhileResultAsync> WhileResultCoreAsync(AsyncForwardIterator iterator, AsyncFuncFactory workerFactory, Action setup) - where TWorker : Template + where TWorker : MutableTuple { var options = Patterns.Configure(setup); var result = new ConcurrentDictionary(); diff --git a/src/Cuemon.Threading/AsyncActionFactory.cs b/src/Cuemon.Threading/AsyncActionFactory.cs index e3ba5f77a..4242656a4 100644 --- a/src/Cuemon.Threading/AsyncActionFactory.cs +++ b/src/Cuemon.Threading/AsyncActionFactory.cs @@ -14,9 +14,9 @@ public static class AsyncActionFactory /// /// The based function delegate to invoke. /// An instance of object initialized with the specified . - public static AsyncActionFactory