Java 类org.springframework.web.bind.support.SessionAttributeStore 实例源码

项目:lams    文件:SessionAttributesHandler.java   
/**
 * Create a new instance for a controller type. Session attribute names and
 * types are extracted from the {@code @SessionAttributes} annotation, if
 * present, on the given type.
 * @param handlerType the controller type
 * @param sessionAttributeStore used for session access
 */
public SessionAttributesHandler(Class<?> handlerType, SessionAttributeStore sessionAttributeStore) {
    Assert.notNull(sessionAttributeStore, "SessionAttributeStore may not be null.");
    this.sessionAttributeStore = sessionAttributeStore;

    SessionAttributes annotation = AnnotationUtils.findAnnotation(handlerType, SessionAttributes.class);
    if (annotation != null) {
        this.attributeNames.addAll(Arrays.asList(annotation.value()));
        this.attributeTypes.addAll(Arrays.<Class<?>>asList(annotation.types()));
    }

    for (String attributeName : this.attributeNames) {
        this.knownAttributeNames.add(attributeName);
    }
}
项目:lams    文件:HandlerMethodInvoker.java   
public HandlerMethodInvoker(HandlerMethodResolver methodResolver, WebBindingInitializer bindingInitializer,
        SessionAttributeStore sessionAttributeStore, ParameterNameDiscoverer parameterNameDiscoverer,
        WebArgumentResolver[] customArgumentResolvers, HttpMessageConverter<?>[] messageConverters) {

    this.methodResolver = methodResolver;
    this.bindingInitializer = bindingInitializer;
    this.sessionAttributeStore = sessionAttributeStore;
    this.parameterNameDiscoverer = parameterNameDiscoverer;
    this.customArgumentResolvers = customArgumentResolvers;
    this.messageConverters = messageConverters;
}
项目:spring4-understanding    文件:SessionAttributesHandler.java   
/**
 * Create a new instance for a controller type. Session attribute names and
 * types are extracted from the {@code @SessionAttributes} annotation, if
 * present, on the given type.
 * @param handlerType the controller type
 * @param sessionAttributeStore used for session access
 */
public SessionAttributesHandler(Class<?> handlerType, SessionAttributeStore sessionAttributeStore) {
    Assert.notNull(sessionAttributeStore, "SessionAttributeStore may not be null.");
    this.sessionAttributeStore = sessionAttributeStore;

    SessionAttributes annotation = AnnotationUtils.findAnnotation(handlerType, SessionAttributes.class);
    if (annotation != null) {
        this.attributeNames.addAll(Arrays.asList(annotation.names()));
        this.attributeTypes.addAll(Arrays.asList(annotation.types()));
    }

    for (String attributeName : this.attributeNames) {
        this.knownAttributeNames.add(attributeName);
    }
}
项目:spring4-understanding    文件:HandlerMethodInvoker.java   
public HandlerMethodInvoker(HandlerMethodResolver methodResolver, WebBindingInitializer bindingInitializer,
        SessionAttributeStore sessionAttributeStore, ParameterNameDiscoverer parameterNameDiscoverer,
        WebArgumentResolver[] customArgumentResolvers, HttpMessageConverter<?>[] messageConverters) {

    this.methodResolver = methodResolver;
    this.bindingInitializer = bindingInitializer;
    this.sessionAttributeStore = sessionAttributeStore;
    this.parameterNameDiscoverer = parameterNameDiscoverer;
    this.customArgumentResolvers = customArgumentResolvers;
    this.messageConverters = messageConverters;
}
项目:class-guard    文件:SessionAttributesHandler.java   
/**
 * Create a new instance for a controller type. Session attribute names and
 * types are extracted from the {@code @SessionAttributes} annotation, if
 * present, on the given type.
 * @param handlerType the controller type
 * @param sessionAttributeStore used for session access
 */
