Monthly Archives: March 2006

Devgone

I wanted to continue with some of my diary entries which relate to programming. I don’t know what I was thinking when I wrote this one here dated the 8th of August of 2005: A coworker moved on to greener code, before his last day we had a lot of knowledge transfer sessions. This guy [...]

Posted in Java, Programming, Rant, TechKnow | Leave a comment

Test Plenty

The following is from an entry in my diary dated back to June of 2005: Test yourself before you wreck your. One of the interview questions asked during my interview for my current position was, “what do you do when adding a new feature?” I went on about understanding the specification, writing a use case, [...]

Posted in Programming, TechKnow | Leave a comment

MESA Day

Last Saturday I gladly volunteered as a web design judge for MESA day in San Jose State University. MESA stands for Math Engineering Science Achievement and is a program run throughout California to try to promote the sciences in socioeconomic disadvantaged communities. For the web design contest, student where given a topic and 45 minutes [...]

Posted in Rant, TechKnow | 3 Comments

Select Top Candidate

Here is an interview questions that I have been asked. Given an employee table with a salary column, what SQL statement would give you the top five earning employees? But before you select the SQL statement you have to select the database implementation. Here is how you might do it in Oracle: SELECT name FROM [...]

Posted in SQL, TechKnow | Leave a comment

Scale Resize Images

I recently had to look into the image scaling code that we employ in our application because of a known bug with the JDK. Here is the original code we used to resize image icons: int hint = Image.SCALE_AREA_AVERAGING; icon = new ImageIcon(original.getScaledInstance(w,h, hint)); As stated, the above code occasionally will throw a ClassCastException because [...]

Posted in Java, Programming, TechKnow | Leave a comment

Poor Man’s Profiling

Some time back I wrote about how OptimizeIt was useful in profiling our application. If you can’t afford OptimizeIt Java provides you an alternative poor man’s profiling tool in the Runtime class. The Runtime class allows you get the total heap size and the amount of available memory. Using these methods you can estimate how [...]

Posted in Java, Programming, TechKnow | Leave a comment