On 2/17/11 6:53 PM, Alex Karasulu wrote:
On Thu, Feb 17, 2011 at 5:10 PM, Emmanuel Lécharny<[email protected]> wrote:
Heads up. Here are some suggested changes on the Dn API. The existing
methods have a (e) prefix. The static methods have a (s) prefix. The added
methods have a (+) prefix. The deleted methods have a (-) prefix. The
renamed methods have a (r) prefix.
Constructors :
(e) Dn()
(e) Dn(SchemaManager)
(e) Dn(Rdn...)
(e) Dn(SchemaManager, Rdn...)
(-) Dn(String) not needed, the Dn(String...) can be used instead
(-) Dn(SchemaManager, String)
(e) Dn(String...)
(e) Dn(SchemaManager, String...)
(a) Dn(SchemaManager, Dn)
(a) Dn(Dn, Rdn) -> to create a new DN with a new RDN
(-) add(String)
(-) add(String…)
(-) add(Rdn)
(-) add(int, Rdn)
(-) add(int, String)
(-) addAll(Dn)
(-) addAll(int, Dn)
(-) addAllNormalized(int, Dn)
(all replaced by constructor calls)
(es) isNullOrEmpty(Dn)
(es) isValid(String)
(er) isChildOf(Dn) -> isDescendantOf(Dn)
(er) isChildOf(String) -> isDescendantOf(String)
(e) isEmpty()
(-) isNormalized() -> delete
(er) isParentOf(Dn) -> isAncestorOf(Dn)
(er) isParentOf(String) -> isAncestorOf(String)
(e) isRootDSE()
(?s) getBytes(Dn) -> package protected/delete
(?s) getNbBytes(Dn) -> package protected/delete
(-) get(int) -> delete
(e) getNormName()
(e) getParent()
(er) getParent(Dn) -> getAncestorOf(Dn)
(er) getParent(String) -> getAncestorOf(String)
(e) getRdn()
(-) getRdn(int)
(e) getRdns()
(er) getSuffix(int) -> getDescendantOf(Dn)/getDescendantOf(String)
(+) getSchemaManager() -> added
(-) normalize(Dn, Map<String, OidNormalizer>) -> delete
(-) normalize(SchemaManager, String) -> delete
(-) normalize(SchemaManager) -> delete
(-) hasSuffix(Dn) -> delete
(-) remove(int) -> delete
(e) size()
(e) equals(Object)
(e) hashCode()
(e) iterator()
(e) toString()
I won't change any of those methods unless we agreed on the operations,
because it impacts the server and studio deeply, so I want to be sure we
don't have to do that many times. Although as soon as we agree on some of
them, I'll apply the agreed on modification in code.
OK go ahead.
Note that some modifications are *very expensive* : for instance,
removing the Dn.normalize( SchemaManager ) has a huge impact on the server.
Atm, i'm trying to see where inside the server we use not normalized Dn,
and to remove them.
If any of you have some issue with any of the actions to be applied to
the Dn methods, feel free to speak your mind : I won't apply the
modifications you don't like, until we reach a consensus.
Thanks !
--
Regards,
Cordialement,
Emmanuel Lécharny
www.iktek.com