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 COPYING file, which can be found * 009 * at the root of the source code distribution tree, * 010 * or in https://www.hdfgroup.org/licenses. * 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.DataView; 016 017import hdf.object.HObject; 018import hdf.view.TreeView.TreeView; 019 020/** 021 * 022 * Defines a list of APIs for the main HDFView windows 023 * 024 * @author Peter X. Cao 025 * @version 2.4 9/6/2007 026 */ 027public abstract interface DataViewManager { 028 /** 029 * Data content is displayed, add the dataview to the main windows 030 * @param dataView 031 * the dataView whose presence in the main view is to be added. 032 */ 033 public abstract void addDataView(DataView dataView); 034 035 /** 036 * Data content is closed, remove the dataview from the main window 037 * @param dataView 038 * the dataView whose presence in the main view is to be removed. 039 */ 040 public abstract void removeDataView(DataView dataView); 041 042 /** 043 * Returns DataView that contains the specified data object. It is useful to 044 * avoid redundant display of data object that is opened already. 045 * 046 * @param dataObject 047 * the object whose presence in the main view is to be tested. 048 * 049 * @return DataView contains the specified data object, null if the data 050 * object is not displayed. 051 */ 052 public abstract DataView getDataView(HObject dataObject); 053 054 /** 055 * Display feedback message 056 * 057 * @param msg 058 * the status message to display 059 */ 060 public abstract void showStatus(String msg); 061 062 /** 063 * Display error message 064 * 065 * @param errMsg 066 * the error message to display 067 */ 068 public abstract void showError(String errMsg); 069 070 /** 071 * Get the current TreeView 072 * 073 * @return the current TreeView 074 */ 075 public abstract TreeView getTreeView(); 076 077 /** 078 * Start stop a timer. 079 * 080 * @param toggleTimer 081 * -- true: start timer, false stop timer. 082 */ 083 public abstract void executeTimer(boolean toggleTimer); 084}