I've been off working on the iPhone SDK, so I wasn't too interrupted when NetBeans 6.1 made an early entrance this week. That was until Nomine said to me "What I'd like is an application which looks up the people you are following on Twitter and the people following you on Twitter and shows who the mutual followed/following are"...
So, I broke out NetBeans 6.1 and gave it a go. First up was the Twitter access. That turned out to be very easy; NB6.1 has precanned code generators for lots of well known web services out there. So I selected Twitter and the appropriate function in the tree and drag it into my code. And pow!, there it is, complete with separate classes generated to handle the result and authentication, including popping up a user name/password authentication dialogue.
Parsing the XML was more interesting. I decided to use the XML Schema design tool in NetBeans 6.1, which I hadn't used before, but after about an hour or so of fiddling, I had a schema file which was automatically generating code for JAXB.
Next up, feeding the result of the Twitter API to create objects... Already in there. The result of the Twitter API call can be parsed into a JAXB object by calling a method on the result and telling it what JAXB class you want it turned into.
The GUI, Matisse as usual, but it's just getting better. Now there's Java Application Framework support in there I made a JAF application, and getting a button to call up Twitter and do all that parsing was a matter of picking the button and doing "Set Action" on it. NetBeans 6.1 can also code generate all the background processing bits, including an animated busy indicator.
And that was an application built. Doesn't actually change anything but boy, it shows how useful NetBeans 6.1 is.
Tuesday, April 29, 2008
Wednesday, April 16, 2008
Inconsolable....
Cross posted from Codepapacy
I was looking for monospaced fonts, after I was reminded that Microsoft had actually made a decent monospaced font with Consola. After some hunting, and a false start finding the original Inconsolas, I found the latest version, with a slashed zero, and my it looks good. Check it out here.
I was looking for monospaced fonts, after I was reminded that Microsoft had actually made a decent monospaced font with Consola. After some hunting, and a false start finding the original Inconsolas, I found the latest version, with a slashed zero, and my it looks good. Check it out here.
Sunday, April 13, 2008
6 People and their ids....
Playing with the iPhone SDK? If you are working with the addressbook, you might want to know what the default record ids of the simulated addressbook is.
Now you know. This might be handy for testing if nothing else.
1 - Kate Bell
2 - Daniel Higgins
3 - John Appleseed
4 - Anna Haro
5 - Hank Zakroff
6 - David Taylor
Now you know. This might be handy for testing if nothing else.
Friday, April 04, 2008
Grails and Groovy....
I've done an article on Grails and Groovy, which you can find at here on Heise Online UK. It's an introduction to what Grails is about.
Subscribe to:
Posts (Atom)