com.esri.arcgis.cartoUI
Class BaseCustomRendererPropertyPage

java.lang.Object
  extended by com.esri.arcgis.framework.BasePropertyPage
      extended by com.esri.arcgis.cartoUI.BaseCustomRendererPropertyPage
All Implemented Interfaces:
IRendererPropertyPage, IComEmbeddedPropertyPage, IComPropertyPage, Serializable

public abstract class BaseCustomRendererPropertyPage
extends BasePropertyPage
implements IComEmbeddedPropertyPage, IRendererPropertyPage

BaseCustomRendererPropertyPage is the base class which Java implementations of a Custom renderer property page should extend from.

Implementations of a Custom renderer property page should define a Java user interface that derives from javax.swing.JFrame. It is recommended to keep the implementation of the user interface seperate from the implementation of the class that derives from BaseCustomRendererPropertyPage. For example,

MyRendererPropertyPage extends BaseCustomRendererPropertyPage {
Form form;
...
JFrame initGUI(IFeatureRenderer featureRenderer) {
// Using the default properties of the featureRenderer to initialize the UI if necessary
form = new Form();
return form;
}
}

See Also:
Serialized Form

Field Summary
 
Fields inherited from interface com.esri.arcgis.framework.IComEmbeddedPropertyPage
IID, IID063304c3_7b90_48e9_b2d3_e795a8ba926b, xxDummy
 
Fields inherited from interface com.esri.arcgis.cartoUI.IRendererPropertyPage
IID, IID44bd4d21_5f47_11d0_92da_00805f7c28b0, xxDummy
 
Fields inherited from interface com.esri.arcgis.framework.IComPropertyPage
IID, IID76951cc6_dbb1_11d2_b868_00600802e603, xxDummy
 
Constructor Summary
BaseCustomRendererPropertyPage()
           
 
Method Summary
 boolean applies(ISet objects)
          Indicates if the page applies to the specified objects.
 void apply()
          Applies any changes to the object(s).
abstract  void apply(IFeatureRenderer yourCustomRenderer)
          Applies property changes onto the Custom renderer.
 boolean canEdit(IFeatureRenderer obj)
          Indicates if the property page can modify the properties of the specified renderer.
 Object createCompatibleObject(Object kind)
          Create a new object using the specified object as a template.
 IUID getClassID()
          Property page class id (unique identifier object).
abstract  Class getCustomRendererDef()
           
abstract  String getDescription()
          Renderer description.
abstract  String getName()
          Name of the renderer.
abstract  int getPreviewImage()
          Preview bitmap for the renderer that appears on the page.
 IUID getRendererClassID()
          Renderer class id (unique identifier object).
 String getTitle()
          The title of the property page.
abstract  String getType()
          Renderer type.
 JFrame initGUI()
           
abstract  JFrame initGUI(IFeatureRenderer yourCustomRender)
          Initializes the User Interface with default properties of a Custom renderer.
 void queryObject(Object theObject)
          Apply the property page settings to the specified object.
 void setObjects(ISet objects)
          Supplies the page with the object(s) to be edited.
 
Methods inherited from class com.esri.arcgis.framework.BasePropertyPage
activate, cancel, deactivate, getHeight, getHelpContextID, getHelpFile, getPriority, getWidth, hide, IComPropertyPage_isPageDirty, pageChanged, repaintJFrame, setPageSiteByRef, setPriority, setTitle, show
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BaseCustomRendererPropertyPage

public BaseCustomRendererPropertyPage()
Method Detail

apply

public abstract void apply(IFeatureRenderer yourCustomRenderer)
Applies property changes onto the Custom renderer. Implementations of this method should obtain the latest values from the property page UI and apply them on the Custom renderer provided as an argument to this method.

Since this method is not called on Java's EDT thread it is unsafe to modify properties of user interface elements residing on the property page.

It is safe to use the ArcObjects API within this method.

Parameters:
yourCustomRenderer - the Custom renderer that is associated with this property page

getCustomRendererDef

public abstract Class getCustomRendererDef()

initGUI

public abstract JFrame initGUI(IFeatureRenderer yourCustomRender)
Initializes the User Interface with default properties of a Custom renderer. This method creates initializes a user interface frame that derives from javax.swing.JFrame and returns it to the ArcGIS runtime. This method is passed in a reference to an instance of a Custom renderer from which default properties of the custom renderer can be obtained to initialize the user interface *

Implementations of this method should not call methods to realize the JFrame; example, setVisible(true). Visibility of the JFrame and it's life-cycle management is performed internally by the ArcGIS runtime.

It is safe to use the ArcObjects API within this method.

Parameters:
yourCustomRenderer - the Custom reference that is associated with this property page
Returns:
the user interface

initGUI

public JFrame initGUI()
Specified by:
initGUI in class BasePropertyPage

applies

public final boolean applies(ISet objects)
                      throws IOException,
                             AutomationException
Description copied from class: BasePropertyPage
Indicates if the page applies to the specified objects.

Specified by:
applies in interface IComPropertyPage
Specified by:
applies in class BasePropertyPage
Parameters:
objects - A reference to a com.esri.arcgis.system.ISet (in)
Returns:
The pApplies
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

apply

public final void apply()
                 throws AutomationException,
                        IOException
Description copied from class: BasePropertyPage
Applies any changes to the object(s).

Specified by:
apply in interface IComPropertyPage
Specified by:
apply in class BasePropertyPage
Throws:
AutomationException - If the ArcObject component throws an exception.
IOException - If there are interop problems.

getTitle

public final String getTitle()
Description copied from class: BasePropertyPage
The title of the property page.

Specified by:
getTitle in interface IComPropertyPage
Specified by:
getTitle in class BasePropertyPage
Returns:
The title

setObjects

public final void setObjects(ISet objects)
                      throws IOException,
                             AutomationException
Description copied from class: BasePropertyPage
Supplies the page with the object(s) to be edited.

Specified by:
setObjects in interface IComPropertyPage
Specified by:
setObjects in class BasePropertyPage
Parameters:
objects - A reference to a com.esri.arcgis.system.ISet (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

createCompatibleObject

public final Object createCompatibleObject(Object kind)
                                    throws IOException,
                                           AutomationException
Create a new object using the specified object as a template. The kind argument may be NULL if the page interacts with only a single object.

Specified by:
createCompatibleObject in interface IComEmbeddedPropertyPage
Parameters:
kind - A Variant (in)
Returns:
A Variant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

queryObject

public final void queryObject(Object theObject)
                       throws IOException,
                              AutomationException
Apply the property page settings to the specified object.

Specified by:
queryObject in interface IComEmbeddedPropertyPage
Parameters:
theObject - A Variant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

canEdit

public final boolean canEdit(IFeatureRenderer obj)
                      throws IOException,
                             AutomationException
Indicates if the property page can modify the properties of the specified renderer.

Specified by:
canEdit in interface IRendererPropertyPage
Parameters:
obj - A reference to a (in)
Returns:
The result
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getClassID

public final IUID getClassID()
                      throws IOException,
                             AutomationException
Property page class id (unique identifier object).

Specified by:
getClassID in interface IRendererPropertyPage
Returns:
A reference to a
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getRendererClassID

public final IUID getRendererClassID()
                              throws IOException,
                                     AutomationException
Renderer class id (unique identifier object).

Specified by:
getRendererClassID in interface IRendererPropertyPage
Returns:
A reference to a
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getDescription

public abstract String getDescription()
                               throws IOException,
                                      AutomationException
Renderer description.

Specified by:
getDescription in interface IRendererPropertyPage
Returns:
The desc
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getName

public abstract String getName()
                        throws IOException,
                               AutomationException
Name of the renderer.

Specified by:
getName in interface IRendererPropertyPage
Returns:
The name
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getPreviewImage

public abstract int getPreviewImage()
                             throws IOException,
                                    AutomationException
Preview bitmap for the renderer that appears on the page.

Specified by:
getPreviewImage in interface IRendererPropertyPage
Returns:
The hBitmap (A COM typedef)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getType

public abstract String getType()
                        throws IOException,
                               AutomationException
Renderer type. Used to group renderers into categories.

Specified by:
getType in interface IRendererPropertyPage
Returns:
The type
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.