Java as a second language – part 1,228,325

Every time I start to think this java/Android coding is like riding a bicycle (which I fell off of sometime in early 2002), I get brought back to reality.

This weekend I discovered a couple of things, more slowly than I care to admit:

1. Parsing XML on Android is slower than…well, let’s just say it’s slow. I didn’t really believe what I was seeing at first, so I started looking around. Looks like I may go back to my alternate model using SQLite.

2. Java XML – getLocalName vs getNodeName – Although I had a basic grasp of the fundamentals of XML, I didn’t really have to deal with the real intricacies of XML schemas until I started working with BizTalk. At that point I learned all about ‘local’ names and erring on the side of caution burned me in this case. So I was trying unsuccessfully to ‘getLocalName’ in Java code but the result was always ‘null’. Lo and behold – ‘getLocalName’ seems pretty useless. Reference the following:

Here is what SHOULD happen IMHO.

And HERE is (I assume) what actually happens in my case returning NULL in all cases, even though the Eclipse debugger shows clearly a populated ‘localName’ property in my ‘variables’ window. If schemas have not been explicitly enabled/created/invoked via some magical voodoo, getLocalName won’t do anything.

Leave a Reply

Your email address will not be published. Required fields are marked *

+ 3 = twelve

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>