Bug 160903 - String constant as identifier for PropertyChangeEvent
String constant as identifier for PropertyChangeEvent
Status: NEW
Product: xml
Classification: Unclassified
Component: XAM
6.x
All All
: P3 (vote)
: TBD
Assigned To: Svata Dedic
issues@xml
: API_REVIEW_FAST
Depends on:
Blocks: 134153
  Show dependency treegraph
 
Reported: 2009-03-23 17:00 UTC by Nikita Krjukov
Modified: 2011-11-28 18:14 UTC (History)
3 users (show)

See Also:
Issue Type: ENHANCEMENT
:


Attachments
The diff is going to be applied (4.28 KB, text/plain)
2009-03-31 15:03 UTC, Nikita Krjukov
Details
A new diff with apichanges.xml (11.27 KB, text/plain)
2009-04-03 20:11 UTC, Nikita Krjukov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nikita Krjukov 2009-03-23 17:00:19 UTC
It's necessary to declare a new string constant as an identifier for the PropertyChangeEvent. 
The constant is going to be used for sending a new kind of notification events about transactions' completion.
It is a part of changes in scope of the issue #134153

It is suggested to put the new constant here:

--------------------------------------------------------
package org.netbeans.modules.xml.xam

public interface Model

String TRANSACTION_COMPLETED_PROPERTY = "transaction_completed"; // NOI18N
--------------------------------------------------------
Comment 1 Nikita Krjukov 2009-03-23 19:22:55 UTC
The changes don't affect any documentation. At least I didn't manage to find any mentioning about other events' constants.
Comment 2 Jaroslav Tulach 2009-03-25 09:52:47 UTC
Y01 Prepare the actual diff
Y02 Don't forget about proper versioning and @since tags
Y03 Write a test to show what this is good for
Comment 3 Nikita Krjukov 2009-03-31 15:03:31 UTC
Created attachment 79145 [details]
The diff is going to be applied
Comment 4 Nikita Krjukov 2009-03-31 15:18:11 UTC
I changed the proposed name of property form TRANSACTION_COMPLETED_PROPERTY to MODEL_CHANGED_PROPERTY 
because it tuned out that not each transaction comes to model's changing. But the required behavior is 
to inform about valuable model's changes.

The test in the attached diff isn't so expressive because the XAM model is too abstract.
The advantage of the enhancement is more visible from real XML models based on XAM. 
See the explanations in the issue #134153.

Some additional changes are required to JUnit tests in other modules because some tests expect 
a specific number of events from the model. 
Comment 5 Jaroslav Tulach 2009-04-02 11:39:51 UTC
Y04 You need a note in apichanges.xml, increment spec version of the module, make sure all modules that use this new 
API depend on the new spec version. More info at: 
http://openide.netbeans.org/tutorial/api.html
http://openide.netbeans.org/versioning-policy.html
Comment 6 Nikita Krjukov 2009-04-03 20:11:39 UTC
Created attachment 79417 [details]
A new diff with apichanges.xml
Comment 7 Nikita Krjukov 2009-04-03 20:18:57 UTC
I've increased the specification version from 1.5.0 to 1.6.0

I've increased a dependency version at the xml.schema.model module. It uses the new constant in tests. 
It's the only place where it is used so far.


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo