2006-12-30

深入理解Tapestry的Rewind

关键字: tapestry rewind
Tapestry的rewind一直是学习和使用Tapestry的难点,rewind是用来处理表单提交的,表单默认使用的是DirectService来提交。在详细介绍之前,先说明下此文中需要用到的一些概念,首先是表单组件,我这里指的是指继承自AbstractFormComponent类的组件,例如:TextField、TextArea、Checkbox等,而不是具体的Form组件,表单组件使用时必须在Form组件中,这些组件在rewind时调用继承自AbstractFormComponent的rewindFormComponent来读取数据,并将数据赋值给容器或者页面。 我们来看一下最简单的Te ...
2006-12-28

The way of checking the type of an object

关键字: javascript
Apress ProJavaScriptTechniques The first way of checking the type of an object is by using the obvious-sounding typeof operator. js 代码   // Check to see if our number is actually a string   if ( typeof& ...
2006-12-28

javascipt scope

关键字: javascript
From Apress ProJavaScriptTechniques In JavaScript, scope is kept within functions, but not within blocks (such as while, if, and for statements). js 代码   // Set a global variable, foo, equal to test   var foo =&nb ...
     Tapestry中构建选择列表需要使用IPropertySelectionModel,Model可以映射选择列表中的Label和Option,Tapestry中已经提供一个常用的StringSelectonModel,具体组件使用如下: Html代码   Java代码 java 代码   public abstract class DetailsPage extends BasePage {   &nb ...
tapestry
搜索本博客
最近加入圈子
存档
最新评论