src/share/jaxws_classes/javax/xml/ws/soap/MTOMFeature.java

changeset 368
0989ad8c0860
parent 286
f50545b5e2f1
child 637
9c07ef4934dd
equal deleted inserted replaced
366:8c0b6bccfe47 368:0989ad8c0860
1 /* 1 /*
2 * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. Oracle designates this 7 * published by the Free Software Foundation. Oracle designates this
25 25
26 package javax.xml.ws.soap; 26 package javax.xml.ws.soap;
27 27
28 import javax.xml.ws.WebServiceFeature; 28 import javax.xml.ws.WebServiceFeature;
29 import javax.xml.ws.WebServiceException; 29 import javax.xml.ws.WebServiceException;
30 import javax.xml.ws.Dispatch;
31 import javax.xml.ws.Endpoint; 30 import javax.xml.ws.Endpoint;
32 import javax.xml.ws.Service; 31 import javax.xml.ws.Service;
33 32
34 /** 33 /**
35 * This feature represents the use of MTOM with a 34 * This feature represents the use of MTOM with a
36 * web service. 35 * web service.
37 * 36 *
38 * This feature can be used during the creation of SEI proxy, and 37 * This feature can be used during the creation of SEI proxy, and
39 * {@link Dispatch} instances on the client side and {@link Endpoint} 38 * {@link javax.xml.ws.Dispatch} instances on the client side and {@link Endpoint}
40 * instances on the server side. This feature cannot be used for {@link Service} 39 * instances on the server side. This feature cannot be used for {@link Service}
41 * instance creation on the client side. 40 * instance creation on the client side.
42 * 41 *
43 * <p> 42 * <p>
44 * The following describes the affects of this feature with respect 43 * The following describes the affects of this feature with respect
68 * Property for MTOM threshold value. This property serves as a hint when 67 * Property for MTOM threshold value. This property serves as a hint when
69 * MTOM is enabled, binary data above this size in bytes SHOULD be sent 68 * MTOM is enabled, binary data above this size in bytes SHOULD be sent
70 * as attachment. 69 * as attachment.
71 * The value of this property MUST always be >= 0. Default value is 0. 70 * The value of this property MUST always be >= 0. Default value is 0.
72 */ 71 */
73 protected int threshold = 0; 72 // should be changed to private final, keeping original modifier to keep backwards compatibility
73 protected int threshold;
74 74
75 75
76 /** 76 /**
77 * Create an <code>MTOMFeature</code>. 77 * Create an <code>MTOMFeature</code>.
78 * The instance created will be enabled. 78 * The instance created will be enabled.
79 */ 79 */
80 public MTOMFeature() { 80 public MTOMFeature() {
81 this.enabled = true; 81 this.enabled = true;
82 this.threshold = 0;
82 } 83 }
83 84
84 /** 85 /**
85 * Creates an <code>MTOMFeature</code>. 86 * Creates an <code>MTOMFeature</code>.
86 * 87 *
87 * @param enabled specifies if this feature should be enabled or not 88 * @param enabled specifies if this feature should be enabled or not
88 */ 89 */
89 public MTOMFeature(boolean enabled) { 90 public MTOMFeature(boolean enabled) {
90 this.enabled = enabled; 91 this.enabled = enabled;
92 this.threshold = 0;
91 } 93 }
92 94
93 95
94 /** 96 /**
95 * Creates an <code>MTOMFeature</code>. 97 * Creates an <code>MTOMFeature</code>.

mercurial