|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectgov.nih.nlm.mms.AbstractGUIConfigurable
gov.nih.nlm.mms.filters.AbstractFilter
gov.nih.nlm.mms.filters.ContentViewFilter
public class ContentViewFilter
Keeps only content in selected content views. Content view definitions are entirely data driven from the "default" property file.
| Nested Class Summary | |
|---|---|
protected class |
ContentViewFilter.ContentViewOption
Represents a single defined content view. |
| Field Summary | |
|---|---|
protected ContentView |
combined_view
|
protected Map<String,ContentViewFilter.ContentViewOption> |
id_to_content_views
|
protected boolean |
ignore_events
|
protected Set<String> |
selected_views
|
protected List |
sources_to_remove
|
| Fields inherited from class gov.nih.nlm.mms.filters.AbstractFilter |
|---|
init_cui, subset_content, warnings |
| Fields inherited from class gov.nih.nlm.mms.AbstractGUIConfigurable |
|---|
data_changed, default_configuration, listeners, user_configuration |
| Constructor Summary | |
|---|---|
ContentViewFilter()
Instantiates an empty ContentViewFilter. |
|
| Method Summary | |
|---|---|
protected void |
addSelectedView(String id)
Adds a selected view to the group of ones that will be applied. |
void |
applySelections(Concept concept)
Apply the filter to the specified Concept. |
Color |
getColor()
Method indicates the Color that should be used to display
the name. |
ContentView |
getCombinedView()
Returns the combined view, the bit-wise OR for all currently selected content views. |
String |
getConfigurationDetails()
Returns the statement that should appear in the subset log file regarding this Filter. |
GUIConfigurable |
getGUIConfigurableForValidationFailure()
Returns the GUIConfigurable whose tab should next be displayed
to allow the user to correct an error or warning. |
JPanel |
getHelpPanel()
Method provides a JPanel that will be called from
the help menu to allow the user to reference a help window
that is particular to this filter. |
String |
getIdForName(String name)
Returns the content view id associated with the given content view name. |
String[] |
getIdsForFlag(long flag)
|
String |
getName()
Returns the name of the Filter. |
String |
getNameForId(String id)
Returns the content view name associated with the given content view id. |
JPanel |
getPanel()
Returns a configuration panel. |
Properties |
getProperties()
Returns a Properties object with the configuration. |
String[] |
getSelectedViews()
|
String |
getTabDescription()
Return the description to appear above the main configuration panel in the {#link MetamorphoSysGUI}. |
boolean |
isEfficientEnabled()
Indicates if Filter can use the efficient mode during
the "Initialize Cuis" phase of the subsetting process. |
protected void |
makeCombinedView()
Calculates the bit-wise OR for all currently selected views. |
protected void |
removeSelectedView(String id)
Removes a selected view from the group of ones that will be applied. |
void |
resetToDefaults()
There are no defaults because this filter has nothing to configure. |
void |
setConfiguration(ApplicationConfiguration c)
Gives the filter access to the default configuration object. |
void |
setPanelSelections()
Inactive method because there are no items to configure on this filter. |
void |
setProperties(Properties props)
Not an active method, because this filter doesn't have any filter specific properties. |
void |
sourcesToRemoveChanged(SourcesToRemoveEvent stre)
Listens for changes in the sources to remove list. |
boolean |
validate()
This method is the default method for filters that don't check for validity and it returns true indicating a valid filter. |
| Methods inherited from class gov.nih.nlm.mms.filters.AbstractFilter |
|---|
applyFilter, beginInitializeCuiList, beginSubsetContent, endInitializeCuiList, endSubsetContent, fireDataChanged, fireNotUndoableDataChanged, getValidateMessage, getWarnings, setCuiList |
| Methods inherited from class gov.nih.nlm.mms.AbstractGUIConfigurable |
|---|
addDataChangeListener, addValidationError, addValidationWarning, clearValidationErrors, clearValidationWarnings, compareTo, getValidationErrors, getValidationWarnings, hasAdvancedOptions, hasDataChanged, removeDataChangeListener, resetDataChanged, setConfiguration, setDataChanged, showOptions |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface gov.nih.nlm.mms.filters.Filter |
|---|
applyFilter, getWarnings |
| Methods inherited from interface gov.nih.nlm.mms.GUIConfigurable |
|---|
addDataChangeListener, getValidationErrors, getValidationWarnings, hasAdvancedOptions, hasDataChanged, removeDataChangeListener, resetDataChanged, setDataChanged, showOptions |
| Methods inherited from interface gov.nih.nlm.mms.Configurable |
|---|
setConfiguration |
| Methods inherited from interface java.lang.Comparable |
|---|
compareTo |
| Methods inherited from interface gov.nih.nlm.mms.SubsetListener |
|---|
beginInitializeCuiList, beginSubsetContent, endInitializeCuiList, endSubsetContent, setCuiList |
| Field Detail |
|---|
protected List sources_to_remove
protected boolean ignore_events
protected final Map<String,ContentViewFilter.ContentViewOption> id_to_content_views
protected final Set<String> selected_views
protected final ContentView combined_view
| Constructor Detail |
|---|
public ContentViewFilter()
ContentViewFilter.
| Method Detail |
|---|
public JPanel getPanel()
getPanel in interface GUIConfigurablegetPanel in class AbstractGUIConfigurableJPanelpublic JPanel getHelpPanel()
JPanel that will be called from
the help menu to allow the user to reference a help window
that is particular to this filter.
getHelpPanel in interface GUIConfigurablegetHelpPanel in class AbstractGUIConfigurableJPanel to be added to the Help menupublic String getTabDescription()
getTabDescription in interface GUIConfigurablegetTabDescription in class AbstractGUIConfigurableStringpublic void resetToDefaults()
resetToDefaults in interface ConfigurableresetToDefaults in class AbstractGUIConfigurablepublic void setConfiguration(ApplicationConfiguration c)
setConfiguration in interface ConfigurablesetConfiguration in class AbstractGUIConfigurablec - ApplicationConfigurationpublic Properties getProperties()
Properties object with the configuration.
getProperties in interface ConfigurablegetProperties in class AbstractGUIConfigurableProperties object with the configuration.public void setProperties(Properties props)
setProperties in interface ConfigurablesetProperties in class AbstractGUIConfigurableprops - Propertiespublic void applySelections(Concept concept)
Concept. Atoms whose
Content View Fields don't provide a bit-wise AND with the selected
views, that is non-zero, are removed.
applySelections in interface ConceptContentSelectorconcept - Conceptpublic void setPanelSelections()
setPanelSelections in interface GUIConfigurablesetPanelSelections in class AbstractGUIConfigurablepublic String getName()
Filter.
getName in interface GUIConfigurablegetName in class AbstractGUIConfigurablepublic String getConfigurationDetails()
Filter.
getConfigurationDetails in interface ConfigurablegetConfigurationDetails in class AbstractGUIConfigurablepublic Color getColor()
Color that should be used to display
the name.
getColor in interface GUIConfigurablegetColor in class AbstractGUIConfigurableColorpublic boolean isEfficientEnabled()
Filter can use the efficient mode during
the "Initialize Cuis" phase of the subsetting process.
The efficient mode reads only MRCONSO and MRSTY during the
"Initialize Cuis" phase.
isEfficientEnabled in interface Filtertrue if efficient mode is acceptable
false if efficient mode is not acceptablepublic boolean validate()
validate in interface GUIConfigurablevalidate in class AbstractGUIConfigurabletrue filter is validpublic GUIConfigurable getGUIConfigurableForValidationFailure()
GUIConfigurable whose tab should next be displayed
to allow the user to correct an error or warning.
getGUIConfigurableForValidationFailure in interface GUIConfigurablegetGUIConfigurableForValidationFailure in class AbstractGUIConfigurablepublic void sourcesToRemoveChanged(SourcesToRemoveEvent stre)
sourcesToRemoveChanged in interface SourcesToRemoveListenerstre - the eventprotected void addSelectedView(String id)
id - for the related ContentViewOptionprotected void removeSelectedView(String id)
id - for the related ContentViewOptionprotected void makeCombinedView()
public ContentView getCombinedView()
ContentView combined_viewpublic String[] getSelectedViews()
public String getNameForId(String id)
id - String
public String getIdForName(String name)
id - String
public String[] getIdsForFlag(long flag)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||