< prev index next >

src/java.desktop/share/classes/com/sun/imageio/plugins/wbmp/WBMPImageReader.java

Print this page

        

@@ -75,41 +75,46 @@
     public WBMPImageReader(ImageReaderSpi originator) {
         super(originator);
     }
 
     /** Overrides the method defined in the superclass. */
+    @Override
     public void setInput(Object input,
                          boolean seekForwardOnly,
                          boolean ignoreMetadata) {
         super.setInput(input, seekForwardOnly, ignoreMetadata);
         iis = (ImageInputStream) input; // Always works
         gotHeader = false;
     }
 
     /** Overrides the method defined in the superclass. */
+    @Override
     public int getNumImages(boolean allowSearch) throws IOException {
         if (iis == null) {
             throw new IllegalStateException(I18N.getString("GetNumImages0"));
         }
         if (seekForwardOnly && allowSearch) {
             throw new IllegalStateException(I18N.getString("GetNumImages1"));
         }
         return 1;
     }
 
+    @Override
     public int getWidth(int imageIndex) throws IOException {
         checkIndex(imageIndex);
         readHeader();
         return width;
     }
 
+    @Override
     public int getHeight(int imageIndex) throws IOException {
         checkIndex(imageIndex);
         readHeader();
         return height;
     }
 
+    @Override
     public boolean isRandomAccessEasy(int imageIndex) throws IOException {
         checkIndex(imageIndex);
         return true;
     }
 

@@ -150,10 +155,11 @@
         metadata.height = height;
 
         gotHeader = true;
     }
 
+    @Override
     public Iterator<ImageTypeSpecifier> getImageTypes(int imageIndex)
         throws IOException {
         checkIndex(imageIndex);
         readHeader();
 

@@ -162,27 +168,31 @@
         ArrayList<ImageTypeSpecifier> list = new ArrayList<>(1);
         list.add(new ImageTypeSpecifier(bi));
         return list.iterator();
     }
 
+    @Override
     public ImageReadParam getDefaultReadParam() {
         return new ImageReadParam();
     }
 
+    @Override
     public IIOMetadata getImageMetadata(int imageIndex)
         throws IOException {
         checkIndex(imageIndex);
         if (metadata == null) {
             readHeader();
         }
         return metadata;
     }
 
+    @Override
     public IIOMetadata getStreamMetadata() throws IOException {
         return null;
     }
 
+    @Override
     public BufferedImage read(int imageIndex, ImageReadParam param)
         throws IOException {
 
         if (iis == null) {
             throw new IllegalStateException(I18N.getString("WBMPImageReader1"));

@@ -294,20 +304,23 @@
         else
             processImageComplete();
         return bi;
     }
 
+    @Override
     public boolean canReadRaster() {
         return true;
     }
 
+    @Override
     public Raster readRaster(int imageIndex,
                              ImageReadParam param) throws IOException {
         BufferedImage bi = read(imageIndex, param);
         return bi.getData();
     }
 
+    @Override
     public void reset() {
         super.reset();
         iis = null;
         gotHeader = false;
     }
< prev index next >