code: public static boolean shouldBeUsed(String authMode) {
          return authMode != null &&
                 (authMode.equalsIgnoreCase(AUTHMODE_SERVICE_ALL) || authMode.equalsIgnoreCase(AUTHMODE_SERVICE_ANY));
      }
docs: Check whether for the given authmode an instance of this context should be used (i.e. when the
  auth-mode is "service-any" or "service-all"
  
  @param authMode authmode to check
  @return true if this context should be used for the agent, false otherwise