Java Quirks: When a Collection is a String (using JSP Tags)
Today I was trying to create an equivalent of displaytag. During the exercise I found out few things a didn’t know about the behavior of JSP tag files.
Soronthar's Software Development Diary
Collection of Random Thoughts and Essays on Software Development
Category
Today I was trying to create an equivalent of displaytag. During the exercise I found out few things a didn’t know about the behavior of JSP tag files.
I was working in the same application where I found the previous quirk. This time I tried to make a cell renderer put a background color in the cell, to no avail. I even tried to explicitly return a JLabel as the cell renderer, with…
I have been bitten. ListSelectionListener.valueChanged is called more than once when a selection in a List/Tree/Table is changed. After some googling, I found out that I’m not alone.
I was doing some regexp work on one of my projects, when suddenly this well-known and hundred-of-times implemented code right from the javadoc, failed: StringBuffer result = new StringBuffer(text.length()); while (includeMatcher.find()) { String includeFile = includeMatcher.group(1); String s = readTemplate(includeFile, area,topic,skins,false); includeMatcher.appendReplacement(result, s); } includeMatcher.appendTail(result); text = result.toString(); A java.lang.IllegalArgumentException was thrown. Thanks…