001/***************************************************************************** 002 * Copyright by The HDF Group. * 003 * Copyright by the Board of Trustees of the University of Illinois. * 004 * All rights reserved. * 005 * * 006 * This file is part of the HDF Java Products distribution. * 007 * The full copyright notice, including terms governing use, modification, * 008 * and redistribution, is contained in the files COPYING and Copyright.html. * 009 * COPYING can be found at the root of the source code distribution tree. * 010 * Or, see http://hdfgroup.org/products/hdf-java/doc/Copyright.html. * 011 * If you do not have access to either file, you may request a copy from * 012 * help@hdfgroup.org. * 013 ****************************************************************************/ 014 015package hdf.view; 016 017import java.awt.Image; 018import java.awt.Rectangle; 019 020/** 021 * The image view interface for displaying image object 022 * 023 * @author Peter X. Cao 024 * @version 2.4 9/6/2007 025 */ 026public abstract interface ImageView extends DataView { 027 /** 028 * returns the selected area of the image 029 * 030 * @return the rectangle of the selected image area. 031 */ 032 public abstract Rectangle getSelectedArea(); 033 034 /** @return true if the image is a truecolor image. */ 035 public abstract boolean isTrueColor(); 036 037 /** @return true if the image interlace is plance interlace. */ 038 public abstract boolean isPlaneInterlace(); 039 040 /** returns array of selected data */ 041 public abstract Object getSelectedData(); 042 043 /** returns the image displayed in this imageView */ 044 public abstract Image getImage(); 045 046 /** sets the image */ 047 public abstract void setImage(Image img); 048 049 /** returns the palette of the image */ 050 public abstract byte[][] getPalette(); 051 052 /** sets the image palette */ 053 public abstract void setPalette(byte[][] palette); 054 055 /** returns the byte array of the image data */ 056 public abstract byte[] getImageByteData(); 057 058}