I think it may be not good idea eg. TLDAPAttributeList.Add TLDAPAttributeList.Add TLDAPAttributeList.Add TLDAPAttributeList.Add
// setup every item TLDAPAttributeList[i].AttributeName =.. .. .. .. TLDAPAttributeList[j].AttributeName =.. .. .. .. it's very obstacle. why not do like the following cn_attr = TLDAPAttribute.Create //set up cn_attr ... ou_attr = TLDAPAttribute.Create //setup ou_attr ... attr_list= TLDAPAttributeList.Create attr_list.add(cn_attr) attr_list.add(ou_attr) ... I think the code smell better. gtalk:[email protected] On Fri, Dec 19, 2008 at 11:21 PM, Lukas Gebauer <[email protected]> wrote: >> TLDAPAttributeList has a Add method without any param, and it return a >> new TLDAPAttribute. But usually we create a new Attribute and fill >> attributename and value, then we continute to put the attribute object >> to a attributelist. So I think TLDAPAttribute should give a >> Add(TLDAPAttribute). > > Because TLDAPAttributeList owning all TLADPAttributes, then it cretae > and destroy it by self. > >> TLDAPAttribue only a attributename property , i don't know why the put >> method is undocumented. and IsBinary is read-only , an is it means >> TLDAPAttribute could judge whether a value is binary? > > Wrong way. It have many and man other properties and methds, because > it have parent clas TStringlist! Put method is not documented, > because it is internal method not designed for your usage. You just > writing or reading attribute values from stringlist, and setting > attribute name. Nothing else. > > > > -- > Lukas Gebauer. > > E-mail: [email protected] > http://synapse.ararat.cz/ - Ararat Synapse - TCP/IP Lib. > > > ------------------------------------------------------------------------------ > _______________________________________________ > synalist-public mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/synalist-public > ------------------------------------------------------------------------------ _______________________________________________ synalist-public mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/synalist-public
