Changes between Version 9 and Version 10 of FdoEnhancedVersionSupport


Ignore:
Timestamp:
Oct 18, 2007, 10:02:12 AM (17 years ago)
Author:
gregboone
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • FdoEnhancedVersionSupport

    v9 v10  
    218218}}}
    219219
    220 
    221 
     220===== IProviderRegistry::!GetProviders (modified) =====
     221
     222!GetProviders will be enhanced to allow a client to determine if a particular provider is compatible with the current FDO:
     223
     224{{{
     225FdoProviderCollection* IProviderRegistry::GetProviders( bool compatibleOnly = false)
     226}}}
     227
     228compatibleOnly is a new parameter. When false, all registered providers are returned. When true, only providers compatible with the current FDO are returned.
     229
     230For Example, the following code checks to see if a particular provider is compatible with the currently running FDO:
     231
     232{{{
     233FdoPtr<IProviderRegistry> registry = FeatureAccessManager::GetProviderRegistry();
     234FdoString* providerName = L"OSGeo.SDF.3.1";
     235FdoPtr<FdoProviderCollection> providers = registry->GetProviders(true);
     236bool isCompatible = (providers->IndexOf(providerName) >= 0);
     237}}}
     238
     239===== FdoProvider::!GetIsCompatible (new) =====
     240
     241IProviderRegistry::!GetProviders implementations can use this function to test whether a particular provider is compatible. The signature is:
     242
     243{{{
     244bool FdoProvider::!GetIsCompatible()
     245}}}
     246
     247It returns true if this provider is compatible with the currently running FDO, and false otherwise.
     248
     249For Example, !GetIsCompatible is used to test the provider's compatibility:
     250
     251{{{
     252FdoPtr<IProviderRegistry> registry = FeatureAccessManager::GetProviderRegistry();
     253FdoString* providerName = L"OSGeo.SDF.3.1";
     254FdoPtr<FdoProviderCollection> providers = registry->GetProviders(false);
     255FdoInt32 ix = providers->IndexOf(providerName);
     256FdoPtr<FdoProvider> provider = providers->GetItem( ix );
     257bool isCompatible = provider->GetIsCompatible();
     258}}}
     259
     260===== FdoPhysicalSchemaMappingCollection::!ReadXml (modified) =====
     261
     262When this function encounters a Schema Override Set, it searches the provider registry for the earliest provider whose version is equal or greater than the Schema Override Set's version. It then invokes that provider to read the Schema Override Set.
     263
     264With this proposal, the latest provider that is binary-compatible with the current FDO will be chosen.
     265
     266It is possible that the chosen provider will be too old to read the given Schema Override Set. When the provider reads the Schema Override set, it may encounter a construct that it doesn't understand. If this happens, the action taken depends on the current !ErrorLevel passed to ReadXml, via the flags parameter:
     267
     268High – an error is reported[[br]]
     269Other – the construct is ignored[[br]]
     270