Brett Morgan's Insanity Weblog Zilla : Days of our lives. Honestly.
Updated: 6/10/2002; 1:22:09 PM.

 

Subscribe to "Brett Morgan's <Strike>Insanity Weblog</Strike> Zilla" in Radio UserLand.

Click to see the XML version of this web page.

Click here to send an email to the editor of this weblog.

 
 

Tuesday, 2 July 2002

javax.crypto and java.util.zip

Y'know what woulda been smart. If the Message Authentication Code stuff in javax.crypto gave back MAC's that implemented java.util.zip.Checksum. Would have made for zero insertion force mac'ing of files. Oh well. Which reminds me, i need to download http://bouncycastle.org/'s encryption libs again. Good to see some Ozzies doing crypto. :)
7:33:03 PM    

Swing HTML Parser

Well whadya know. Swing's HTML parser is as ugly as sin, but it works. I can retrieve all the A tag hrefs I can see in the doc, and it only took about 30 lines of code. Of course, most of that is boilerplate code (I tend to code in a haskell'esque style. I find it easier to reason about code that way. Tis why I am still productivly coding in the middle of a two tissue box cold. Bah.

Now, if only java.net.URL had an absolutify() call to allow me to easily sort out relative hrefs. Back to digging through HttpClient. Lalala.

I've also decided that if I ever need to really pull through some project where I require the services of a real html parser, I am going to use Mozilla's parser. I should possibly think about re-learning c++ at some point ;)

[Later...] D'uh. You absolutify a relative URL by creating a new url while supplying a context URL as well. That was easy. RTFM. :>
6:53:39 PM    


JTidy & JDOM

Tried to get JTidy to feed JDom via the joys of org.w3c.dom.Document. No dice. Seems JDom is spitting chips based on the doctype info. That, and JTidy is writing all over stdout, even though I am trying to make it forward warning info into an internal data structure. Not nearly so impressed with JTidy anymore Timmy. Not impressed at all.

Maybe I am going to have to forward port parts of WebSphinx. Or I could play with the HTML parser that is part of Swing. Eggads. :P
3:38:47 PM    


Moz SVG status

Silly question. Anyone know how stable / advanced mozilla's svg support is? It is somewhat of cute idea to be able to generate webpages that have all their graphics inline. Admittedly, it would only work in Moz.

But, did cute things ever have to be cross browser? :)
2:36:15 PM    


Radio and Port 80

Why, oh why, is Radio running on both port 5335 and port 80 on localhost? I suppose it might make sense given the rants and raves about "desktop webserver" software. But, I'd at least expect it to turn up in a configuration item somewhere.

I wonder what I am going to break when I turn port 80 off ...

[Later...] Inside Radio the app, as opposed to radio the web pages, there is an option to alter the port of the webserver. Bumped to port 81. Wonder where the configuration is for port 5335? Heh. Nothing appears to have broken yet, but then again, I aint online either.
1:34:25 PM    


Evil Thought of the Day

If you desperatly need to build an application with a "fruit salad" interface (y'know, something that most people would look to flash to do), you can use Batik. Batik has a Swing component that can display SVG documents in, and you can modify the SVG dom from the app in response to events and the like. Of course, there are threading issues, but Batik has a cute idiom for handing actions "across the fence" consisting of handing over Runnable instances that get added to a run queue, either as add and forget, or add and wait.

I can see the need to do a Batik based app just to see how evil the above really is. Heh.

(Of course, the same could be done for applets as well. But, does anyone still do applets?)
12:59:46 PM    


WebSphinx

Well, i can say one thing. Eclipse is quite helpful when it comes to trying to understand how much work is involved in bringing an old source base upto current spec. Anone know where Netscape's JSObject and sundry libs hides out these days? Eeek. I think I am going back to playing with Batik. I enjoy making pretty pictures. ;)
12:20:05 PM    

HttpClient bug

HttpClient is somehow modifying the location header on a 302 redirect from http://host:port/path to http://host/path. Am I up to debugging HttpClient? Not today. Bugger.

On to WebSphinx then.
12:00:12 PM    


Dreaming of WiFi from bed

Sick at home, and all I want is the ability to hit the internet from bed. My kingdom for a 802.11b card for my desktop box!
11:08:15 AM    

Continuing trials and tribulations of a baby Eclipse user

Eclipse's java mode is quite nice. It follows msword conventions of underlining things with red squiggles when they don't make sense. Would be nice if I could figure out how to elicit the actual error behind the red squiggle sometimes tho. And yes, i did finally figure out how to add jars to a project. None too obvious.

[Later...] Two ways to easily find out the cause of the req squiggle of death:

  • Save the file out (to bring the java parser and the editor back into sync) and then click on the exclamation or stop sign in the left margin. Eclipse even gives sets of options on how to fix the problem. It then (get this!) goes ahead and makes the changes for you.
  • Change to the resource perspective, and then a short description shows up in the tasks listing.

    And the answer to the "adding jar to project" riddle? In either the "Package Explorer" or the "Navigator" windows, right click on the project line, and select properties. In the pop up, "Java build path" should be selected in the left hand tree nav, select "Libraries tab on the tab-pane on the right. Then click "Add external jar". Compared to netbeans - right click in the explorer and select "Add Jar" - thats a tad more elongated than really necessery.

    I'd actually ask everyone to put statistical analysis into their code to see what the user is really doing with the application, and if there are common tasks that everyone is doing, then give shortcuts to these common actions. Yes I know this destroys the nice logical grouping that took you hours to come up with, and spent days justifying in meetings with various pig headed management types, each with their own Bikeshed to paint, but the real name of this game is making your software easy to use.

    And if you see that people are frequently doing a two or three step process that you allow to be done in one step, then for pete's sake use that help thingey to tell the user there is an easier way. Just dont do it when they are busily trying to get something done.

    Geez, I am a painful customer aint i? :)
    11:04:16 AM    


  • © Copyright 2002 Brett Morgan.



    Click here to visit the Radio UserLand website.

     


    July 2002
    Sun Mon Tue Wed Thu Fri Sat
      1 2 3 4 5 6
    7 8 9 10 11 12 13
    14 15 16 17 18 19 20
    21 22 23 24 25 26 27
    28 29 30 31      
    Jun   Aug

    Previous Next
    blogchalk: Brett/Male/26-30. Lives in Australia/Sydney/Carlingford and speaks English. Spends 60% of daytime online. Uses a Faster (1M+) connection.
    this site is a java.blog