类 AbstractKiteReturnValueHandler<T>

  • 所有已实现的接口:
    org.springframework.web.method.support.HandlerMethodReturnValueHandler
    直接已知子类:
    AnnotationKiteReturnValueHandler

    public abstract class AbstractKiteReturnValueHandler<T>
    extends Object
    implements org.springframework.web.method.support.HandlerMethodReturnValueHandler
    抽象的springmvc ReturnValueHandler
    作者:
    qiuzhenhao
    • 字段详细资料

    • 构造器详细资料

      • AbstractKiteReturnValueHandler

        public AbstractKiteReturnValueHandler​(KiteFactory kiteFactory)
    • 方法详细资料

      • createOutputMessage

        protected org.springframework.http.server.ServletServerHttpResponse createOutputMessage​(org.springframework.web.context.request.NativeWebRequest webRequest)
      • getJsonEncoding

        protected com.fasterxml.jackson.core.JsonEncoding getJsonEncoding​(org.springframework.http.MediaType contentType)
      • supportsReturnType

        public boolean supportsReturnType​(org.springframework.core.MethodParameter returnType)
        指定者:
        supportsReturnType 在接口中 org.springframework.web.method.support.HandlerMethodReturnValueHandler
      • handleReturnValue

        public void handleReturnValue​(Object returnValue,
                                      org.springframework.core.MethodParameter methodParameter,
                                      org.springframework.web.method.support.ModelAndViewContainer mavContainer,
                                      org.springframework.web.context.request.NativeWebRequest webRequest)
                               throws Exception
        指定者:
        handleReturnValue 在接口中 org.springframework.web.method.support.HandlerMethodReturnValueHandler
        抛出:
        Exception
      • returnType

        protected abstract Class<T> returnType()
        取得返回类型
        返回:
      • namespace

        protected abstract String namespace​(T returnValue,
                                            org.springframework.core.MethodParameter methodParameter)
        取得 kite template 命名空间
        参数:
        returnValue -
        methodParameter -
        返回:
      • templateId

        protected abstract String templateId​(T returnValue,
                                             org.springframework.core.MethodParameter methodParameter)
        取得 kite template id
        参数:
        returnValue -
        methodParameter -
        返回:
      • templateType

        protected abstract TemplateType templateType​(T returnValue,
                                                     org.springframework.core.MethodParameter methodParameter)
        取得 template type
        参数:
        returnValue -
        methodParameter -
        返回:
      • dataModel

        protected abstract DataModel dataModel​(T returnValue,
                                               org.springframework.core.MethodParameter methodParameter)
        取得 dataModel
        参数:
        returnValue -
        methodParameter -
        返回: