jsynoptic.plugins.svg
Class SvgMapper

java.lang.Object
  extended by simtools.ui.GenericMapper
      extended by jsynoptic.plugins.svg.SvgMapper
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable

public class SvgMapper
extends GenericMapper

This class maps data sources and index to Svg. The mapping is user defined, and based for example on the value of the data source For example, green value < 10, red above. Useful for making plots with "alarm" colors The data source shall not be saved into the object. Rather, this class goal is to implement a mapping independent of the data source given. The same is true for the Svg

See Also:
Serialized Form

Nested Class Summary
protected static class SvgMapper.ImageRenderer
          Class SvgMapper. textual representation of the SvgFile for the table cell
protected  class SvgMapper.SvgEditor
           
static class SvgMapper.SvgFile
          Class SvgMapper.
protected  class SvgMapper.SvgMapperTableModel
          Class SvgMapper.
protected  class SvgMapper.SvgMappingTable
          Class SvgMapper. represent the Svg mapper table, extends the simtools.ui.GenericMapper.ExpressionMappingTable
 
Nested classes/interfaces inherited from class simtools.ui.GenericMapper
GenericMapper.Expression, GenericMapper.ExpressionDialog, GenericMapper.ExpressionEditor, GenericMapper.ExpressionMappingTable, GenericMapper.Interval, GenericMapper.MapperTableModel
 
Field Summary
static java.util.ResourceBundle resources
           
static java.util.ArrayList svgMappers
          The svg mappers List are application global
 
Fields inherited from class simtools.ui.GenericMapper
defaultValue, intervals, listeners, map, name
 
Constructor Summary
SvgMapper()
          Constructor. empty constructor call the Abstract2Shape consructor
SvgMapper(java.lang.String name)
          Constructor. call the Abstract2Shape consructor with name in parameters
 
Method Summary
 GenericMapper.MapperTableModel createModel()
           
protected  java.lang.Object createNewValue()
          For subclasses to specialize, create a new object of the specialized type
static SvgMapper createSvgMapperDialog(javax.swing.JDialog owner)
          Method createSvgMapperDialog static metod to instanciate a SvgMapperDialog Parameters:
protected  GenericMapper.ExpressionMappingTable createTable(javax.swing.JDialog parent)
          For subclasses to specialize
static SvgMapper getSvgMapper(java.lang.String id)
          Method getSvgMapperFromName<\b> returns mapper linked to specified name return null if no mapper were found
static SvgMapper updateSvgMapper(SvgMapper m)
          If the mapper already exists in the list, update its values Otherwise add it to the list of existing mappers
 
Methods inherited from class simtools.ui.GenericMapper
addListener, clone, createMapperDialog, createPanel, editDialog, equals, getAllMapperValues, getDefaultValue, getIntervals, getMap, getMapping, getMapping, getMapping, notifyListeners, removeListener, setDefaultValue, setMapperValues, setMapping, setMapping, setMapping, setMapping, setMapping, setMapping, setMapping, setMapping, setMapping, setMapping, setMapping, setMapping, setMapping, setName, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

resources

public static java.util.ResourceBundle resources

svgMappers

public static transient java.util.ArrayList svgMappers
The svg mappers List are application global

Constructor Detail

SvgMapper

public SvgMapper()
Constructor. empty constructor call the Abstract2Shape consructor


SvgMapper

public SvgMapper(java.lang.String name)
Constructor. call the Abstract2Shape consructor with name in parameters

Parameters:
name - the name of the mapper
Method Detail

updateSvgMapper

public static SvgMapper updateSvgMapper(SvgMapper m)
If the mapper already exists in the list, update its values Otherwise add it to the list of existing mappers

Parameters:
m, - the mapper to update
Returns:

getSvgMapper

public static SvgMapper getSvgMapper(java.lang.String id)
Method getSvgMapperFromName<\b> returns mapper linked to specified name return null if no mapper were found

Parameters:
name -
Returns:

createModel

public GenericMapper.MapperTableModel createModel()
Overrides:
createModel in class GenericMapper

createTable

protected GenericMapper.ExpressionMappingTable createTable(javax.swing.JDialog parent)
Description copied from class: GenericMapper
For subclasses to specialize

Overrides:
createTable in class GenericMapper

createNewValue

protected java.lang.Object createNewValue()
Description copied from class: GenericMapper
For subclasses to specialize, create a new object of the specialized type

Overrides:
createNewValue in class GenericMapper

createSvgMapperDialog

public static SvgMapper createSvgMapperDialog(javax.swing.JDialog owner)
Method createSvgMapperDialog static metod to instanciate a SvgMapperDialog Parameters:

Parameters:
owner - the frame owner of this dialog
Returns:
an instance of a SvgMapper