[logback-dev] [Bug 110] AccessEvent is missing getters for RequestParameters.

bugzilla-daemon at pixie.qos.ch bugzilla-daemon at pixie.qos.ch
Wed Oct 24 15:02:09 CEST 2007


http://bugzilla.qos.ch/show_bug.cgi?id=110





------- Comment #1 from joern at huxhorn.de  2007-10-24 15:02 -------
Workaround:

/**
 * Hack ;)
 * @param event
 * @return request parameter map
 */
public Map<String,Object> getRequestParameterMap(AccessEvent event)
{
    try
    {
        Field field=AccessEvent.class.getDeclaredField("requestParameterMap");
        field.setAccessible(true);
        Object rpm=field.get(event);
        if(rpm instanceof Map)
        {
            return (Map<String, Object>)rpm;
        }
    }
    catch (NoSuchFieldException e)
    {
        e.printStackTrace();
    }
    catch (IllegalAccessException e)
    {
        e.printStackTrace();
    }
    return null;
}


-- 
Configure bugmail: http://bugzilla.qos.ch/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the logback-dev mailing list