本帖最后由 worldlove2009 于 2010-01-08 15:55:21 编辑

解决方案 »

  1.   


    while(stack.size()>0){
            SOAPMessageWrapper wrap = stack.pop();
            System.out.println("outBound:"+wrap.getOutBoundMessageAsString());
            System.out.println("InBound:"+wrap.getInBoundMessageAsString());
            System.out.println("");
        }
    方法的实现必须有对应的方法名
    如果直接加在{}里面是静态块
      

  2.   

    while(stack.size()>0){
            SOAPMessageWrapper wrap = stack.pop();
            System.out.println("outBound:"+wrap.getOutBoundMessageAsString());
            System.out.println("InBound:"+wrap.getInBoundMessageAsString());
            System.out.println("");
        }
    这个只能放在方法里吗,我放在类中不行吗
      

  3.   

    是不是if.....else..... , while...  什么的没法直接放在类体中,只能放在方法中啊