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


##########
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:
   > Do we have tests to check that both implementations work the same?
   
   Yes, we have `AbstractImmutableTupleTest` with 5 child classes (including 
`TupleImplTest` and `SqlRowTest`).
   
   > Should we document the code duplication so we don't forget to update both 
parts?
   
   We have many Tuple implementations that should have the same behavior. I 
think having a single test point (AbstractImmutableTupleTest) is enough to 
ensure we don't forget to fix one implementation or another.
   
   If you still think this isn't enough and something needs to be specified in 
the javadoc, please give me an example.



-- 
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