首页>代码>java开源cms管理系统框架-PublicCMS后台管理系统>/PublicCMS-master/publiccms-by-gradle/src/com/publiccms/common/base/AbstractAppDirective.java
package com.publiccms.common.base;

import java.io.IOException;

import javax.servlet.http.HttpServletRequest;

import org.springframework.beans.factory.annotation.Autowired;

import com.publiccms.common.base.app.App;
import com.publiccms.entities.sys.SysSite;
import com.publiccms.logic.component.SiteComponent;
import com.sanluan.common.directive.BaseHttpDirective;
import com.sanluan.common.handler.RenderHandler;

/**
 * 
 * BaseDirective 自定义接口指令基类
 *
 */
public abstract class AbstractAppDirective extends BaseHttpDirective implements App {

    public SysSite getSite(RenderHandler handler) throws IOException, Exception {
        HttpServletRequest request = handler.getRequest();
        return siteComponent.getSite(request.getServerName(), request.getServerPort());
    }

    public abstract boolean needUserToken();

    public abstract boolean needAppToken();

    @Autowired
    private SiteComponent siteComponent;
}
最近下载更多
wanglinddad  LV54 2022年3月11日
tiansitong  LV14 2022年3月8日
heliosd  LV2 2022年2月15日
heqian  LV16 2021年8月11日
马123456  LV8 2021年7月13日
judy0971  LV12 2021年5月5日
zjjhzjb  LV14 2021年3月15日
ExamplesDYC  LV13 2020年11月21日
guoruchao  LV13 2020年9月28日
wzzhou  LV6 2020年9月14日
最近浏览更多
小王wang  LV10 2月29日
WBelong  LV7 2023年12月25日
locklock  LV2 2023年12月22日
chenxina 2023年12月6日
暂无贡献等级
丝绸之路  LV1 2023年12月6日
草帽小小鸡  LV7 2023年11月27日
ninanlin  LV2 2023年10月31日
18953153697 2023年10月29日
暂无贡献等级
liuxiao2  LV16 2023年10月25日
顶部 客服 微信二维码 底部
>扫描二维码关注最代码为好友扫描二维码关注最代码为好友