commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [commons-imaging] christoffer-rydberg commented on a change in pull request #55: [IMAGING-236] Add support to read multiple images from GIF
Date Sat, 02 Nov 2019 13:34:49 GMT
christoffer-rydberg commented on a change in pull request #55: [IMAGING-236] Add support to
read multiple images from GIF
URL: https://github.com/apache/commons-imaging/pull/55#discussion_r341811398
 
 

 ##########
 File path: src/main/java/org/apache/commons/imaging/formats/gif/GifImageParser.java
 ##########
 @@ -439,6 +439,16 @@ private GifBlock findBlock(final List<GifBlock> blocks, final
int code) {
         return null;
     }
 
+    private <T extends GifBlock> List<T> findAllBlocks(final List<GifBlock>
blocks, final int code) {
+        final List<T> filteredBlocks = new ArrayList<>();
+        for (final GifBlock gifBlock : blocks) {
+            if (gifBlock.blockCode == code) {
+                filteredBlocks.add((T) gifBlock);
 
 Review comment:
   I think that sounds good. I'll add the comment and suppress the warning.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message