1 Reply Latest reply on May 26, 2009 7:42 PM by norman

    Outjection and compiler warnings

    gonorrhea

      So this is a minor IDE-related issue in the context of outjected context variables.


      @Out(required=false, scope=ScopeType.SESSION)
      private String domainAndUsername;
      
      public boolean authenticate() {
                                                      
                      identity.setUsername("me");
                      identity.setPassword("jibberish"); 
                      
                      domainAndUsername = "foo\\bar";
                                      
                      return true;
              }



      So the compiler/IDE complains as such:


      The field BypassAuthenticator.domainAndUsername is never read locally



      What is the best practice solution to fix this warning?


      I am given 3 options to resolve by the IDE, one of which is to add @SuppressWarning("unused").  The other is remove the variable and the other is create getter/setter.  I don't need getter/setter for this context variable in my backing SFSB.  Remove is obviously out of the question.