com.sas.actionprovider.commands
Class MapPropertyCommand

com.sas.actionprovider.commands.MapPropertyCommand
All Implemented Interfaces:
CancelInterface, ContentsChangedInterface, DataSelectorCommandInterface, DynamicAttributeCommandInterface, PendingCommandInterface, BaseEntityInterface, BaseEntityValueInterface, EntityKeyInterface, com.sas.lang.StringDataInterface, com.sas.PublicClonable, com.sas.util.Command, com.sas.util.SimpleCommand, java.lang.Cloneable, java.rmi.Remote

public class MapPropertyCommand

This class implements the map's show property sheet command.


Field Summary
 
Fields inherited from class com.sas.commands.dataselectors.BaseSelectorCommand
actionClass, CANCEL_MODE, COMMIT_MODE, complete, contentsChanged, eventInfo, eventSource, modal, mode, model, PROCESS_MODE, selector, selectorModel, SHOW_MODE
 
Fields inherited from interface com.sas.commands.DynamicAttributeCommandInterface
COMMAND_NAME_PREFIX
 
Constructor Summary
MapPropertyCommand(java.lang.String name)
          Constructor that accepts a command name
MapPropertyCommand(java.lang.String name, java.lang.String actionClass)
          Constructor that accepts a command name and an action class type
 
Method Summary
 void cancel(java.lang.Object o)
          Cancel is called when the user clicks on the cancel button on the selector or another selector becomes active.
protected  void commit(java.lang.Object o)
          Commits all changes made to the selector model to the viewer's business model.
 int getColorRegions()
           
 java.lang.String[] getCrossing()
           
 java.lang.Object getGeo()
           
 int getHeight()
           
 java.lang.String[] getLayers()
           
protected  java.util.List getLayersList()
           
protected  java.util.HashMap getLayersMap(java.util.List layersList, java.util.Map layers)
           
 java.lang.Object getMapViewer()
           
 java.lang.String getMeasure()
           
 int getNumberOfColors()
           
 java.lang.String[] getSelectedCrossing()
           
 java.lang.String getSelectedRegionColor()
           
 java.lang.String getSize()
           
 int getWidth()
           
 boolean isShowCrossing()
           
 boolean isSupported(ActionSupportFilter actionFilter)
          Returns a boolean indicating whether the command is supported for the area specified on the ActionSupportFilter argument.
protected  void process(java.lang.Object o)
          e Constructor that accepts a command name and an action class type
 void setColorRegions(int colorRegions)
           
 void setCrossing(java.lang.String[] crossing)
           
 void setGeo(java.lang.Object geo)
           
 void setHeight(int height)
           
 void setLayers(java.lang.String[] layers)
           
 void setMapViewer(java.lang.Object mapViewer)
           
 void setMeasure(java.lang.String measure)
           
 void setNumberOfColors(int numberOfColors)
           
 void setSelectedCrossing(java.lang.String[] selectedCrossing)
           
 void setSelectedRegionColor(java.lang.String selectedRegionColor)
           
 void setShowCrossing(boolean showCrossing)
           
 void setSize(java.lang.String size)
           
 void setWidth(int width)
           
protected  void show(java.lang.Object o)
          Creates the selector model and sets it on the selector.
 
Methods inherited from class com.sas.commands.dataselectors.BaseSelectorCommand
cancel, closeSelector, execute, getEventInfo, getEventSource, getMode, getModel, getSelector, getSelectorModel, isComplete, isContentsChanged, isModal, setComplete, setModal, setMode, setModel, setSelector, setSelectorModel
 
Methods inherited from class com.sas.commands.BaseCommand
getLocale, getName, getNextCommandName, getText, isExecutable, isUndoable, setLocale, setName, setText, undo
 
Methods inherited from class com.sas.entities.BaseEntity
clone, containsAttributeNamed, equals, equals, getAttribute, getAttribute, getAttributeCount, getAttributes, getEntityKey, getPropertyDescriptors, getStringAttribute, listAttributeNames, removeAllAttributes, removeAttribute, reset, sameEntity, setAttribute, setAttributes, setEntityKey, toString
 
Methods inherited from interface com.sas.entities.BaseEntityValueInterface
getAttribute, setAttribute
 
Methods inherited from interface com.sas.util.Command
clone
 

Constructor Detail

MapPropertyCommand

public MapPropertyCommand(java.lang.String name)
Constructor that accepts a command name

