hackergin commented on code in PR #24183:
URL: https://github.com/apache/flink/pull/24183#discussion_r1468995720


##########
flink-table/flink-table-common/src/main/java/org/apache/flink/table/types/extraction/BaseMappingExtractor.java:
##########
@@ -323,6 +327,37 @@ private void verifyMappingForMethod(
                         verification.verify(method, signature.toClass(), 
result.toClass()));
     }
 
+    private void verifyOptionalOnPrimitiveParameter(
+            Method method,
+            Map<FunctionSignatureTemplate, FunctionResultTemplate> 
collectedMappingsPerMethod) {
+
+        collectedMappingsPerMethod.forEach(
+                (signature, result) -> {
+                    Boolean[] argumentOptional = signature.argumentOptionals;
+                    if (argumentOptional != null
+                            && 
Arrays.stream(argumentOptional).anyMatch(Boolean::booleanValue)) {
+                        // do something check
+                        FunctionSignatureTemplate functionResultTemplate =

Review Comment:
   The main purpose here is to determine if there is an "optional" in 
FunctionHint while the actual method declaration is of primitive type, so it 
must be compared with the FunctionSignature generated by the method.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@flink.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to