directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Zoerner <ste...@labeo.de>
Subject Re: Groovy and LDAP, how to accomplish this?
Date Sat, 16 Jun 2007 22:31:03 GMT
Stefan Zoerner wrote:
> ---
> heather = [:]
> heather.objectclass = ['top', 'person']
> heather.sn = 'Nova'
> heather.cn = 'Heather Nova'
> 
> con.add('cn=Heather Nova,dc=example,dc=com', heather)
> ---
> 
> I like it syntactically :-)
> 

In fact, I am a Groovy newbie. It is even more simpler, if you write the 
entry map like this:

---

heather = [
   objectclass: ['top', 'person'],
   sn: 'Nova',
   cn: 'Heather Nova'
]
con.add('cn=Heather Nova,dc=example,dc=com', heather)

---


Greetings,
     Stefan


Mime
View raw message