All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.febit.wit.servlet.resolvers.HttpSessionResolver Maven / Gradle / Ivy

There is a newer version: 2.7.0-beta
Show newest version
// Copyright (c) 2013-present, febit.org. All Rights Reserved.
package org.febit.wit.servlet.resolvers;

import javax.servlet.http.HttpSession;
import org.febit.wit.resolvers.GetResolver;
import org.febit.wit.resolvers.SetResolver;

/**
 *
 * @author zqq90
 */
public class HttpSessionResolver implements GetResolver, SetResolver {

    @Override
    public Object get(HttpSession bean, Object property) {
        return bean.getAttribute(property.toString());
    }

    @Override
    public void set(HttpSession bean, Object property, Object value) {
        bean.setAttribute(property.toString(), value);
    }

    @Override
    public Class getMatchClass() {
        return HttpSession.class;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy