public abstract class AbstractTemplateDirective extends BaseTemplateDirective
限定符和类型 | 字段和说明 |
---|---|
static java.lang.String |
ADVANCED |
private SysAppService |
appService |
private SysAppTokenService |
appTokenService |
static java.lang.String |
AUTH_TOKEN |
static java.lang.String |
AUTH_USER_ID |
protected SiteComponent |
siteComponent |
private SysUserService |
sysUserService |
private SysUserTokenService |
sysUserTokenService |
log
构造器和说明 |
---|
AbstractTemplateDirective() |
限定符和类型 | 方法和说明 |
---|---|
void |
execute(org.springframework.http.converter.HttpMessageConverter<java.lang.Object> httpMessageConverter,
org.springframework.http.MediaType mediaType,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response) |
protected void |
expose(RenderHandler handler,
java.util.Map<java.lang.String,java.lang.Object> model) |
protected boolean |
getAdvanced(RenderHandler handler) |
protected SysApp |
getApp(RenderHandler handler) |
protected SysSite |
getSite(RenderHandler handler) |
private SysUser |
getUser(RenderHandler handler) |
protected java.lang.Long |
getUserId(RenderHandler handler,
java.lang.String name) |
boolean |
needAppToken() |
boolean |
needUserToken() |
boolean |
supportAdvanced() |
execute, getName, getNamespace, getShortName, httpEnabled, setName, setNamespace, setShortName
public static final java.lang.String AUTH_TOKEN
public static final java.lang.String AUTH_USER_ID
public static final java.lang.String ADVANCED
private SysAppTokenService appTokenService
private SysAppService appService
private SysUserTokenService sysUserTokenService
private SysUserService sysUserService
protected SiteComponent siteComponent
protected SysSite getSite(RenderHandler handler) throws freemarker.template.TemplateModelException
handler
- freemarker.template.TemplateModelException
protected void expose(RenderHandler handler, java.util.Map<java.lang.String,java.lang.Object> model) throws freemarker.template.TemplateModelException
model
- handler
- freemarker.template.TemplateModelException
protected boolean getAdvanced(RenderHandler handler) throws freemarker.template.TemplateModelException
freemarker.template.TemplateModelException
protected java.lang.Long getUserId(RenderHandler handler, java.lang.String name) throws freemarker.template.TemplateModelException
freemarker.template.TemplateModelException
public void execute(org.springframework.http.converter.HttpMessageConverter<java.lang.Object> httpMessageConverter, org.springframework.http.MediaType mediaType, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws freemarker.template.TemplateException, java.io.IOException
java.io.IOException
freemarker.template.TemplateException
private SysUser getUser(RenderHandler handler) throws freemarker.template.TemplateModelException
handler
- freemarker.template.TemplateModelException
public boolean supportAdvanced()
public boolean needAppToken()
public boolean needUserToken()
protected SysApp getApp(RenderHandler handler) throws freemarker.template.TemplateModelException
handler
- freemarker.template.TemplateModelException