edu.wisc.ssec.mcidasv.ui
Class McIdasColorTableManager

java.lang.Object
  extended by ucar.unidata.util.ResourceManager
      extended by ucar.unidata.ui.colortable.ColorTableManager
          extended by edu.wisc.ssec.mcidasv.ui.McIdasColorTableManager

public class McIdasColorTableManager
extends ColorTableManager

A class to manage Hydra color tables


Field Summary
static String CATEGORY_HYDRA
          The color table category
static PatternFileFilter FILTER_ET
          File filter used for McIDAS-X "enhancement files"
static PatternFileFilter FILTER_HYDRA
          File filter used for "HYDRA" color tables
 
Fields inherited from class ucar.unidata.ui.colortable.ColorTableManager
FILTER_ACT, FILTER_GEM, FILTER_IDV, FILTER_MCI, FILTER_PAL, NAME_DEFAULT, PROP_CANCEL, PROP_CLOSE, PROP_COLORTABLE, PROP_RANGE, TAG_COLORTABLE, TAG_COLORTABLES, TAG_NAME
 
Fields inherited from class ucar.unidata.util.ResourceManager
listOfResourceLists, log_, LU, nameToObject, PROP_RESOURCECHANGE, PROP_RESOURCEREMOVE, resources, usersList, writablePath
 
Constructor Summary
McIdasColorTableManager()
          Create me
 
Method Summary
 NamedObject doImport(boolean makeUnique)
          Import a color table
 List getReadFileFilters()
          Return the file filters used for writing a file on an import
private  boolean isGempakFile(String file)
          Is the given file a Gempak file
 void makeColorTableMenu(ObjectListener listener, List l)
          Filles the given list with menu items that represent that available color tables.
private  List processSpecial(String file, String name, String category)
          Try to load in one of the special colortables
 
Methods inherited from class ucar.unidata.ui.colortable.ColorTableManager
doExport, edit, getCategories, getColorTable, getColorTables, getDefaultColorTable, getExportContents, getLabel, getManager, getTitle, getWriteFileFilters, initResource, main, makeColorTableMenu, setManager
 
Methods inherited from class ucar.unidata.util.ResourceManager
addPropertyChangeListener, addUsers, doExport, doImport, doImport, doNew, doNew, doNew, doSaveAs, firePropertyChange, firePropertyChange, getDefault, getEncoder, getFileFilters, getFileSuffix, getObject, getResources, getResourceTimestamp, getUsersIndex, getUsersObject, hasUsers, init, initDone, isUsers, processObject, reloadResources, removePropertyChangeListener, removeUsers, resourceExists, shouldWeIgnoreThisXml, toObject, toObject
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CATEGORY_HYDRA

public static final String CATEGORY_HYDRA
The color table category

See Also:
Constant Field Values

FILTER_HYDRA

public static final PatternFileFilter FILTER_HYDRA
File filter used for "HYDRA" color tables


FILTER_ET

public static final PatternFileFilter FILTER_ET
File filter used for McIDAS-X "enhancement files"

Constructor Detail

McIdasColorTableManager

public McIdasColorTableManager()
Create me

Method Detail

makeColorTableMenu

public void makeColorTableMenu(ObjectListener listener,
                               List l)
Filles the given list with menu items that represent that available color tables. Overridden in McIDAS-V to force the presence of the "" tag.

Overrides:
makeColorTableMenu in class ColorTableManager

getReadFileFilters

public List getReadFileFilters()
Return the file filters used for writing a file on an import

Overrides:
getReadFileFilters in class ColorTableManager
Returns:
Read file filters

doImport

public NamedObject doImport(boolean makeUnique)
Import a color table

Overrides:
doImport in class ColorTableManager
Parameters:
makeUnique - If true then we change the name of the color table so it is unique
Returns:
The imported color table

processSpecial

private List processSpecial(String file,
                            String name,
                            String category)
                     throws IOException
Try to load in one of the special colortables

Parameters:
file - file
name - _more_
category - category
Returns:
the ct
Throws:
IOException - _more_

isGempakFile

private boolean isGempakFile(String file)
Is the given file a Gempak file

Parameters:
file - The file name to check
Returns:
Is it a Gempak file