|
|||||||||
| 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.browser.AbstractBrowserRestrictor
gov.nih.nlm.mms.browser.SemanticTypesBrowserRestrictor
public class SemanticTypesBrowserRestrictor
Holds criteria for how to restrict or highlight content
in finder searches and/or concept view displays. Offers
user restriction/highlight mechanisms based on HierarchicalSemanticTypes.
| Field Summary |
|---|
| Fields inherited from class gov.nih.nlm.mms.browser.AbstractBrowserRestrictor |
|---|
cds |
| Fields inherited from class gov.nih.nlm.mms.AbstractGUIConfigurable |
|---|
data_changed, listeners, user_configuration |
| Constructor Summary | |
|---|---|
SemanticTypesBrowserRestrictor()
Every BrowserRestrictor is required to have a no-arg constructor. |
|
| Method Summary | |
|---|---|
void |
addStyColorSetting(HierarchicalSemanticType sty,
Color color)
Sets the given Color to be associated with the given
HierarchicalSemanticType. |
void |
addStyStyleSetting(HierarchicalSemanticType sty,
String style)
Sets the given style to be associated with the given HierarchicalSemanticType. |
int |
compare(Object o1,
Object o2)
Compares this object with the specified object for order. |
List<Color> |
getColor(Object o)
Returns a List of Colors for which the given parameter
matches in the BrowserRestrictor's key. |
Color |
getColorForSty(HierarchicalSemanticType sty)
Returns the Color associated with the given
HierarchicalSemanticType. |
String |
getConfigurationDetails()
Method returns a String detailing
the user selections on the GUIConfigurable. |
String |
getName()
Returns the name. |
JPanel |
getPanel()
Returns a JPanel containing configuration options. |
Properties |
getProperties()
Returns the Properties representing the configuration choices. |
List<String> |
getStyle(Object o)
Returns a List of font styles for which the given parameter
matches in the BrowserRestrictor's key. |
String |
getStyleForSty(HierarchicalSemanticType sty)
Returns the style associated with the given HierarchicalSemanticType. |
String |
getStyleLegend()
Returns a HTML string containing a key for how elements from the browser restrictor should be displayed, indicating the color and font style. |
String |
getTabDescription()
Returns the description to be used in conjunction with the panel when presented to the user. |
boolean |
isColorInHashMap(Color color)
Indicates if the given Color is present in the
set of HierarchicalSemanticType - Color
associations. |
boolean |
isStyInColorHashMap(HierarchicalSemanticType sty)
Indicates if the given HierarchicalSemanticType is
present in the set of HierarchicalSemanticType - Color
associations. |
boolean |
isStyInStyleHashMap(HierarchicalSemanticType sty)
Indicates if the given HierarchicalSemanticType is
present in the set of HierarchicalSemanticType - style
associations. |
boolean |
keep(Object o)
Indicates if the given Object should be kept according to
the restriction rules of this BrowserRestrictor
return true if Object should be kept
false otherwise |
void |
removeStyColorSetting(HierarchicalSemanticType sty)
Clears the association between the given HierarchicalSemanticType
and its Color setting. |
void |
removeStyStyleSetting(HierarchicalSemanticType sty)
Clears the association between the given HierarchicalSemanticType
and its style setting. |
void |
setProperties(Properties props)
Sets the Properties representing the configuration choices. |
void |
showOptions()
Presents an advanced options GUI to the user. |
| Methods inherited from class gov.nih.nlm.mms.browser.AbstractBrowserRestrictor |
|---|
equals, getConceptDataSelector, hasAdvancedOptions, isBold, isConceptViewHideModeEnabled, isConceptViewHighlightModeEnabled, isFinderRestrictionEnabled, isItalics, isUnderline, setBold, setConceptViewHideModeEnabled, setConceptViewHighlightModeEnabled, setFinderRestrictionEnabled, setItalics, setUnderline, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface gov.nih.nlm.mms.browser.BrowserRestrictor |
|---|
getConceptDataSelector, isBold, isConceptViewHideModeEnabled, isConceptViewHighlightModeEnabled, isFinderRestrictionEnabled, isItalics, isUnderline, setBold, setConceptViewHideModeEnabled, setConceptViewHighlightModeEnabled, setFinderRestrictionEnabled, setItalics, setUnderline |
| Methods inherited from interface gov.nih.nlm.mms.GUIConfigurable |
|---|
addDataChangeListener, getColor, getGUIConfigurableForValidationFailure, getHelpPanel, getValidationErrors, getValidationWarnings, hasAdvancedOptions, hasDataChanged, removeDataChangeListener, resetDataChanged, setDataChanged, setPanelSelections, validate |
| Methods inherited from interface gov.nih.nlm.mms.Configurable |
|---|
resetToDefaults, setConfiguration, setConfiguration |
| Methods inherited from interface java.lang.Comparable |
|---|
compareTo |
| Methods inherited from interface java.util.Comparator |
|---|
equals |
| Constructor Detail |
|---|
public SemanticTypesBrowserRestrictor()
BrowserRestrictor is required to have a no-arg constructor.
| Method Detail |
|---|
public boolean keep(Object o)
Object should be kept according to
the restriction rules of this BrowserRestrictor
return true if Object should be kept
false otherwise
keep in interface Restrictorkeep in class AbstractBrowserRestrictortrue object will be kept
false otherwise
public int compare(Object o1,
Object o2)
Required method for implementing
Comparable interface.
Indicates the means for comparison between two Filters.
compare in interface Comparatoro1 - the first Object to be compared.02 - the second Object to be compared.
ClassCastException - if the specified object's type is not
GUIConfigurable.public String getName()
getName in interface GUIConfigurablegetName in class AbstractGUIConfigurablepublic JPanel getPanel()
JPanel containing configuration options.
getPanel in interface GUIConfigurablegetPanel in class AbstractGUIConfigurableJPanel containing configuration optionspublic String getTabDescription()
getTabDescription in interface GUIConfigurablegetTabDescription in class AbstractGUIConfigurablepublic Properties getProperties()
Properties representing the configuration choices.
getProperties in interface ConfigurablegetProperties in class AbstractBrowserRestrictorProperties representing the configuration choicespublic void setProperties(Properties props)
Properties representing the configuration choices.
setProperties in interface ConfigurablesetProperties in class AbstractBrowserRestrictorp - the Properties representing the configuration choicespublic String getConfigurationDetails()
String detailing
the user selections on the GUIConfigurable. This String will
be displayed in the mmsys.log at the completion of subsetting
so it should be formatted to be easily read.
getConfigurationDetails in interface ConfigurablegetConfigurationDetails in class AbstractGUIConfigurableString of data for logpublic void showOptions()
showOptions in interface GUIConfigurableshowOptions in class AbstractGUIConfigurable
public void addStyColorSetting(HierarchicalSemanticType sty,
Color color)
Color to be associated with the given
HierarchicalSemanticType.
sty - HierarchicalSemanticTypecolor - Color
public void addStyStyleSetting(HierarchicalSemanticType sty,
String style)
HierarchicalSemanticType.
sty - HierarchicalSemanticTypestyle - Colorpublic void removeStyColorSetting(HierarchicalSemanticType sty)
HierarchicalSemanticType
and its Color setting.
sty - HierarchicalSemanticTypepublic void removeStyStyleSetting(HierarchicalSemanticType sty)
HierarchicalSemanticType
and its style setting.
sty - HierarchicalSemanticTypepublic Color getColorForSty(HierarchicalSemanticType sty)
Color associated with the given
HierarchicalSemanticType.
sty - HierarchicalSemanticType
Colorpublic boolean isColorInHashMap(Color color)
Color is present in the
set of HierarchicalSemanticType - Color
associations.
color - Color
true if given Color is present
false otherwisepublic boolean isStyInColorHashMap(HierarchicalSemanticType sty)
HierarchicalSemanticType is
present in the set of HierarchicalSemanticType - Color
associations.
sty - HierarchicalSemanticType
true if given HierarchicalSemanticType is present
false otherwisepublic boolean isStyInStyleHashMap(HierarchicalSemanticType sty)
HierarchicalSemanticType is
present in the set of HierarchicalSemanticType - style
associations.
sty - HierarchicalSemanticType
true if given HierarchicalSemanticType is present
false otherwisepublic String getStyleForSty(HierarchicalSemanticType sty)
HierarchicalSemanticType.
sty - HierarchicalSemanticType
public String getStyleLegend()
getStyleLegend in interface BrowserRestrictorpublic List<Color> getColor(Object o)
List of Colors for which the given parameter
matches in the BrowserRestrictor's key.
getColor in interface BrowserRestrictorgetColor in class AbstractBrowserRestrictoro - Object
public List<String> getStyle(Object o)
List of font styles for which the given parameter
matches in the BrowserRestrictor's key.
getStyle in interface BrowserRestrictorgetStyle in class AbstractBrowserRestrictoro - Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||