?? form.java
字號:
// Copyright 2005-2007 onetsoft.com
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package com.onetsoft.fastjsp;
import com.onetsoft.fastjsp.valid.FieldValidator;
/**
* 表單配置類接口
* 注:現對于同一頁面,表單是由狀態的。
*
* @author <a href="mailto:hgw@onetsoft.com">hgw</a>
*/
public interface Form {
/**
* 取得本表單名稱
* 此名稱應與客戶表單隱藏域form傳入的名稱完全相同
* 注意區分大小寫
*
* @return
*/
String getName();
/**
* 取得本表單域驗證
* 警告:此驗證配置運行時將有狀態保存,不能靜態化此配置
* 注:
* 1.此驗證配置可通過方法{@link AbstractFormAction#isBypassFormFieldValidation()} 忽略
* 2.頁面以此生成js驗證。若要實現自定義驗證,建議實現{@link AbstractFormAction#validate()}方法或在action中為表單執行結果生成驗證
* 3.Action執行過程中的驗證順序:a:順序執行此驗證數組 b:執行{@link com.onetsoft.fastjsp.AbstractFormAction#validate()}自定義驗證
* 4.此數組可包含null元素
* @return
*/
FieldValidator[] getFieldValidators();
/**
* 是否開啟客戶端表單域Javascript驗證
*
* @return
*/
boolean isClientValidationEnabled();
/**
* 在頁碼呈現時是否"focus"表單域
*
* @return
*/
boolean isFocus();
/**
* 獲取當前頁面
*
* @return
* @since 3.0
*/
Page getPage();
/**
* 是否缺省action優先執行
* 若配置為true,則將首先嘗試執行缺省action ,若不存在則再嘗試執行指定action
* 注:每次表單請求僅Action執行一次
* @since 3.0
* @return default:false
* @see #getDefaultAction()
*/
boolean isDefaultActionPreferred();
/**
* 取得本表單缺省action
* @return
* @since 3.0
*/
String getDefaultAction();
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -