xtern commented on code in PR #7630:
URL: https://github.com/apache/ignite-3/pull/7630#discussion_r2832316740


##########
modules/api/src/main/java/org/apache/ignite/table/TupleImpl.java:
##########
@@ -459,4 +464,122 @@ private <T> T valueNotNull(String columnName) {
 
         return value;
     }
+
+    /** Casts a {@link Number} to {@code byte}. */
+    private static byte castToByte(Object number) {

Review Comment:
   Unfortunately, `TupleImpl` is part of the public API module and can't depend 
on the `core` module.
   On the other hand, introducing a new helper class into the API module is the 
wrong approach, thus we will maintain the duplication, but this is covered by 
tests (see AbstractImmutableTupleTest, AbstractMutableTupleTest) they cover all 
tuple implementations.



##########
modules/api/src/main/java/org/apache/ignite/table/TupleImpl.java:
##########
@@ -459,4 +464,122 @@ private <T> T valueNotNull(String columnName) {
 
         return value;
     }
+
+    /** Casts a {@link Number} to {@code byte}. */
+    private static byte castToByte(Object number) {

Review Comment:
   Unfortunately, `TupleImpl` is part of the public API module and can't depend 
on the `core` module.
   On the other hand, introducing a new helper class into the API module is the 
wrong approach, thus we will maintain the duplication, but this is covered by 
tests (see `AbstractImmutableTupleTest`, `AbstractMutableTupleTest`) they cover 
all tuple implementations.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to