Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 327174 - Update Metatype service source code to use jsr14 and generics.
Summary: Update Metatype service source code to use jsr14 and generics.
Status: RESOLVED FIXED
Alias: None
Product: Equinox
Classification: Eclipse Project
Component: Compendium (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 3.7 M3   Edit
Assignee: John Ross CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-10-07 01:13 EDT by John Ross CLA
Modified: 2010-10-18 11:27 EDT (History)
1 user (show)

See Also:


Attachments
JSR14 and Generics Support for Metatype (102.29 KB, patch)
2010-10-12 15:37 EDT, John Ross CLA
tjwatson: iplog+
Details | Diff
patch to stop using package admin (102.24 KB, patch)
2010-10-13 17:00 EDT, Thomas Watson CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description John Ross CLA 2010-10-07 01:13:50 EDT
Build Identifier: 

The Metatype service code should be updated to use the -target jsr14 compile option and generics in conjunction with OSGi 4.3.


Reproducible: Always
Comment 1 John Ross CLA 2010-10-12 15:37:27 EDT
Created attachment 180707 [details]
JSR14 and Generics Support for Metatype

Adds jsr14 support.

Adds support for generics. As part of this work, the ObjectClassDefinitionImpl.addAddtributeDefinition method signature was updated. I believe this method should be package-private but did not change the visibility. There are two remaining warnings since the LogService does not currently support generics.

Updates required execution environment to J2SE-1.5, OSGi/Minimum-1.2.

Removes deprecated export service header.

Removes unused _dfts_vector variable from AttributeDefinitionImpl.

Removes unnecessary throws clauses for SAXException causing numerous warnings.

Per discussions with Tom, removes reflection code for dealing with BigInteger and BigDecimal and replaces with direct class access since the target is now OSGi/Minimum-1.2.

Adds versions to the imported packages, with the exception of XML related packages, within the manifest. The versions for ConfigAdmin and Metatype imports will need to be changed once the org.eclipse.osgi.services project is updated.

Updates the bundle version to 1.1.0.

Updates java source copyrights where necessary. Does the value of the bundleCopyright property within plugin.properties need to be updated as well?
Comment 2 Thomas Watson CLA 2010-10-13 16:15:51 EDT
I will to review patch.  Thanks John.
Comment 3 Thomas Watson CLA 2010-10-13 17:00:40 EDT
Created attachment 180830 [details]
patch to stop using package admin

This patch updates FragmentUtils to no longer use PackageAdmin.  Additional work could be done to use BundleWiring.findEntries instead of using getEntryPaths on each fragment to search over fragments.  But we likely should do additional clean up in other bugs.  For example, the use of Vector and Hashtable should be replaced by List and Map etc.  We should also consider use DS to register the service similar to how event admin impl does.

I also changed both addAttributeDefinition and setIcon on ObjectClassDefinitionImpl to be package private.  John, please review my changes.  We should use other bugs to do any other clean up.  Thanks.
Comment 4 John Ross CLA 2010-10-13 19:57:10 EDT
(In reply to comment #3)
> John, please review my changes.

I see no issues.
Comment 5 Thomas Watson CLA 2010-10-18 11:27:00 EDT
Patch released.  Thanks for the patch and review John.