in my web application I have many places where I need to retrieve current logged account (from session).
Account account = getAccountFromSession(session);
This piece of code is repeated many many times. I wonder if this is possible to make my request look something like this:
@RequestMapping(value="/something", method=RequestMethod.POST)
public String handleSomething(
@RequestParam String someParam,
@Account Account account) { ... }
where @Account is my custom annotation.
How can I tell spring to process this annotation?