2008年7月29日星期二

MySpace and Portlet

MySpace looks some like Portlet. Is it just like at face?
MySpace has a MySpace Developer Platform. What is it?

2008年7月8日星期二

different framework, different web page

the Struts treats a page as a Command;
the Portlet treats a page as a Window;
the JSF treats a page as a lot of Components;
the Spring Web Flow treats a lot of pages as a Flow;
the Tapestry treats a page as a Java class

2008年7月3日星期四

JSF Custom Compoment development tips

1. JSP taglib
In JSF, the scriplet like "#{RequestBean1.name}" is treated as a ValueExpression field in tab class. The corresponding tab lib definition file should nests the attribute type with deferred-value.

And also in tld file, jsp-version 2.1 element should be included. If this scriplet is missed, some container like Tomcat 6.0.16 will take this tag as generial tag and if we invoke isLiteralText() on the ValueExpression object, true will return. It was not excepted. But the GlassFish V2 ignored this and took 2.1 as default.

2. Why setProperties() in tag handler java is not invoked?
You should define all property of jsf component java in faces-config.xml. Sometimes it looks like that a attribute is defined twice: one in tld, one in faces-config.xml. JSF Template can make these things easy by generating all configuration file. In order to archive this, it introduces some anonations.

3. Why did some data shown on page disappear after re-loading the page?
implement the saveState/restoreState method.