public interface IVizCanvas
When implemented in tandem with an IVizService, the class that realizes this interface should encapsulate all details related to the internal workings of the IVizService and refrain from exposing them to the client. For example, service ids, credentials, window ids and other information should be stored as private variables and not exposed in the properties map unless absolutely necessary.
A proper implementation of IVizCanvas is one that can be used in standalone tools, workbench-based tools, and embedded in composites in larger, existing tools. Implementations should not be restricted to one usage scenario.
Modifier and Type | Method and Description |
---|---|
org.eclipse.swt.widgets.Composite |
draw(org.eclipse.swt.widgets.Composite parent)
This operation draws the canvas contents onto the given parent Composite.
|
java.net.URI |
getDataSource()
This operation returns the data source that is plotted/drawn by this
IPlot.
|
int |
getNumberOfAxes()
This operation returns the number of axes of the plot.
|
java.util.Map<java.lang.String,java.lang.String> |
getProperties()
This operation returns properties of this IPlot that can be safely
modified and/or tuned by the client.
|
IRenderElementHolder |
getRenderElementHolder(Geometry geometry)
Get the list of render elements used to display the given geometry in
this canvas.
|
java.lang.String |
getSourceHost()
This operation retrieves the hostname for this IPlot's data source.
|
boolean |
isSourceRemote()
This operation signifies whether or not the IPlot's host is local or
remote.
|
void |
redraw()
This operation directs the IPlot to redraw its contents.
|
void |
setProperties(java.util.Map<java.lang.String,java.lang.String> props)
This operation updates the properties of the plot based on client-side
modifications.
|
org.eclipse.swt.widgets.Composite draw(org.eclipse.swt.widgets.Composite parent) throws java.lang.Exception
parent
- java.lang.Exception
java.net.URI getDataSource()
int getNumberOfAxes()
java.util.Map<java.lang.String,java.lang.String> getProperties()
IRenderElementHolder getRenderElementHolder(Geometry geometry)
geometry
- The geometry whose corresponding IRenderElements are sought.java.lang.String getSourceHost()
boolean isSourceRemote()
void redraw()
void setProperties(java.util.Map<java.lang.String,java.lang.String> props) throws java.lang.Exception
props
- The updated propertiesjava.lang.Exception
- This exception indicates that the IPlot could not update its
properties or redraw itself.