I wrote the following code:
public class UserAccountWebServices {
@Context protected HttpHeaders httpHeaders; @HeaderParam("Authorization") private String authorization; @FormParam("UserAccountIdentifier") private String userAccountIdentifier;…
The thing is that my class variables (authorization and userAccountIdentifier) are marked “private” and IntelliJ IDEA flags a warning – saying that they were never assigned. I still have a long way to go before compiling and running it, so I would appreciate if someone could tell me if it would work – injected into a private variable?
Thanks!
Yes, that works (assuming you are using Jersey).