|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectucar.unidata.ui.WindowHolder
ucar.unidata.idv.IdvManager
ucar.unidata.idv.IdvPersistenceManager
edu.wisc.ssec.mcidasv.PersistenceManager
public class PersistenceManager
McIDAS-V has 99 problems, and bundles are several of 'em. Since the UI of alpha 10 relies upon component groups and McIDAS-V needs to support IDV and bundles prior to alpha 10, we must add facilities for coping with bundles that may not contain component groups. Here's a list of the issues and how they are resolved:
TabbedUIManager
. Each tab
is, internally, an IDV window. This is reflected in the contents of bundles,
so the IDV wants to create a new window for each tab upon loading. Alpha 10
allows the user to force bundles to only create one window. This work is
done in injectComponentGroups(List)
.ViewManager
s with component groups and without!
This is actually only a problem when limiting the windows;
injectComponentGroups
has to wrap ViewManagers without
component groups in dynamic skins. These ViewManagers must be removed
from the bundle's internal list of ViewManagers, as they don't exist until
the dynamic skin is built. Do not simply clear the list! The
ViewManagers within component groups must appear in it, otherwise the IDV
does not add them to the VMManager
. If limiting
windows is off, everything will be caught properly by the unpersisting
facilities in UIManager
.
IdvPersistenceManager
,
UIManager
Nested Class Summary |
---|
Nested classes/interfaces inherited from class ucar.unidata.idv.IdvPersistenceManager |
---|
IdvPersistenceManager.DataSourceComponent |
Field Summary | |
---|---|
private static String |
ATTR_NAME
|
private boolean |
bundleLoading
Whether or not a bundle is actively loading. |
private static String |
DYNSKIN_ATTR_CLASS
|
private static String |
DYNSKIN_ATTR_COLS
|
private static String |
DYNSKIN_ATTR_ID
|
private static String |
DYNSKIN_ATTR_PROPS
|
private static String |
DYNSKIN_ATTR_ROWS
|
private static String |
DYNSKIN_ATTR_VIEWID
|
private static String |
DYNSKIN_ID_VALUE
|
private static String |
DYNSKIN_PROPS_GENERAL
|
private static String |
DYNSKIN_PROPS_GLOBE
|
private static String |
DYNSKIN_TAG_PANEL
|
private static String |
DYNSKIN_TAG_VIEW
|
private static String |
DYNSKIN_TMPNAME
|
static String |
ID_MCV_VERSION
Key used to access a bundle's McIDAS-V in-depth versioning info section. |
private ViewManager |
lastBeforeBundle
Stores the last active ViewManager from before a bundle load. |
private JRadioButton |
layoutOnlyRadio
Use radio buttons to control state saving |
private JRadioButton |
layoutSourcesDataRadio
|
private JRadioButton |
layoutSourcesRadio
|
(package private) static LogUtil.LogCategory |
log_
|
private static org.slf4j.Logger |
logger
|
static String |
MACRO_ZIDVPATH
Macro used as a place holder for wherever the IDV decides to place extracted contents of a bundle. |
private boolean |
mergeBundledLayers
Whether or not the user wants to attempt merging bundled layers into current displays. |
private static String |
NEW_COMP_STUFF
|
private static String |
NEW_SOURCE_MACRO
|
private static String |
OLD_COMP_STUFF
|
private static String |
OLD_SOURCE_MACRO
|
private XmlResourceCollection |
parameterSets
Cache the parameter sets XML |
private static Document |
parameterSetsDocument
|
private static Element |
parameterSetsRoot
|
private boolean |
savingDefaultLayout
Is the bundle being saved a layout bundle? |
private static String |
SIMPLE_SKIN_TEMPLATE
XML template for generating dynamic skins. |
private static String |
TAG_DEFAULT
|
private static String |
TAG_FOLDER
|
Fields inherited from class ucar.unidata.ui.WindowHolder |
---|
contents, dialog, frame, window |
Constructor Summary | |
---|---|
PersistenceManager()
Java requires this constructor. |
|
PersistenceManager(IntegratedDataViewer idv)
|
Method Summary | |
---|---|
boolean |
addParameterSetCategory(String parameterType,
String category)
Add the directory |
protected boolean |
addToBundle(Hashtable data,
List dataSources,
List displayControls,
List viewManagers,
String jython)
Overridden so that McIDAS-V can: add better versioning information to bundles remove ReadoutProbes from the displayControls that are getting persisted. |
protected List<WindowInfo> |
betterInject(List<WindowInfo> windows)
Builds an altered copy of windows that preserves the
number of windows while ensuring all displays are inside component
holders. |
static IdvWindow |
buildDynamicSkin(int width,
int height,
int rows,
int cols,
List<org.python.core.PyObject> panelTypes)
|
protected List<IdvComponentHolder> |
buildHolders(WindowInfo window)
Builds a list of component holders with all of window 's
displays. |
private void |
checkForBadMaps(String bundlePath)
|
void |
decodeXml(String xml,
boolean fromCollab,
String xmlFile,
String label,
boolean showDialog,
boolean shouldMerge,
Hashtable bundleProperties,
boolean removeAll,
boolean letUserChangeData)
Overridden so that McIDAS-V can redirect to the version of this method that supports limiting the number of new windows. |
void |
decodeXml(String xml,
boolean fromCollab,
String xmlFile,
String label,
boolean showDialog,
boolean shouldMerge,
Hashtable bundleProperties,
boolean removeAll,
boolean letUserChangeData,
boolean limitWindows)
Hijacks the second part of the IDV bundle loading pipeline so that McIDAS-V can limit the number of new windows. |
boolean |
decodeXmlFile(String xmlFile,
String label,
boolean checkToRemove,
boolean letUserChangeData,
Hashtable bundleProperties)
Hijacks control of the IDV's bundle loading facilities. |
protected void |
decodeXmlInner(String xml,
boolean fromCollab,
String xmlFile,
String label,
boolean showDialog,
boolean shouldMerge,
Hashtable bundleProperties,
boolean didRemoveAll,
boolean changeData)
Overridden so that McIDAS-V can redirect to the version of this method that supports limiting the number of new windows. |
protected void |
decodeXmlInner(String xml,
boolean fromCollab,
String xmlFile,
String label,
boolean showDialog,
boolean shouldMerge,
Hashtable bundleProperties,
boolean didRemoveAll,
boolean letUserChangeData,
boolean limitNewWindows)
Hijacks the third part of the bundle loading pipeline. |
void |
deleteParameterSet(String parameterType,
ParameterSet set)
Delete the given parameter set |
void |
deleteParameterSetCategory(String parameterType,
String category)
Delete the directory and all of its contents that the given category represents. |
void |
doSaveAs()
Have the user select an xidv filename and write the current application state to it. |
void |
doSaveAsDefaultLayout()
|
protected static List<ViewManager> |
extractCompGroupVMs(List<WindowInfo> windows)
Builds a list of an incoming bundle's ViewManager s that are part of a component
group. |
private void |
fixBulkDataSources(List<DataSourceImpl> ds)
Attempts to reconcile McIDAS-V's ability to easily load all files in a directory with the way the IDV expects file data sources to behave upon unpersistence. |
protected IdvComponentGroup |
flattenGroup(IdvComponentGroup nested)
|
protected void |
flattenWindows(List<WindowInfo> windows)
Alters windows so that no windows in the bundle contain
nested component groups. |
private List<ViewManager> |
generateViewManagers(List<DisplayControlImpl> controls)
|
List<String> |
getAllParameterSetCategories(String parameterType)
Get a list of all of the categories for the given parameterType |
List<ParameterSet> |
getAllParameterSets(String parameterType)
Get the list of ParameterSet s that are writable |
JPanel |
getFileAccessory()
Create, if needed, and return te GUI panel to put into the file dialog when saving a file. |
ViewManager |
getLastViewManager()
Returns the last active ViewManager from before loading
the most recent bundle. |
List |
getLocalBundles()
Create, if needed, and return the list of locally saved SavedBundle s |
boolean |
getMergeBundledLayers()
|
private Element |
getParameterTypeNode(String parameterType)
Get the node representing the parameterType |
boolean |
getSaveDataSources()
Should the data sources be saved |
boolean |
getSaveDisplays()
Should the displays be saved |
boolean |
getSaveJython()
Should the jython be saved |
boolean |
getSaveViewState()
Should the view state be saved |
protected List<WindowInfo> |
injectComponentGroups(List<WindowInfo> windows)
Builds a single window with a single component group. |
protected void |
instantiateFromBundle(Hashtable ht,
boolean fromCollab,
LoadBundleDialog loadDialog,
boolean shouldMerge,
Hashtable bundleProperties,
boolean didRemoveAll,
boolean letUserChangeData)
Overridden so that McIDAS-V can redirect to the version of this method that supports limiting the number of new windows. |
protected void |
instantiateFromBundle(Hashtable ht,
boolean fromCollab,
LoadBundleDialog loadDialog,
boolean shouldMerge,
Hashtable bundleProperties,
boolean didRemoveAll,
boolean letUserChangeData,
boolean limitNewWindows)
Overridden so that McIDAS-V can preempt the IDV's bundle loading. |
private boolean |
isBulkDataSource(DataSourceImpl d)
Attempts to determine whether or not a given DataSourceImpl is
the result of a McIDAS-V "bulk load". |
boolean |
isBundleLoading()
Returns whether or not a bundle is currently being loaded. |
protected void |
loadBundlesInDirectory(List<SavedBundle> allBundles,
List categories,
File file)
For each of of the bundle files in the given file directory create a SavedBundle object with the given categories list ad add it into the given allBundles list. |
McvComponentHolder |
makeDynSkin(WindowInfo info)
Uses the ViewManager s in info
to build a dynamic skin. |
List<ViewManager> |
mapDynamicSkins(List<WindowInfo> windows)
Builds a list of any dynamic skins in the bundle and adds them to the UIMananger's "cache" of encountered ViewManagers. |
void |
moveParameterSet(String parameterType,
ParameterSet set,
List categories)
Move the bundle to the given category area |
void |
moveParameterSetCategory(String parameterType,
List fromCategories,
List toCategories)
Move the bundle category |
protected static void |
populateEssentialLists(String[] ids,
Hashtable<String,Object> table)
Ensures that the lists corresponding to the ids in ids
actually exist in table , even if they are empty. |
protected static List<IdvComponentHolder> |
removeUIHolders(IdvComponentGroup group)
|
protected static List<WindowInfo> |
removeUIHolders(List<WindowInfo> windows)
Returns an altered copy of windows containing only
component holders that have displays. |
void |
renameParameterSet(String parameterType,
ParameterSet set)
Rename the parameter set |
protected void |
reverseCollisions(List<ViewManager> vms)
Does the work in fixing the collisions described in the instantiateFromBundle javadoc. |
boolean |
saveParameterSet(String parameterType,
Hashtable parameterValues)
Show the Save Parameter Set dialog |
private void |
setMergeBundledLayers(boolean newValue)
|
private List<WindowInfo> |
wrapViewManagers(List<ViewManager> vms)
|
void |
writeParameterSets()
Write the parameter sets |
Methods inherited from class ucar.unidata.ui.WindowHolder |
---|
actionPerformed, close, doMakeContents, getContents, getDialog, getFrame, getWindow, getWindowTitle, isShowing, removeAll, setMenuBar, setWindowTitle, shouldMakeDialog, show, show, showModal, toFront, windowIsClosing |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String ID_MCV_VERSION
private static final org.slf4j.Logger logger
public static final String MACRO_ZIDVPATH
static LogUtil.LogCategory log_
private boolean savingDefaultLayout
private ViewManager lastBeforeBundle
private boolean mergeBundledLayers
private boolean bundleLoading
private XmlResourceCollection parameterSets
private static Document parameterSetsDocument
private static Element parameterSetsRoot
private static final String TAG_FOLDER
private static final String TAG_DEFAULT
private static final String ATTR_NAME
private JRadioButton layoutOnlyRadio
private JRadioButton layoutSourcesRadio
private JRadioButton layoutSourcesDataRadio
private static final String OLD_COMP_STUFF
private static final String NEW_COMP_STUFF
private static final String OLD_SOURCE_MACRO
private static final String NEW_SOURCE_MACRO
private static final String DYNSKIN_TMPNAME
private static final String DYNSKIN_TAG_PANEL
private static final String DYNSKIN_TAG_VIEW
private static final String DYNSKIN_ATTR_ID
private static final String DYNSKIN_ATTR_COLS
private static final String DYNSKIN_ATTR_ROWS
private static final String DYNSKIN_ATTR_PROPS
private static final String DYNSKIN_ATTR_CLASS
private static final String DYNSKIN_ATTR_VIEWID
private static final String DYNSKIN_PROPS_GLOBE
private static final String DYNSKIN_PROPS_GENERAL
private static final String DYNSKIN_ID_VALUE
private static final String SIMPLE_SKIN_TEMPLATE
Constructor Detail |
---|
public PersistenceManager()
public PersistenceManager(IntegratedDataViewer idv)
IdvPersistenceManager.IdvPersistenceManager(IntegratedDataViewer)
Method Detail |
---|
public ViewManager getLastViewManager()
ViewManager
from before loading
the most recent bundle.
null
if there was no previous
ViewManager (such as loading a default bundle/layout).public boolean isBundleLoading()
true
if instantiateFromBundle
is doing
what it needs to do, or false
.instantiateFromBundle(Hashtable, boolean, LoadBundleDialog, boolean, Hashtable, boolean, boolean, boolean)
public boolean getMergeBundledLayers()
private void setMergeBundledLayers(boolean newValue)
public boolean getSaveDataSources()
ucar.unidata.idv.IdvPersistenceManager
getSaveDataSources
in class IdvPersistenceManager
public boolean getSaveDisplays()
ucar.unidata.idv.IdvPersistenceManager
getSaveDisplays
in class IdvPersistenceManager
public boolean getSaveViewState()
ucar.unidata.idv.IdvPersistenceManager
getSaveViewState
in class IdvPersistenceManager
public boolean getSaveJython()
ucar.unidata.idv.IdvPersistenceManager
getSaveJython
in class IdvPersistenceManager
public void doSaveAsDefaultLayout()
public JPanel getFileAccessory()
ucar.unidata.idv.IdvPersistenceManager
getFileAccessory
in class IdvPersistenceManager
public void doSaveAs()
doSaveAs
in class IdvPersistenceManager
protected boolean addToBundle(Hashtable data, List dataSources, List displayControls, List viewManagers, String jython)
ReadoutProbes
from the displayControls
that are getting persisted.
addToBundle
in class IdvPersistenceManager
data
- Holds the bundle statedataSources
- List of data sources to adddisplayControls
- List of displays to addviewManagers
- List of view managers to addjython
- jython to add
public List getLocalBundles()
ucar.unidata.idv.IdvPersistenceManager
SavedBundle
s
getLocalBundles
in class IdvPersistenceManager
protected void loadBundlesInDirectory(List<SavedBundle> allBundles, List categories, File file)
ucar.unidata.idv.IdvPersistenceManager
loadBundlesInDirectory
in class IdvPersistenceManager
allBundles
- The list to put the bundles incategories
- Categories for the SavedBundle objectsfile
- Where to lookpublic void decodeXml(String xml, boolean fromCollab, String xmlFile, String label, boolean showDialog, boolean shouldMerge, Hashtable bundleProperties, boolean removeAll, boolean letUserChangeData)
Overridden so that McIDAS-V can redirect to the version of this method that supports limiting the number of new windows.
decodeXml
in class IdvPersistenceManager
xml
- The bundle xmlfromCollab
- Was this bundle from the collaboration facility.
If it was we treat it differently.xmlFile
- The filename this came from. May be null.label
- The label to use in the dialogshowDialog
- Should the dialog be shownshouldMerge
- Should we merge the windows/views in the bundle into the existing windowsbundleProperties
- set of propertiesremoveAll
- Should we remove all data/displaysletUserChangeData
- Should popup the data path dialogdecodeXml(String, boolean, String, String, boolean, boolean,
Hashtable, boolean, boolean, boolean)
public boolean decodeXmlFile(String xmlFile, String label, boolean checkToRemove, boolean letUserChangeData, Hashtable bundleProperties)
Hijacks control of the IDV's bundle loading facilities. Due to the way versions of McIDAS-V prior to alpha 10 handled tabs, the user will end up with a new window for each tab in the bundle. McIDAS-V alpha 10 has the ability to only create one new window and have everything else go into that window's tabs.
decodeXmlFile
in class IdvPersistenceManager
xmlFile
- filelabel
- labelcheckToRemove
- check to removeletUserChangeData
- if true then ask user to change data pathsbundleProperties
- set of properties
IdvPersistenceManager.decodeXmlFile(String, String, boolean, boolean, Hashtable)
,
decodeXml(String, boolean, String, String, boolean, boolean, Hashtable,
boolean, boolean, boolean)
protected void decodeXmlInner(String xml, boolean fromCollab, String xmlFile, String label, boolean showDialog, boolean shouldMerge, Hashtable bundleProperties, boolean didRemoveAll, boolean changeData)
Overridden so that McIDAS-V can redirect to the version of this method that supports limiting the number of new windows.
decodeXmlInner
in class IdvPersistenceManager
xml
- The xml bundlefromCollab
- Was this bundle from the collaboration facility.
If it was we treat it differently.xmlFile
- The filename where the xml came from - may be null.label
- The label to show in the guishowDialog
- Should the loadbundle dialog be shownshouldMerge
- Should we merge the windows/views in the bundle into the existing windowsbundleProperties
- set of propertiesdidRemoveAll
- Was remove all called before we decoded the xmlchangeData
- Should popup data path change dialogdecodeXmlInner(String, boolean, String, String, boolean, boolean, Hashtable, boolean, boolean, boolean)
protected void instantiateFromBundle(Hashtable ht, boolean fromCollab, LoadBundleDialog loadDialog, boolean shouldMerge, Hashtable bundleProperties, boolean didRemoveAll, boolean letUserChangeData) throws Exception
Overridden so that McIDAS-V can redirect to the version of this method that supports limiting the number of new windows.
instantiateFromBundle
in class IdvPersistenceManager
ht
- Contains the unpersisted objectsfromCollab
- Was this bundle from the collaboration facility.
If it was we treat it differently.loadDialog
- The load bundle dialogshouldMerge
- Should we merge the windows/views in the bundle into the existing windowsbundleProperties
- set of propertiesdidRemoveAll
- Was remove all called before we decoded the xmlletUserChangeData
- Should popup data path change dialog
Exception
instantiateFromBundle(Hashtable, boolean, LoadBundleDialog,
boolean, Hashtable, boolean, boolean, boolean)
public void decodeXml(String xml, boolean fromCollab, String xmlFile, String label, boolean showDialog, boolean shouldMerge, Hashtable bundleProperties, boolean removeAll, boolean letUserChangeData, boolean limitWindows)
Hijacks the second part of the IDV bundle loading pipeline so that McIDAS-V can limit the number of new windows.
IdvPersistenceManager.decodeXml(String, boolean,
String, String, boolean, boolean, Hashtable, boolean, boolean)
,
decodeXmlInner(String, boolean, String, String, boolean, boolean,
Hashtable, boolean, boolean, boolean)
protected void decodeXmlInner(String xml, boolean fromCollab, String xmlFile, String label, boolean showDialog, boolean shouldMerge, Hashtable bundleProperties, boolean didRemoveAll, boolean letUserChangeData, boolean limitNewWindows)
Hijacks the third part of the bundle loading pipeline.
IdvPersistenceManager.decodeXmlInner(String, boolean, String, String, boolean, boolean, Hashtable, boolean, boolean)
,
instantiateFromBundle(Hashtable, boolean, LoadBundleDialog, boolean, Hashtable, boolean, boolean, boolean)
private void checkForBadMaps(String bundlePath)
protected static List<ViewManager> extractCompGroupVMs(List<WindowInfo> windows)
Builds a list of an incoming bundle's
ViewManager
s that are part of a component
group.
The reason for only being interested in component groups is because any windows not using component groups will be made into a dynamic skin. The associated ViewManagers do not technically exist until the skin has been "built", so there's nothing to do. These ViewManagers must also be removed from the bundle's list of ViewManagers.
However, any ViewManagers associated with component groups still need to appear in the bundle's ViewManager list, and that's where this method comes into play!
windows
- WindowInfos to be searched.
protected void reverseCollisions(List<ViewManager> vms)
Does the work in fixing the collisions described in the
instantiateFromBundle
javadoc. Basically just queries the
VMManager
for each
ViewManager
. If a match is found, a new ID is
generated and associated with the ViewManager, its
ViewDescriptor
, and any associated
DisplayControl
s.
vms
- ViewManagers in the incoming bundle.instantiateFromBundle(Hashtable, boolean, LoadBundleDialog, boolean, Hashtable, boolean, boolean, boolean)
protected List<WindowInfo> injectComponentGroups(List<WindowInfo> windows) throws Exception
Builds a single window with a single component group. The group contains component holders that correspond to each window or component holder stored in the incoming bundle.
windows
- The bundle's list of
WindowInfo
s.
Exception
- Bubble up any exceptions from
makeImpromptuSkin
.protected List<WindowInfo> betterInject(List<WindowInfo> windows) throws Exception
Builds an altered copy of windows
that preserves the
number of windows while ensuring all displays are inside component
holders.
Exception
- Bubble up dynamic skin exceptions.injectComponentGroups(List)
protected List<IdvComponentHolder> buildHolders(WindowInfo window) throws Exception
Builds a list of component holders with all of window
's
displays.
Exception
- Bubble up any problems creating a dynamic skin.public List<ViewManager> mapDynamicSkins(List<WindowInfo> windows)
Builds a list of any dynamic skins in the bundle and adds them to the UIMananger's "cache" of encountered ViewManagers.
windows
- The bundle's windows.
windows
.private void fixBulkDataSources(List<DataSourceImpl> ds)
The problem is twofold: the paths referenced in the data source's
Sources
may not exist, and the persistence code combines
each individual file into a blob.
The current solution is to note that the data source's
PollingInfo
is used by FilesDataSource.initWithPollingInfo()
to replace the contents of the data source's file paths. Simply
overwrite PollingInfo#filePaths
with the path to the blob.
ds
- List
of DataSourceImpl
s to inspect and/or fix.
Cannot be null
.isBulkDataSource(DataSourceImpl)
private boolean isBulkDataSource(DataSourceImpl d)
DataSourceImpl
is
the result of a McIDAS-V "bulk load".
d
- DataSourceImpl
to check. Cannot be null
.
true
if the DataSourceImpl
matched the criteria.protected void instantiateFromBundle(Hashtable ht, boolean fromCollab, LoadBundleDialog loadDialog, boolean shouldMerge, Hashtable bundleProperties, boolean didRemoveAll, boolean letUserChangeData, boolean limitNewWindows) throws Exception
Overridden so that McIDAS-V can preempt the IDV's bundle loading.
There will be problems if any of the incoming
ViewManager
s share an ID with an existing
ViewManager. While this case may seem unlikely, it can be triggered
when loading a bundle and then reloading. The problem is that the
ViewManagers are the same, and if the previous ViewManagers were not
removed, the IDV doesn't know what to do.
Assigning the incoming ViewManagers a new ID, and associating its
ViewDescriptor
s and
DisplayControl
s with the new ID fixes this
problem.
McIDAS-V also allows the user to limit the number of new windows the bundle may create. If enabled, one new window will be created, and any additional windows will become tabs (component holders) inside the new window.
McIDAS-V also prefers the bundles being loaded to be in a semi-regular regular state. For example, say you have bundle containing only data. The bundle will probably not contain lists of WindowInfos or ViewManagers. Perhaps the bundle contains nested component groups as well! McIDAS-V will alter the unpersisted bundle state (not the actual bundle file) to make it fit into the expected idiom. Mostly this just entails wrapping things in component groups and holders while "flattening" any nested component groups.
ht
- Holds unpersisted objects.fromCollab
- Did the bundle come from the collab stuff?loadDialog
- Show the bundle loading dialog?shouldMerge
- Merge bundle contents into an existing window?bundleProperties
- If non-null, use the set of time indices for
data sources?didRemoveAll
- Remove all data and displays?letUserChangeData
- Allow changes to the data path?limitNewWindows
- Only create one new window?
Exception
IdvPersistenceManager.instantiateFromBundle(Hashtable, boolean, LoadBundleDialog, boolean, Hashtable, boolean, boolean)
private List<WindowInfo> wrapViewManagers(List<ViewManager> vms)
private List<ViewManager> generateViewManagers(List<DisplayControlImpl> controls)
protected void flattenWindows(List<WindowInfo> windows)
Alters windows
so that no windows in the bundle contain
nested component groups.
protected IdvComponentGroup flattenGroup(IdvComponentGroup nested)
nested
that contains no
nested component groups.protected static List<IdvComponentHolder> removeUIHolders(IdvComponentGroup group)
group
containing only component holders
with displays.protected static void populateEssentialLists(String[] ids, Hashtable<String,Object> table)
Ensures that the lists corresponding to the ids in ids
actually exist in table
, even if they are empty.
protected static List<WindowInfo> removeUIHolders(List<WindowInfo> windows)
Returns an altered copy of windows
containing only
component holders that have displays.
The IDV allows users to embed HTML controls or things like the dashboard into component holders. This ability, while powerful, could make for a confusing UI.
public McvComponentHolder makeDynSkin(WindowInfo info) throws Exception
Uses the ViewManager
s in info
to build a dynamic skin.
info
- Window that needs to become a dynamic skin.
McvComponentHolder
containing
the ViewManagers inside info
.
Exception
- Bubble up any XML problems.public static IdvWindow buildDynamicSkin(int width, int height, int rows, int cols, List<org.python.core.PyObject> panelTypes) throws Exception
Exception
public void writeParameterSets()
private Element getParameterTypeNode(String parameterType)
parameterType
- What type of parameter set
public List<String> getAllParameterSetCategories(String parameterType)
parameterType
- What type of parameter set
public List<ParameterSet> getAllParameterSets(String parameterType)
ParameterSet
s that are writable
parameterType
- The type of parameter set
public boolean addParameterSetCategory(String parameterType, String category)
parameterType
- The type of parameter setcategory
- The category (really a ">" delimited string)
public void deleteParameterSet(String parameterType, ParameterSet set)
parameterType
- The type of parameter setset
- Parameter set to delete.public void deleteParameterSetCategory(String parameterType, String category)
parameterType
- The type of parameter setcategory
- The category (really a ">" delimited string)public void renameParameterSet(String parameterType, ParameterSet set)
parameterType
- The type of parameter setset
- The parameter setpublic void moveParameterSet(String parameterType, ParameterSet set, List categories)
parameterType
- The type of parameter setset
- The parameter setcategories
- Where to move topublic void moveParameterSetCategory(String parameterType, List fromCategories, List toCategories)
parameterType
- The type of parameter setfromCategories
- The category to movetoCategories
- Where to move topublic boolean saveParameterSet(String parameterType, Hashtable parameterValues)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |