Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 329118

Summary: Support create action
Product: z_Archived Reporter: Konstantin Komissarchik <konstantin>
Component: SapphireAssignee: Konstantin Komissarchik <konstantin>
Status: CLOSED FIXED QA Contact:
Severity: enhancement    
Priority: P3 CC: ling.hao
Version: unspecifiedKeywords: plan
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:

Description Konstantin Komissarchik CLA 2010-10-29 16:58:21 EDT
One common pattern is for a value property to refer to an external entity. We
already have ability to provide browsing for existing values. We need to add
ability for user to create new entities.

From UI perspective, this should appear as another button next to the browse
button. Developer should be able to attach create handlers to a property
editor in the Sapphire UI definition file. It may also be desirable to be
able to define create handlers in global fashion via an extension point.
Comment 1 Konstantin Komissarchik CLA 2010-10-29 16:58:39 EDT
Enhancement completed. To use this feature, the developer must supply create
action handler for the property editor in the sdef file. This is done as
follows:

<property-editor>
  <property>MyProperty</property>
  <action-handler>
    <action>Sapphire.Create</action>
    <impl>MyCreateImpl</impl>
  </action-handler>
</property-editor>

The action handler implementation class must extend SapphireActionHandler.
The class references in the sdef files are resolved using the import
directives specified. Make sure that the package where the implementation
class is located is imported.
Comment 2 Konstantin Komissarchik CLA 2010-11-16 12:19:34 EST
Marking as fixed.
Comment 3 Ling Hao CLA 2011-01-05 14:42:40 EST
Verified with gallery sample value property editor reference create.