public SessionAttributesHandler(Class<?> handlerType, SessionAttributeStore sessionAttributeStore) {
    Assert.notNull(sessionAttributeStore, "SessionAttributeStore may not be null.");
    this.sessionAttributeStore = sessionAttributeStore;

    SessionAttributes annotation = AnnotationUtils.findAnnotation(handlerType, SessionAttributes.class);
    if (annotation != null) {
        this.attributeNames.addAll(Arrays.asList(annotation.value()));
        this.attributeTypes.addAll(Arrays.<Class<?>>asList(annotation.types()));
    }

    for (String attributeName : this.attributeNames) {
        this.knownAttributeNames.put(attributeName, Boolean.TRUE);
    }
}
项目:class-guard    文件:HandlerMethodInvoker.java   
public HandlerMethodInvoker(HandlerMethodResolver methodResolver, WebBindingInitializer bindingInitializer,
        SessionAttributeStore sessionAttributeStore, ParameterNameDiscoverer parameterNameDiscoverer,
        WebArgumentResolver[] customArgumentResolvers, HttpMessageConverter[] messageConverters) {

    this.methodResolver = methodResolver;
    this.bindingInitializer = bindingInitializer;
    this.sessionAttributeStore = sessionAttributeStore;
    this.parameterNameDiscoverer = parameterNameDiscoverer;
    this.customArgumentResolvers = customArgumentResolvers;
    this.messageConverters = messageConverters;
}
项目:oauth-client-master    文件:AuthorizationEndpoint.java   
public void setSessionAttributeStore(SessionAttributeStore sessionAttributeStore) {
    this.sessionAttributeStore = sessionAttributeStore;
}
项目:jresplus    文件:ExtendableAnnotationMethodHandlerAdapter.java   
/**
 * Specify the strategy to store session attributes with.
 * <p>
 * Default is
 * {@link org.springframework.web.bind.support.DefaultSessionAttributeStore}
 * , storing session attributes in the HttpSession, using the same attribute
 * name as in the model.
 */
public void setSessionAttributeStore(
        SessionAttributeStore sessionAttributeStore) {
    Assert.notNull(sessionAttributeStore,
            "SessionAttributeStore must not be null");
    this.sessionAttributeStore = sessionAttributeStore;
}
项目:spring4-understanding    文件:AnnotationMethodHandlerAdapter.java   
/**
 * Specify the strategy to store session attributes with.
 * <p>Default is {@link org.springframework.web.bind.support.DefaultSessionAttributeStore},
 * storing session attributes in the PortletSession, using the same
 * attribute name as in the model.
 */
public void setSessionAttributeStore(SessionAttributeStore sessionAttributeStore) {
    Assert.notNull(sessionAttributeStore, "SessionAttributeStore must not be null");
    this.sessionAttributeStore = sessionAttributeStore;
}
项目:spring4-understanding    文件:AnnotationMethodHandlerAdapter.java   
/**
 * Specify the strategy to store session attributes with.
 * <p>Default is {@link org.springframework.web.bind.support.DefaultSessionAttributeStore},
 * storing session attributes in the HttpSession, using the same attribute name as in the model.
 */
public void setSessionAttributeStore(SessionAttributeStore sessionAttributeStore) {
    Assert.notNull(sessionAttributeStore, "SessionAttributeStore must not be null");
    this.sessionAttributeStore = sessionAttributeStore;
}
项目:spring4-understanding    文件:RequestMappingHandlerAdapter.java   
/**
 * Specify the strategy to store session attributes with. The default is
 * {@link org.springframework.web.bind.support.DefaultSessionAttributeStore},
 * storing session attributes in the HttpSession with the same attribute
 * name as in the model.
 */
public void setSessionAttributeStore(SessionAttributeStore sessionAttributeStore) {
    this.sessionAttributeStore = sessionAttributeStore;
}
项目:class-guard    文件:AnnotationMethodHandlerAdapter.java   
/**
 * Specify the strategy to store session attributes with.
 * <p>Default is {@link org.springframework.web.bind.support.DefaultSessionAttributeStore},
 * storing session attributes in the PortletSession, using the same
 * attribute name as in the model.
 */
public void setSessionAttributeStore(SessionAttributeStore sessionAttributeStore) {
    Assert.notNull(sessionAttributeStore, "SessionAttributeStore must not be null");
    this.sessionAttributeStore = sessionAttributeStore;
}
项目:class-guard    文件:AnnotationMethodHandlerAdapter.java   
/**
 * Specify the strategy to store session attributes with.
 * <p>Default is {@link org.springframework.web.bind.support.DefaultSessionAttributeStore},
 * storing session attributes in the HttpSession, using the same attribute name as in the model.
 */
public void setSessionAttributeStore(SessionAttributeStore sessionAttributeStore) {
    Assert.notNull(sessionAttributeStore, "SessionAttributeStore must not be null");
    this.sessionAttributeStore = sessionAttributeStore;
}
项目:class-guard    文件:RequestMappingHandlerAdapter.java   
/**
 * Specify the strategy to store session attributes with. The default is
 * {@link org.springframework.web.bind.support.DefaultSessionAttributeStore},
 * storing session attributes in the HttpSession with the same attribute
 * name as in the model.
 */
public void setSessionAttributeStore(SessionAttributeStore sessionAttributeStore) {
    this.sessionAttributeStore = sessionAttributeStore;
}