Hi Lukas,

I have tried your the changes that you suggested, it works fine

But!!!!!!
Later what i tried a case when

mimeprofile:
               <value field="EMAIL_FLAGS" combine=";" conversion="multimix">
                  <enum name="WORK,INTERNET" value="B0"/>
                  <enum name="HOME,INTERNET" value="B1"/>
                  <enum name="INTERNET" value="B2"/>
                  <enum name="PREF" value="B3"/>
               </value>

vCard in addressbook(file based):
        EMAIL;WORK,INTERNET:w...@email.com  //seperator is a coma ( , )
        EMAIL;HOME,INTERNET:h...@email.com
        EMAIL;INTERNET:inter...@email.com


on doing a slow sync, resulted in the server accepting the contact vCard as
required i.e. the server saves w...@email.com with TYPE=WORK;TYPE=INTERNET,

Logs show;

- 17 :  multiline EMAIL           [1000, 100,     0] : <array with 3
elements>
                                      -- element    0 : "w...@email.com"
                                     -- element    1 : "h...@email.com"
                                      -- element    2 : "inter...@email.com"
 - 18 :  integer EMAIL_FLAGS       [   0, 100,     0] : <array with 3
elements>
                                      -- element    0 : 1
                                      -- element    1 : 2
                                      -- element    2 : 4

But on doing a refresh from the in coming vCard contains the following:

       EMAIL;WORK;INTERNET:w...@email.com  //seperator is a semicolon( ; )
       EMAIL;HOME;INTERNET:h...@email.com
       EMAIL;INTERNET:inter...@email.com

the syncevolution Engine is unable to understand the incoming type and thus
again it saves the above as

        EMAIL;INTERNET:w...@email.com
       EMAIL;INTERNET:h...@email.com
       EMAIL;INTERNET:inter...@email.com

What I believe is that if  I am able to chanage the semicolon ( ; ) between
WORK;INTERNET
 to a coma ( , ) before it is parsed and flag values are calculated I will
be able to obtain the desired result

if you could suggest me some way  by which this can be done.


On Thu, Mar 13, 2014 at 1:18 PM, Lukas Zeller <l...@plan44.ch> wrote:
> Hi Rajesh,
>
> On 12.03.2014, at 11:00, rajesh kumar pawar <pawar.rajesh...@gmail.com>
wrote:
>
>> I am working to customize the Syncevolution and am facing issues with
>> combination of TYPE parameters.
>>
>> The problem I am facing is that the syncevolution is not producing
>> FLAGS or the Bitmap values for the instances where there is a
>> combination of TYPES like HOME,INTERNET etc.
>
> The idea between the "bitmap" and "multimix" mapping modes are that each
TYPE is mapped to a bit.
>
>>               <value field="EMAIL_FLAGS" combine=","
conversion="multimix">
>>                  <enum name="WORK,INTERNET" value="B0"/>
>>                  <enum name="HOME,INTERNET" value="B1"/>
>>                  <enum name="INTERNET" value="B2"/>
>>                  <enum name="PREF" value="B3"/>
>>               </value>
>
> The first two <enum>s don't work because their name part already contains
combined names. Just convert these to:
>
>>               <value field="EMAIL_FLAGS" combine=","
conversion="multimix">
>>                  <enum name="WORK" value="B0"/>
>>                  <enum name="HOME" value="B1"/>
>>                  <enum name="INTERNET" value="B2"/>
>>                  <enum name="PREF" value="B3"/>
>>               </value>
>
> With this, you map WORK to bit 0, HOME to bit 1, INTERNET to bit 2 etc.
>
> So when an incoming vCard has TYPE=WORK,INTERNET (or INTERNET,WORK),
you'll get EMAIL_FLAGS with bit 0 and bit 2 set (= 2^0 + 2^2 = 1 + 4 = 5 =
0b101)
>
> Similarily, for TYPE=WORK,PREF (or PREF,WORK) you'll get bit 0 and bit 3
set (=2^0 + 2^3 = 1 + 8 = 9 = 0b1001)
>
> This way, you can easily parse and generate any combination of the basic
TYPEs.
>
> Best Regards,
>
> Lukas
_______________________________________________
os-libsynthesis mailing list
os-libsynthesis@synthesis.ch
http://lists.synthesis.ch/mailman/listinfo/os-libsynthesis

Reply via email to