To consume updates when there are changes to the configuration properties, the application registers a listener delegate with the OData SDK. The client SDK notifies this listener object whenever there is a configuration update from the server. The listener should implement the LiteSUPMessagingClientConfigListener protocol.
- (void) onConfigurationChange: (NSInteger) iPropertyID value: (id) oValue
@implementation UserRegistration
ODPClientListeners* listeners = [ODPClientListeners instance];
[listeners setConfigChangeDelegate:self];
LiteSUPUserManager* manager = [LiteSUPUserManager getInstance:APPID];
…………….
- (void)onConfigurationChange:(NSInteger)iPropertyID value:(id)oValue
{
if(iPropertyID==MCL_PROP_ID_APPLICATION_CUSTOMIZATION_RESOURCES)
{
NSData *l_customResourceData=nil;
@try {
l_customResourceData=[LiteSUPAppSettings getCustomizationResourceBundleWithCustomizationResource:oValue userName:supuser passWord:s3puser];
}
@catch (NSException *exception) {
NSLog(@"exception name: %@ reason: %@",[exception name],[exception reason]);
}
}
}
}