protected Map < Long , Map < String , String > > getRequestAnswerMap ( RequestContext requestContext ) { @ SuppressWarnings ( "unchecked" ) Map < Long , Map < String , String > > answers = ( Map < Long , Map < String , String > > ) requestContext . getRequest ( ) . getAttribute ( "commentAnswers" ) ; if ( answers == null ) { answers = new HashMap <> ( ) ; requestContext . getRequest ( ) . setAttribute ( "commentAnswers" , answers ) ; } return answers ; }
Returns comment answers map from the request context . If map is not yet defined new is created .