Hi Cl?ment,

Cl?ment OUDOT a ?crit :
> Hello LSC experts,
> 
> I try to map one source attribute into 2 destination attribute :
> - sAMAccountName -> uid
> - {SASL} + sAMAccountName + "@example.com" -> userPassword
> 
> I made my own bean (to manager source attributes that are not in
> destination directory).
> 
> The solution I found is to use a private variable, but maybe there is a
> better solution?

I can think of two others ways to do this. But there is no "right" way,
you do it however you like :)

As I understand the source attribute you map into 2 destination
attributes is "SAMAccountName".

1) Just map both (or more) destination attributes in the
mapSAMAccountName() function :
        ...
        mapString(doc, "uid", FrenchFilters.filterString(value));
        mapString(doc, "userPassword", "{SASL}" + valTmp + "@example.com");
        ...

2) Get the value of the attribute from the source object class (soc):
        mapString(doc, "uid", soc.getSAMAccountName());

Hope this helps.

Jon

PS: Thanks for using the new mailing lists :)

Reply via email to