spring webservice 可以自动生成WSDL文件,
<bean id="
Hr"
class="org.springframework.ws.wsdl.wsdl11.DynamicWsdl11Definition">
<description>
This bean definition represents a WSDL definition that is
generated at runtime, based on the builder defined below. It
can be retrieved by going to /
Hr/
Hr.wsdl (i.e. the bean
name corresponds to the filename).
</description>
<property name="builder">
<description>
The builder creates a WSDL from the 'echo.xsd' schema.
It detects all elements that ends with 'Request', finds
corresponding 'Response' messages, and creates an
operation based on that. All operations are put in a
portType with name 'Echo', and binding and service are
created.
</description>
<bean
class="org.springframework.ws.wsdl.wsdl11.builder.XsdBasedSoap11Wsdl4jDefinitionBuilder">
<property name="schema" value="/WEB-INF/person.xsd" />
<property name="portTypeName" value="
Info" />
<property name="locationUri"
value="http://localhost:8080/
Hr/webservices" />
</bean>
</property>
</bean>
蓝色表示eclipse中创建的根目录也就是web的根目录,只能为web的根目录
红色表示在根目录下的子目录中可以访问到生成的WSDL文件的路径,可以随便取
绿色表示portType名字,可以随便取