Java Reference
In-Depth Information
The class javax.xml.ws.soap.MTOMFeature extends WebServiceFeature . The generated
client interfaces make it easy to invoke your service operations using a built-in or custom
feature. To use MTOM on the client, simply retrieve the port using the factory that accepts
a variable-length argument of WebServiceFeature objects, passing in an instance of the
MTOMFeature . Here's how you can enable MTOM using the getCatalogPort method:
Catalog catalogPort = service.getCatalogPort(new MTOMFeature());
The implementation is handled for you by the runtime.
The MTOMFeature constructor also accepts an optional integer argument indicating the
threshold, or the number of bytes that the binary data should be before being sent as an attach-
ment. The default value for the threshold is 0.
See Also
Optimizing Transmission of Binary Content on the Server .
Search WWH ::




Custom Search