Browse Author

Cameron Crothers

Open Java and Windows Options

Well it’s officially been announced that Java J2SE, J2ME, J2EE will all be released by sun as reference implementations under the Gnu GPL + classpath exception. Which I’m sure will bring a new era of Java, especially to Linux since Java will be able to be shipped with distributions without concern just like Mono is today.

I really hope this means the MVM will get done faster it would be a great thing for the platform.

On a unrelated note one of my pet peeves about Windows is the way that Explorer.exe works. The problem is that it is the window manager as well as the file browser. What I usually find is that the file manager will lock up the window manager which is most annoying. However there is an option to make them work in separate processes which users more memory but for the stability of the system it’s well worth it.
Edit In Seperate Process

Code Cutting

Well this page always seems to get a bit neglected when nothing much happens……

Something interesting that I have come across is the w3c DOM in java and how there isn’t a definitive guide to how to output it to pretty print, ie human readable, there were a few examples with xerces-j but I thought that wouldn’t work but I tried it for good measure and it works. Even with the option that appears to be for xerces. Heres the code.

TransformerFactory tFactory = TransformerFactory.newInstance();
try {
    Transformer transformer = tFactory.newTransformer();
    transformer.setOutputProperty(OutputKeys.INDENT, "yes");
    transformer.setOutputProperty("{xml.apache.org/xslt}indent-amount", "4");

    DOMSource source = new DOMSource(document);
    transformer.transform(source, new StreamResult(f));
} catch (TransformerConfigurationException e) {
    e.printStackTrace();
} catch (TransformerException e) {
    e.printStackTrace();
}

Have fun and I found a great plugin for doing the code colouring, iG:Syntax Highligher.

Interesting Java Proposal

In the java community there has been a long and heated debate about adding delegates to the language. There is a white paper on Suns website explaining there position on the debate. Which is in response to Microsoft’s implementation of them in J++ which in tern could be deemed as the turning point for Microsoft to then create the entire .NET architecture. Although it doesn’t have a date on it using the way back machine we can see that the paper has been around at least since the beginning of 1999.

I hadn’t read the paper until just last week and I agree with what it’s saying functors/delegates are a quite strange structure in c/c++/.NET and can be difficult to explain. On a side not I have also read that Java is a much more strongly OO architecture than .NET, which is more an easy wrapper over windows as always (grr I can’t stand MFC) anyway… I was looking at some new features for c# 3.0 and in particular extension methods which I am of the opinion are really syntactic sugar for the lazy VB programmers out there, ducks for cover.

But in my search I also found a new paper that is proposed for Java written by three prominent figures including James Gosling, the farther of Java, Closures for Java, there is a pdf but this is a verbatim copy on Neal Gafter’s blog.

Neal has 4 other posts about them and I recommend reading them all if your head can get around them, it took me 2 goes at it. I can see how these constructs could be very useful in getting rid of boiler plate code from a lot of Java programming, which is always a good thing, but I can also see it becoming a problem as well when used too much. Since it is a way of almost changing the language itself you could quickly start having the same headaches you get for heavily preprocessed c/c++ code.

I am still not sure as to whether they would be a good thing for the language if introduced it will be something that will probably not make it into begging programming courses. One of the things I have always liked about Java is that once you understand the OO principles of the language which can be picked up in a short amount of time virtually all api’s and constructs can be created by the programmer. If not very well designed used but use none the less.

I’ll keep tracking Neal’s blog for more insights into uses before I am really sure but it is none the less a very radical and interesting proposal none the less.

Cracking 1,000

After 27 Months (2 Years, 3 Months), 104 posts, a change of host, the addition of a gallery and many changes in theme. JBlog this month has had over 1,000 unique visitors.

Although it’s not really that large in the grand scheme of things but it’s significant to me :P.

There has been a large increase in traffic this month in particular since last month I received just over 600 unique visitors for July and most of the additional traffic seem to be coming from the main page of my provider profusehost. It has been linked from there since a week after the move from buildtolearn but they must be receiving a lot more hits too.

That’s all there is folks.

Big News

Well once again me like some of my friends find it hard to actually get to the content page and add new stuff to their blogs but I think the news of the last 2 weeks really deserves a blog post.

Well probably the biggest news is from this week, Merinda and I have bought a block of land! And get this it’s in Mernda, that will make for interesting conversations and lots of spelling names over the phone. And it only took us a week to go from looking at existing properties to buying land and looking at houses to build!

With stamp duty here in Victoria being so high it doesn’t really make much sense to buy a fairly expensive property that will be over 20 years old.

The other big news is that I received a employee recognition award which is always quite strange. It was for integrating one of Microsoft’s better technologies into our product, the ability to write mini-dumps in the event of crash. Which then allows us to see the stack and trace the line of code that the crash occurs on.

