标签: design-patterns static local final
我的代码如下,所讨论的变量仅使用一次。
class A{ private static final String patternStr = "abc"; public void m1(){ final String local patternStr = "abc"; ..... /* Code dealing with pattern matching*/ } }