public class IlvDashboardContext extends Object
IlvDashboardContext
provides the global context used by a
dashboard diagram and its related objects. You need a
IlvDashboardContext
object to create an
IlvDashboardDiagram
instance.
An IlvDashboardContext
instance contains the following
context data:
ResourceBundle
for stocking locale
specific data.IlvPaletteManager
used to load and unload palettes in
your application.Logger
object.IlvDashboardContext
instance to create a
IlvDashboardDiagram
instance.
IlvDashboardContext dashContext = new IlvDashboardContext(); IlvDashboardDiagram dashDiag = new IlvDashboardDiagram(dashContext);
IlvDashboardDiagram
,
IlvDashboardEditor
Constructor and Description |
---|
IlvDashboardContext()
Constructs an
IlvDashboardContext instance using the
default resource bundle. |
IlvDashboardContext(ResourceBundle bundle)
Constructs an
IlvDashboardContext instance adding the
locale specific information resources in bundle . |
Modifier and Type | Method and Description |
---|---|
Component |
getDialogParent()
Returns the Java
Component that will be used as the parent
for dialog windows in your dashboard application. |
Logger |
getLogger()
Returns the Java
Logger used by the
ilog.views.dashboard package. |
IlvPaletteManager |
getPaletteManager()
Returns the palette manager used by this dashboard context.
|
ResourceBundle |
getResourceBundle()
Returns the locale specific information contained in this object.
|
URL |
getStyleSheetURL()
Returns the URL holding the location of the CSS file used
to render
IlvDashboardDiagram s utilizing this
IlvDashboardContext . |
boolean |
isDefaultMappingEnabled()
Checks if symbol parameters are automatically mapped to SDM object
properties when it is added to a dashboard diagram.
|
IlvPalette |
loadPalette(String packageName)
Loads a symbol palette in
packageName using the
local IlvPaletteManager . |
IlvPalette[] |
loadPalettes(URL paletteURL)
This method loads the content of jar file containing one or more
palette definitions.
|
void |
logMessage(Level level,
String message)
Logs
message at level to the Logger
used by your dashboard application. |
void |
setDefaultMappingEnabled(boolean enabled)
Sets whether symbol parameters are automatically mapped to SDM object
properties when it is added to a dashboard diagram.
|
void |
setDialogParent(Component component)
Sets the Java parent
Component used for any dialog window created by
a dashboard component. |
void |
setStyleSheetURL(URL url)
Sets the URL holding the location of the CSS file used
to render
IlvDashboardDiagram s utilizing this
IlvDashboardContext . |
public static final String VERSION
public IlvDashboardContext()
IlvDashboardContext
instance using the
default resource bundle.IlvDashboardContext(ResourceBundle)
,
Examplepublic IlvDashboardContext(ResourceBundle bundle)
IlvDashboardContext
instance adding the
locale specific information resources in bundle
.
Note: if bundle
is null
, the
default resource bundle is used to instantiate the
IlvDashboardContext
instance.
bundle
- A resource bundle with locale specific information to be used
by a dashboard diagram via this IlvDashboardContext
instance.IlvDashboardContext()
public ResourceBundle getResourceBundle()
public Component getDialogParent()
Component
that will be used as the parent
for dialog windows in your dashboard application.
When a dialog window is created by a dashboard component for any purpose,
this Component
is used as the parent window.
Note: this attribute is not instantiated when the
IlvDashboardContext
class is created. Call
setDialogParent
to set the parent component.
Component
to be used as parent for dialog windows in
your dashboard application.setDialogParent(Component)
public void setDialogParent(Component component)
Component
used for any dialog window created by
a dashboard component.
Note: this attribute is not instantiated when the
IlvDashboardContext
class is created. You must call
this method to set the parent component.
component
- The parent Java Component
for dialog windows
attached to a dashboard application.getDialogParent()
public URL getStyleSheetURL()
IlvDashboardDiagram
s utilizing this
IlvDashboardContext
.
Change this style sheet by calling setStyleSheetURL
.
setStyleSheetURL(URL)
public void setStyleSheetURL(URL url)
IlvDashboardDiagram
s utilizing this
IlvDashboardContext
.url
- The URL to the current style sheet.getStyleSheetURL()
public IlvPaletteManager getPaletteManager()
This IlvPaletteManager
instance is used to load, save and
manage palettes.
public IlvPalette loadPalette(String packageName)
packageName
using the
local IlvPaletteManager
.packageName
- The name of the package containing the symbol palette
the user wants to load.IlvPaletteManager
,
IlvPaletteManager.load(java.lang.String)
public IlvPalette[] loadPalettes(URL paletteURL)
paletteURL
- A fully qualified URL containing the path to the palette
the user wants to load.loadPalette(String)
,
IlvPaletteManager
,
IlvPaletteManager.load(java.net.URL)
public boolean isDefaultMappingEnabled()
true
if default mapping is enabled.setDefaultMappingEnabled(boolean)
,
Rendering symbolspublic void setDefaultMappingEnabled(boolean enabled)
enabled
- Set to true
to enable default SDM mapping.isDefaultMappingEnabled()
,
Rendering symbolspublic Logger getLogger()
Logger
used by the
ilog.views.dashboard
package.Logger
instance used to trace a
dashboard application.logMessage(Level, String)
public void logMessage(Level level, String message)
message
at level
to the Logger
used by your dashboard application.level
- The level at which to log message
.message
- The message to log.getLogger()
© Copyright Rogue Wave Software, Inc. 1997, 2018. All Rights Reserved.