⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 page.java

📁 欢迎使用 FastJsp 开发框架! 编译说明: * 若要生成Api Javadoc文档
💻 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 java.util.Locale;


/**
 * 可用于保存:
 * 1.由url或form传递过来页面参数/对象
 * 2.客户端用户状态
 * 3.当前页面数据操作方法
 * 特别场合也可用于缓存页面数据
 * 注:所有页面对象应继承自 AbstractPage
 *
 * @author <a href="mailto:hgw@onetsoft.com">hgw</a>
 */
public interface Page extends Component {

    /**
     * 取得文件名称
     *
     * @return page name without extension  e.g:"index"
     */
    String getName();

    /**
     * 页面 request URL
     * 注:不能直接在jsp页面调用"request.getRequestURL()",因为WAS会返回实际模板路径构建的URL.
     * @return
     */
    String getRequestURL();

    /**
     * 取得页面标题
     *
     * @return
     */
    String getTitle();


    /**
     * 取得客户端locale
     *
     * @return
     */
    Locale getLocale();

    /**
     * 设置客户端Locale
     * 此设置将同时保存到本地 cookie 中
     *
     * @param locale
     */
    void setLocale(Locale locale);

    /**
     * 取得模板根目录
     * 一般用于取得客户端共享资源,如:JS、Style等
     *
     * @return e.g;"/onet/onetforums"
     */
    String getTemplateContextBase();

    /**
     * 取得当前页面的模板绝对路径
     * 此路径一般用于URL访问模板静态资源,如图片、CSS文件等。
     * 需要时,可将此路径作为页面的base标签。
     *
     * @return e.g;"http://locahost/onet/onetforums/skins/bbs/default/"
     */
    String getTemplateContextPath();

    /**
     * 取得当前页面模块
     * @return
     */
    PageModule getPageModule();


}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -