LuYu

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理
  
String... excludeProperty表示不定参数,也就是调用这个方法的时候这里可以传入多个String对象。
 public static void main(String[] args) {
            //测试,传入多个参数
            test("hello", "world", "13sd", "china", "cum", "ict");
        }

        public static void test(String... arguments) {
            for (int i = 0; i < arguments.length; i++) {
                System.out.println(arguments[i]);
            }
        }
posted on 2008-10-31 11:09  luyu  阅读(135)  评论(0)    收藏  举报