BUG-582: optimize replaceWithCamelCase
authorRobert Varga <rovarga@cisco.com>
Sun, 8 Jun 2014 10:23:13 +0000 (12:23 +0200)
committerRobert Varga <rovarga@cisco.com>
Wed, 18 Jun 2014 09:43:47 +0000 (11:43 +0200)
commit178d21d614c1c0d0983a1d8ac62cbc7014831794
tree5b2cb7b50551e020a2de8399a32ef54ccbf1148a
parentda8a0493cbf741db7aa40b86633fb7b06882267c
BUG-582: optimize replaceWithCamelCase

Optimize replaceWithCamelCase() by not instantiating a string just to do
a toUppserCase.

Also the initial character lookup is done on the original string, such
that we can elide any object instantiation if the character to be
removed is not found.

Change-Id: Iee81f1967d47a63668bf14b319a2f46715e6866b
Signed-off-by: Robert Varga <rovarga@cisco.com>
code-generator/binding-generator-util/src/main/java/org/opendaylight/yangtools/binding/generator/util/BindingGeneratorUtil.java