----------java2wsdl-----------------
set Axis_Lib=E:\workspace\axis_dome\lib1.2_match
set Java_Cmd=java -Djava.ext.dirs=%Axis_Lib%
set Output_Path=E:\wangchaoboWorkSpace\LBUmdmc\mdmcWeb\wsdl\ConfAccountOperator.wsdl
set Package=com.huawei.mdmcservice.confaccount.server
set namespace=urn:ConfAccountOperator
set url=http://localhost:8080/webservice/ConfAccountOperator
%Java_Cmd% org.apache.axis.wsdl.Java2WSDL -o%Output_Path% -l%url% -n%namespace% -p%Package%=%namespace% -y rpc com.huawei.mdmcservice.confaccount.ConfAccountOperator
@echo wsdl文件已经成功生成,代码在src目录下
@echo -----------------------------------------
@pause
----------wsdl2javaclient-----------------
set Axis_Lib=E:\workspace\axis_dome\lib1.2_match
set Java_Cmd=java -Djava.ext.dirs=%Axis_Lib%
set Output_Path=E:\workspace\axis_dome\clientCode
set Package=com.huawei.portal.mmc.prem.webstub
%Java_Cmd% org.apache.axis.wsdl.WSDL2Java -o%Output_Path% -p%Package% E:\wangchaoboWorkSpace\LBUmdmc\mdmcWeb\wsdl\ConfAccountOperator.wsdl
----------wsdl2javaServer-----------------
@echo -----------------------------------------
@echo 设置Output_Path设置为你要生成的路径
@echo Package设置为生成文件的包路径
@echo 最后是wsdl可以是文件路径 可以是URL
@echo WSDL2Java -o [放在那个包下面] -d Session -s -S true [wsdl路径]
@echo -----------------------------------------
@echo 切换到当前目录
set CURRENT_DIR=%cd%
@echo %CURRENT_DIR%
cd %CURRENT_DIR%
set Axis_Lib=E:\workspace\axis_dome\lib1.2_match
set Java_Cmd=java -Djava.ext.dirs=%Axis_Lib%
set Output_Path=E:\workspace\axis_dome\server
set Package=com.huawei.mdmcservice.confaccount.server
%Java_Cmd% org.apache.axis.wsdl.WSDL2Java -o%Output_Path% -p%Package% -s -S true E:\wangchaoboWorkSpace\LBUmdmc\mdmcWeb\wsdl\ConfAccountOperator.wsdl
@echo 服务端代码已经成功生成,代码在src目录下
@echo -----------------------------------------
@pause
axis 1.4的下载地址:http://www.us.apache.org/dist/ws/axis/1_4/