9 namespace Core.TypeCast
12 using System.Reflection;
13 using System.Runtime.InteropServices;
19 [StructLayout(LayoutKind.Sequential)]
44 : this(parameters: new[] { parameters?.First(), parameterOut, parameters?.Length > 1 ? parameters[1] : parameterOut } )
59 this.Count = parameters.Length;
60 this.In = Count > 0 ? parameters[0].ParameterType : null;
61 this.Out = Count > 1 ? parameters[1].ParameterType : null;
63 this.Arg = Count > 2 ? parameters[2].ParameterType : this.Out;
70 public Type[] ToArray()
72 return new[] { this.In, this.Out, this.Arg };
79 public override string ToString()
81 return $
"{nameof(ConverterParameters)}: (In:{this.In}, Out:{this.Out}, Arg:{this.Arg})";
Container with sequentially assigned type-parameters of a strictly typed Converter-Function, in the sequence of Types for: In, Out, Argument