首先請看如下的代碼
view plainprint?
class Help { private int n
class Helper { static public void setValue(Help h
public class TestQuestion{ public static void main(String[] args) { Help h = new Help()
Help的setMe方法調用了Helper的setValue方法
class Help { private int n
class Helper { static public void setValue(Help h
public class TestQuestion{ public static void main(String[] args) { Help h = new Help()
這樣可以把檢測分離出來
From:http://tw.wingwit.com/Article/program/Java/hx/201311/27129.html