论坛首页 Java版

tapestry-core:Introduction

浏览 376 次
精华帖 (0) :: 良好帖 (0) :: 新手帖 (0) :: 隐藏帖 (0)
作者 正文
最后更新时间:2007-05-09 关键字: Tapestry5
 

本文翻译出处 http://tapestry.apache.org/tapestry5/tapestry-core/index.html
本人翻译目的是用来学习Tapestry5的,共享出来希望大家批评指正。计划持续翻译。

chinajavawolf

Tapestry Core

Tapestry 核心

The tapestry-core module provides the interfaces and annotations that form the Tapestry API.

tapestry-core是提供接口和标注的 Tapestry API模块。

tapestry-core is built upon the Tapestry IoC Container.

tapestry-core 构建于 Tapestry IoC 容器之上。

New And Of Note

新的和需要注意的

Progress on Tapestry 5 is really taking off. This space lists some cool new features that have been added recently.

在 Tapestry 5 之上的进展正在开启。这里列出最近已经被增加的一些重要的新功能。

l        Explicit <!DOCTYPE> declarations inside page and component templates will now be forwarded through to the client web browser.

直接<!DOCTYPE> 声明在页面和组件模板内现在将会被转到客户端浏览器。

l        The mapping from class names to page names (or component types) has been tweaked to remove some redunancy;

从类名到页面名(或者组建类型)的映射也已经被简化去除那些冗余的。

l        For example, class org.example.myapp.pages.edit.EditUser will now have the name "edit/User" rather than "edit/EditUser". This results in shorter, clearer, more natural URLs.

举例来说, 类 org.example.myapp.pages.edit.EditUser 现在将会有 "edit/User" 优于 " edit/EditUser" 的名字。这样就带来了短小、简洁,自然的URLs.

l        The type of component may now be specified in a template using the element name, rather than the t:type attribute (this represents an incompatible change from 5.0.2).

组件的类型现在可能会在模板中使用元素名进行详细说明, 这样优于 t:type 属性.(这是一个与5.0.2版本不相容的变化)

l        Form validation now runs on the client side (as well as on the server side) with some basic effects, built on script.taculo.us.

现在运行于客户端(也可运行在服务器端)的一些基本的表单验证构建在 script.taculo.us上。

l        The default ExceptionReport page has been improved to show details of the incoming request, to filter out repetative and unnecessary data, and to display file content when an exception includes a location.

默认的异常报告页已经被改良来显示详细的请求信息,过滤掉那些冗余的数据,还要现实出特定异常的文件内容。

 

 

l        Action request URLs have been shortened and simplified for the common case. They may also include a query parameter to identify the page's activation context.

动态请求URLs已经被简化成统一的形式。他们也可能包括一个查询叁数用以识别页面的动态的上下文关系。

l        Component Reference Documentation, generated via a Maven plugin, is now available.

现在可以通过Maven获得可用的组件参考文件。

l        The return values for the "after" set of render phase methods have changed: all render phase methods return true (or void) to progress down the default path, and return false to either skip stages or return to earlier stages. This may break some existing code.

一组返回值的after呈现阶段方法已经改变: 所有的呈现阶段方法返回true (或者void) 给默认的路径, 而且返回false给跳跃或者叫早的阶段。这样可能打破些现有的代码。

l        Component event handlers may now return a StreamResponse to directly send a stream to the client web browser (this is intended for components that need to render images, PDF, or other non-page oriented content).

组件事件操作器现在可能返回 StreamResponse 直接地将流送到客户端浏览器。 (这是给那些需要呈现图片、PDF或者其他没有页面导向内容的组件提供的。)

l        The root URL for an application now renders the application's start page (it used to let the servlet container render the static welcome page, if any).

URL根路径现在为一个应用程序呈现应用程序的开始页。 (过去使用servlet容器呈现静态的欢迎页)

l        Named-based lookups of messages, resources, etc., are all case-insensitive.

信息、资源等所有同类方案以命名为基础查询.

l        Fast, smart, fully customizable Grid component for displaying tabular data.

方便快捷漂亮灵活可定制的Grid组件用以显示列表数据

l        Validating form components will use the same system as BeanEditForm to determine default validation for fields.

表单验证组件将会使用与 BeanEditForm 相同的系统为字段确认默认的验证。

l        Select component will automatically provide a ValueEncoder and SelectModel when the value parameter is bound to an Enum type.

当参数值被一个Enum类型绑定的时候,选择组件将会自动地提供一个ValueEncoder值编码器和 SelectModel选择模式 。

 

 

l        BeanEditForm component that creates a form and related controls to edit the properties of any JavaBean, automatically. Inspired by Trails and BeanForm (both for Tapestry 4).

BeanEditForm组件能够自动产生出一个form并借可以关联控制以编辑任何JavaBean的属性。通过 Trails 和 BeanForm 获得的灵感。 (两者为 Tapestry 4的)

l        Case insensitive URLs. Tapestry no longer cares about the case of the page names and component ids it puts into URLs, and they are now generated in all lower-case for that clean "Web 2.0" look. And they're shorter and "prettier", too!

不区分大小写的URLs方案。Tapestry不再担心把页面名和组件标识放入URLs的方案。现在他们用小些方案产生简洁的Web 2.0外观方案。而且他们也更短和更漂亮的!

l        Initial support for application state objects.

初始支持application状态对象。

l        Input validation messages may now be overriden by providing a particular message key in the containing component's message catalog.

输入验证信息现在可能由提供一个包含组件的信息目录的详细信息key值所替代。

l        Property expressions may now reference public methods (with no parameters) in addition to traditional property names.

属性表达式现在应该参考没有参数的公共方法除了传统的属性名外。

l        Page templates are now allowed to be stored in the WEB-INF , as well as on the classpath.

页面模板现在被允许被储存在 Web INF 中 , 也可在 classpath 上。

l        Invisible instrumentation, hiding Tapestry components inside ordinary HTML elements (a favorite feature of Tapestry 4), has been added to Tapestry 5.

隐性标识, 藏于 Tapestry 组件在普通的 HTML 元素 (一个 Tapestry 4 的喜爱功能) 内, 已经被增加进Tapestry 5

l        Component parameter defaults may be computed on the fly.

组件叁数默认值应该在运算时被计算。

l        Component parameters may have default values.

组件叁数可能有默认值。

The @ComponentClass anntotation, seen in the earlier screencasts has been removed.

@ComponentClass 标注, 在较早的录像中已经被移除。

   
论坛首页 Java版

跳转论坛:
JavaEye推荐