If, as you say, only one method needs the variable, and as long as the value does not need to persist between successive calls to that method, then yes definitely put it inside the method. That's better design, plus then you needn't worry about possible threading issues as well, as each
thread invoking the method will get their own copy.