Parameters:
name - command name

MapPropertyCommand

public MapPropertyCommand(java.lang.String name,
                          java.lang.String actionClass)
Constructor that accepts a command name and an action class type

Method Detail

show

protected void show(java.lang.Object o)
Creates the selector model and sets it on the selector. This is typically run when the selector dialog is initially displayed.

Overrides:
show in class BaseSelectorCommand

process

protected void process(java.lang.Object o)
e Constructor that accepts a command name and an action class type

Overrides:
process in class BaseSelectorCommand
Parameters:
command - name
swing - true if a swing viewer is used, false otherwise

cancel

public void cancel(java.lang.Object o)
Cancel is called when the user clicks on the cancel button on the selector or another selector becomes active. Sets the selector visible property to false so the selector window gets closed.

Overrides:
cancel in class BaseSelectorCommand

commit

protected void commit(java.lang.Object o)
               throws java.io.IOException
Commits all changes made to the selector model to the viewer's business model. The items selected for each role are set as the result items on the BusinessQuery. If problems are enountered while updating the BusinessQuery, the error message describing the problem will be places on the EventInfo map for display by viewers listening for events, and all changes committed to the business model will be rolled back to the original state.

Overrides:
commit in class BaseSelectorCommand
Throws:
java.io.IOException
See Also:
BusinessQuery, BusinessModel

getLayersMap

protected java.util.HashMap getLayersMap(java.util.List layersList,
                                         java.util.Map layers)

isSupported

public boolean isSupported(ActionSupportFilter actionFilter)
Returns a boolean indicating whether the command is supported for the area specified on the ActionSupportFilter argument.

Parameters:
actionFilter - - the object that describes the current area.
Returns:
a boolean indicating whether the command is supported.

getMapViewer

public java.lang.Object getMapViewer()
Returns:
Returns the mapViewer.

setMapViewer

public void setMapViewer(java.lang.Object mapViewer)
Parameters:
mapViewer - The mapViewer to set.

getGeo

public java.lang.Object getGeo()
Returns:
Returns the geo.

setGeo

public void setGeo(java.lang.Object geo)
Parameters:
geo - The geo to set.

getCrossing

public java.lang.String[] getCrossing()
Returns:
Returns the crossing.

setCrossing

public void setCrossing(java.lang.String[] crossing)
Parameters:
crossing - The crossing to set.

getNumberOfColors

public int getNumberOfColors()
Returns:
Returns the numberOfColors.

setNumberOfColors

public void setNumberOfColors(int numberOfColors)
Parameters:
numberOfColors - The numberOfColors to set.

getColorRegions

public int getColorRegions()
Returns:
Returns the colorRegions.

setColorRegions

public void setColorRegions(int colorRegions)
Parameters:
colorRegions - The colorRegions to set.

getHeight

public int getHeight()
Returns:
Returns the height.

setHeight

public void setHeight(int height)
Parameters:
height - The height to set.

getSize

public java.lang.String getSize()
Returns:
Returns the size.

setSize

public void setSize(java.lang.String size)
Parameters:
size - The size to set.

getWidth

public int getWidth()
Returns:
Returns the width.

setWidth

public void setWidth(int width)
Parameters:
width - The width to set.

getSelectedRegionColor

public java.lang.String getSelectedRegionColor()
Returns:
Returns the selectedRegionColor.

setSelectedRegionColor

public void setSelectedRegionColor(java.lang.String selectedRegionColor)
Parameters:
selectedRegionColor - The selectedRegionColor to set.

getLayers

public java.lang.String[] getLayers()
Returns:
Returns the layers.

getLayersList

protected java.util.List getLayersList()

setLayers

public void setLayers(java.lang.String[] layers)
Parameters:
layers - The layers to set.

getSelectedCrossing

public java.lang.String[] getSelectedCrossing()
Returns:
Returns the selectedCrossing.

setSelectedCrossing

public void setSelectedCrossing(java.lang.String[] selectedCrossing)
Parameters:
selectedCrossing - The selectedCrossing to set.

getMeasure

public java.lang.String getMeasure()
Returns:
Returns the measure.

setMeasure

public void setMeasure(java.lang.String measure)
Parameters:
measure - The measure to set.

isShowCrossing

public boolean isShowCrossing()

setShowCrossing

public void setShowCrossing(boolean showCrossing)



Copyright © 2009 SAS Institute Inc. All Rights Reserved.