@@ -21,8 +21,11 @@ namespace Microsoft.Data.Analysis
21
21
where T : unmanaged
22
22
{
23
23
<# foreach (MethodConfiguration method in methodConfiguration) { #>
24
- <# if (method.MethodType == MethodType.Comparison || method.MethodType == MethodType.ComparisonScalar) { #>
25
- PrimitiveColumnContainer<bool> <#=method.MethodName#>(<#=method.GetMethodArguments("PrimitiveColumnContainer", "T")#>);
24
+ <# if (method.MethodType == MethodType.Comparison) { #>
25
+ PrimitiveColumnContainer<bool> <#=method.MethodName#>(PrimitiveColumnContainer<T> left, PrimitiveColumnContainer<T> right);
26
+ <# } #>
27
+ <# else if (method.MethodType == MethodType.ComparisonScalar) { #>
28
+ PrimitiveColumnContainer<bool> <#=method.MethodName#>(PrimitiveColumnContainer<T> column, T scalar);
26
29
<# } #>
27
30
<# else if (method.MethodType == MethodType.Binary) { #>
28
31
void <#=method.MethodName#>(PrimitiveColumnContainer<T> left, PrimitiveColumnContainer<T> right);
@@ -61,15 +64,27 @@ namespace Microsoft.Data.Analysis
61
64
internal class <#=type.ClassPrefix#>Arithmetic : IPrimitiveDataFrameColumnArithmetic<<#=type.TypeName#>>
62
65
{
63
66
<# foreach (MethodConfiguration method in methodConfiguration) { #>
64
- <# if (method.MethodType == MethodType.Comparison || method.MethodType == MethodType.ComparisonScalar ) { #>
67
+ <# if (method.MethodType == MethodType.Comparison) { #>
65
68
66
- public PrimitiveColumnContainer<bool> <#=method.MethodName#>(<#=method.GetMethodArguments("PrimitiveColumnContainer", type.TypeName)#> )
67
- {
68
- <#} else { #>
69
+ public PrimitiveColumnContainer<bool> <#=method.MethodName#>(PrimitiveColumnContainer<<#=type.TypeName#>> left, PrimitiveColumnContainer<<#= type.TypeName#>> right )
70
+ <# } #>
71
+ <# else if (method.MethodType == MethodType.ComparisonScalar) { #>
69
72
70
- public void <#=method.MethodName#>(<#=method.GetMethodArguments("PrimitiveColumnContainer", type.TypeName)#>)
71
- {
73
+ public PrimitiveColumnContainer<bool> <#=method.MethodName#>(PrimitiveColumnContainer<<#=type.TypeName#>> column, <#=type.TypeName#> scalar)
74
+ <# } #>
75
+ <# else if (method.MethodType == MethodType.Binary) { #>
76
+
77
+ public void <#=method.MethodName#>(PrimitiveColumnContainer<<#=type.TypeName#>> left, PrimitiveColumnContainer<<#=type.TypeName#>> right)
78
+ <# } #>
79
+ <# else if (method.MethodType == MethodType.BinaryScalar) { #>
80
+
81
+ public void <#=method.MethodName#>(PrimitiveColumnContainer<<#=type.TypeName#>> column, <#=type.TypeName#> scalar)
72
82
<# } #>
83
+ <# else if (method.MethodType == MethodType.BinaryInt) { #>
84
+
85
+ public void <#=method.MethodName#>(PrimitiveColumnContainer<<#=type.TypeName#>> column, int value)
86
+ <# } #>
87
+ {
73
88
<# if ((method.IsNumeric && !type.SupportsNumeric) || (method.IsBitwise && !type.SupportsBitwise) || (type.UnsupportedMethods.Contains(method.MethodName))) { #>
74
89
throw new NotSupportedException();
75
90
<# } else if (method.Operator != null) { #>
0 commit comments