예제 #1
0
// ---------------------------------------------------------------------------
// 
// ---------------------------------------------------------------------------
//
void CSpsBackupHelperPerformer::ReadSettingsL()
    {
    XSPSLOGSTRING( "CSpsBackupHelperPerformer::ReadSettingsL IN" );
    RIdArray ids;
    CleanupClosePushL( ids );
    iServiceProviderSettings->FindServiceIdsL( ids );
    
    // Make sure that id's are in correct order!
    for( TInt i = 0; i < ids.Count(); i++ )
        {
        TRAP_IGNORE( 
            CSPEntry* entry = CSPEntry::NewLC();
            User::LeaveIfError( 
                iServiceProviderSettings->FindEntryL( ids[i], *entry ) );
            
            // Make sure that all properties are loaded
            entry->GetAllProperties(); 
            iEntries.AppendL( entry );
            CleanupStack::Pop( entry );
            )

        }
    
    XSPSLOGSTRING2( 
        "CSpsBackupHelperPerformer::ReadSettingsL Service count=%i", 
        iEntries.Count() );
    
    CleanupStack::PopAndDestroy( &ids );
    XSPSLOGSTRING( "CSpsBackupHelperPerformer::ReadSettingsL OUT" );
    }
예제 #2
0
void CSPSettingsEngine::ConvertSpEntryToCenRepArrayL( const CSPEntry& aEntry, 
                                                     RIpAppPropArray& aArray )
    {
    CCenRepDatabaseProperty* property = CCenRepDatabaseProperty::NewLC();
    
    property->SetName( EServiceName );
    property->SetValue( aEntry.GetServiceName() );
    User::LeaveIfError( aArray.Append( property ) );
    CleanupStack::Pop( property );
    
    TInt count = aEntry.PropertyCount();
    const RPropertyArray& entryArray = aEntry.GetAllProperties();
    
    ConvertSpArrayToCenRepArrayL( entryArray, aArray );
    }