I'm sure it's possible in Java (at least in those versions that allow you to access system environment variables), but Java doesn't sound like the best language for this, as it doesn't know anything about the NT shell. Is there some reason you have to use Java? Could you consider using NT command script, Perl, Python...?
Betty Rubble? Well, I would go with Betty... but I'd be thinking of Wilma.