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

Bug 364232

Summary: Standardize the data service pattern with a common base class
Product: z_Archived Reporter: Konstantin Komissarchik <konstantin>
Component: SapphireAssignee: Konstantin Komissarchik <konstantin>
Status: CLOSED FIXED QA Contact:
Severity: enhancement    
Priority: P3 CC: shenxue.zhou
Version: unspecifiedKeywords: plan
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:

Description Konstantin Komissarchik CLA 2011-11-19 17:46:04 EST
Many of the services that form Sapphire API fall in the category of providing data (as opposed to operations). For these data services, a pattern has emerged that captures a way to handle caching computation of this data and handling listening/refresh. This pattern is currently manually replicated among various services such as EnablementService. Rather than continuing this way, we should extract this pattern into a common base class... DataService.
Comment 1 Konstantin Komissarchik CLA 2011-11-20 22:52:09 EST
Defined DataService as the common base for all such services and converted the following list of services to use this common base. There are other services that should probably be made data services, but this will do for now.

DefaultValueService
DependenciesAggregationService
DependenciesService
DerivedValueService
EnablementService
FileExtensionsService
ImageService
InitialValueService
JavaTypeConstraintService
PossibleTypesService
Comment 2 Shenxue Zhou CLA 2011-11-28 17:40:43 EST
Verified the class hierarchy of the generic Service class and their usage in Sapphire samples and our internal Sapphire adopter product.