Finally I wish to say that mustang (or JDK6 as it is now known) ROCKS it makes programs such as jbidwatcher seem so much more polished. With true double buffering the windows no longer goes gray when repainting, and the new register allocator that I talked about a while ago makes every java application fly. It’s still in beta but when it releases for real it will be a great step forward and with the open sourcing of the platform to be complete by ruffly the end of 2007 I’m looking forward to more java technology into the future.

The Long Silence

Well it’s been well over a month since my last post I am getting really really slack. What’s happened in that time? Well quite a lot really.

  • Holidays
  • Flights
  • And a stupid film

And I will outline them in that order :P

Well last week Merinda and I packed up and went on a 4 day holiday to Beechworth and stayed at the Swiss Cottages there it was a most relaxing time and can recommend the accommodation full heartily.

Last weekend (1 July 2006) Merinda and I got to go on a second holiday to Brisbane overnight. Our fantastic broadband Internet provider, aaNet, flew both of us up for a party they were having. We got the flights because I am a moderator on their forums. I only started getting back into the forums a few weeks before the trip was announced so it was great timing. It was a lot of fun and meeting people you have only ever communicated to in a digital medium was interesting. We spent most of our time playing cards which is a great day in our books.

And to the final point we went a saw the new Superman movie, Superman Returns, for a $300 million movie it was a bit of a disappointment really.

Begin rant/spoilers

I don’t know what it is if it’s the Superman story itself or the story of this particular movie in particular but the character to me seems to be a bit lacking. When compared to the X-Men or Spiderman series, Superman the character is very bland in that he is predictable in his actions, there is no human side to his character (I know he is an alien). But even when stabbed with Kriptionite after it is removed he is fine again.

Also he stands for all things moral however he has an illegitimate child with Louis Lane, it just lacks consistency. The movie also shows that Superman is helping people all around the word with their problems, ie. a burning house in Germany, so in one moment he is trying to help everyone and then goes to his day job in Metropolis at the Daily Planet. What about all the people with burning houses now?

I just find it hard to identify with this interpretation of the character. I was expecting a reinterpretation like the original Batman movie or Batman Begins however it was just really the next Superman movie with better visual effects.

End rand/spoilers

Anyho that’s about it I would just like to add decaf sucks, I had some yesterday and I guess now I know what I really appreciate from coffee.. the caffeine hit.

Undelivered Mail And Incredible Building

Well aren’t I the lazy boy I haven’t put up a post in ages….

Well this week has been a bit stressful in getting a build ready so hopefully I can be excused.

If you are a /. reader you may have heard about a small start up called blue security who had a novel concept of fighting spam by sending thousands of un-subscribe emails to the perpetrators of the spam. I signed up for this free service and started fighting my spam.

However one of the leading spammers in the world didn’t like this idea much and started a campaign to stop the company. Bringing down websites such as tucows and typepad in the process. And eventually Blue Security threw up their hands and called it a day.

This has left me without a spam fighting technique and now with my email address well and trully in their address books. To the point now that I am receiving 2-5 emails a day saying that mail was undelivered so these quite insidious people are now using my address as a return address for the spam they send out. How Great!!!

On a note of the more professional nature we are trialling Xoreax Incredibuild, a distributed C++ build system for Visual Studio and it is going well. Nothing quite like your colleagues cpu idle cycles working for you instead of against.

Well I guess that is enough angst for one day.

Strange Cats & Broken PDA's

Well today marks the end of a quite weird weekend my cat, Alex, has had a quite traumatized weekend.

For some reason she got spooked and was afraid of everything and anything. The washing basket, feet etc. and both Merinda and I are a little worse for the wear. You know cats and all. So she has us both worried since she wont come out from under the bed and will bang her head against the bottom of it when she frightens herself and jumps.

On the other topic my Tungsten E PDA didn’t want to turn on last week got me thinking if I would replace it and if I did what would I replace it with.

With my constant search for open platforms and non-Microsoft solutions would I buy another Palm or go for Windows Mobile. I have always had a soft spot for Palm since they invented the market but they haven’t released any PDA’s with a new operating system since version 5. And although they say that a Linux based Palm OS is in the pipes not even previews have been seen. So I think if my PDA does really die I might be swapping one proprietary platform for another. Or maybe a Laptop is enough techno junk for me.

<Update removing references to deleted gallery>

BenQ s52 v54 ACPI

I have now had a few requests from non native English speakers for the compiled version of the ACPI DSDT that I have created for my laptop. So it is linked here.

Compiled DSDT for BenQ s52 v54

The source copy is located on the acpi website. Please note that this is the upgraded BIOS that you can get from benq version A32.

See the DSDT page from acpi for how to get this into your kernel.

Also thanks to Peter Westwood for his mime-config plugin for wordpress for sorting out the upload of this perculiar file type.