Class HTTPServerPolicy

java.lang.Object
org.apache.cxf.transports.http.configuration.HTTPServerPolicy

public class HTTPServerPolicy extends Object
Properties used for configuring a server-side HTTP prort

Java class for HTTPServerPolicy complex type

.

The following schema fragment specifies the expected content contained within this class.


 <complexType name="HTTPServerPolicy">
   <complexContent>
     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
       <sequence>
       </sequence>
       <attribute name="ReceiveTimeout" type="{http://www.w3.org/2001/XMLSchema}unsignedInt" default="30000" />
       <attribute name="SuppressClientSendErrors" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
       <attribute name="SuppressClientReceiveErrors" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
       <attribute name="HonorKeepAlive" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
       <attribute name="KeepAliveParameters" type="{http://www.w3.org/2001/XMLSchema}string" />
       <attribute name="RedirectURL" type="{http://www.w3.org/2001/XMLSchema}string" />
       <attribute name="CacheControl" type="{http://www.w3.org/2001/XMLSchema}string" />
       <attribute name="ContentLocation" type="{http://www.w3.org/2001/XMLSchema}string" />
       <attribute name="ContentType" type="{http://www.w3.org/2001/XMLSchema}string" />
       <attribute name="ContentEncoding" type="{http://www.w3.org/2001/XMLSchema}string" />
       <attribute name="ServerType" type="{http://www.w3.org/2001/XMLSchema}string" />
       <anyAttribute namespace='http://schemas.xmlsoap.org/wsdl/'/>
     </restriction>
   </complexContent>
 </complexType>
 
  • Field Details

    • receiveTimeout

      protected Long receiveTimeout
      Receive timeout in milliseconds, 0 is infinite
    • suppressClientSendErrors

      protected Boolean suppressClientSendErrors
      When set to false, exceptions will be thrown when an error is encountered receiving a request from the client. When set to true these errors will be suppressed. The default is false.
    • suppressClientReceiveErrors

      protected Boolean suppressClientReceiveErrors
      When set to false, exceptions will be thrown when an error is encountered sending a reply from to client. When set to true these errors will be suppressed. The default is false.
    • honorKeepAlive

      protected Boolean honorKeepAlive
      When set to true, the request socket will remain open after the reply is sent to the client, if the client has requested keep-alive and is using at least version 1.1 of HTTP. If set to false, the socket will be closed after each reply is sent, even if the client requests the server to keep the connection alive. Keep-Alive improves performance for the client requesting such behavior, but can limit overall scalability of the server for handling many clients. The Default is true.
    • keepAliveParameters

      protected String keepAliveParameters
      If KeepAlive connections are turned on, this allows sending additional parameters back to the client via the Keep-Alive header. Common parameters are timeout and max to specify how long the client should hold open the connection and how many connections to hold open. Different clients may have different defaults. For Java HTTPUrlConnection, the defaults would be timeout=5, max=5 Example: timeout=60, max=5;
    • redirectURL

      protected String redirectURL
      A URL to which clients are redirected (if the ReplyCode and ReplyDescription are not set, ReplyCode will be set to 302, and ReplyDescription will be set to 'Object Moved').
    • cacheControl

      protected String cacheControl
      Most commonly used to specify no-cache, however the standard supports a dozen or so caching related directives for responses.
    • contentLocation

      protected String contentLocation
      Specifies the URL representing the resource used to satisfy the request(e.g., to inform that default.htm document was used.)
    • contentType

      protected String contentType
      Specifies the MIME type used for responses. The default is set by the binding.
    • contentEncoding

      protected String contentEncoding
      Specifies any additional encoding applied to the response. Values are specified using IANA labels.
    • serverType

      protected String serverType
      Specifies an optional value for the HTTP ServerType property.
    • propertyListener

      protected PropertyChangeSupport propertyListener
  • Constructor Details

    • HTTPServerPolicy

      public HTTPServerPolicy()
  • Method Details

    • getKeepAliveParameters

      public String getKeepAliveParameters()
      If KeepAlive connections are turned on, this allows sending additional parameters back to the client via the Keep-Alive header. Common parameters are timeout and max to specify how long the client should hold open the connection and how many connections to hold open. Different clients may have different defaults. For Java HTTPUrlConnection, the defaults would be timeout=5, max=5 Example: timeout=60, max=5;
      Returns:
      possible object is String
    • setKeepAliveParameters

      public void setKeepAliveParameters(String value)
      Sets the value of the keepAliveParameters property.
      Parameters:
      value - allowed object is String
      See Also:
    • isSetKeepAliveParameters

      public boolean isSetKeepAliveParameters()
    • getRedirectURL

      public String getRedirectURL()
      A URL to which clients are redirected (if the ReplyCode and ReplyDescription are not set, ReplyCode will be set to 302, and ReplyDescription will be set to 'Object Moved').
      Returns:
      possible object is String
    • setRedirectURL

      public void setRedirectURL(String value)
      Sets the value of the redirectURL property.
      Parameters:
      value - allowed object is String
      See Also:
    • isSetRedirectURL

      public boolean isSetRedirectURL()
    • getCacheControl

      public String getCacheControl()
      Most commonly used to specify no-cache, however the standard supports a dozen or so caching related directives for responses.
      Returns:
      possible object is String
    • setCacheControl

      public void setCacheControl(String value)
      Sets the value of the cacheControl property.
      Parameters:
      value - allowed object is String
      See Also:
    • isSetCacheControl

      public boolean isSetCacheControl()
    • getContentLocation

      public String getContentLocation()
      Specifies the URL representing the resource used to satisfy the request(e.g., to inform that default.htm document was used.)
      Returns:
      possible object is String
    • setContentLocation

      public void setContentLocation(String value)
      Sets the value of the contentLocation property.
      Parameters:
      value - allowed object is String
      See Also:
    • isSetContentLocation

      public boolean isSetContentLocation()
    • getContentType

      public String getContentType()
      Specifies the MIME type used for responses. The default is set by the binding.
      Returns:
      possible object is String
    • setContentType

      public void setContentType(String value)
      Sets the value of the contentType property.
      Parameters:
      value - allowed object is String
      See Also:
    • isSetContentType

      public boolean isSetContentType()
    • getContentEncoding

      public String getContentEncoding()
      Specifies any additional encoding applied to the response. Values are specified using IANA labels.
      Returns:
      possible object is String
    • setContentEncoding

      public void setContentEncoding(String value)
      Sets the value of the contentEncoding property.
      Parameters:
      value - allowed object is String
      See Also:
    • isSetContentEncoding

      public boolean isSetContentEncoding()
    • getServerType

      public String getServerType()
      Specifies an optional value for the HTTP ServerType property.
      Returns:
      possible object is String
    • setServerType

      public void setServerType(String value)
      Sets the value of the serverType property.
      Parameters:
      value - allowed object is String
      See Also:
    • isSetServerType

      public boolean isSetServerType()
    • getOtherAttributes

      public Map<QName,String> getOtherAttributes()
      Gets a map that contains attributes that aren't bound to any typed property on this class.

      the map is keyed by the name of the attribute and the value is the string value of the attribute. the map returned by this method is live, and you can add new attribute by updating the map directly. Because of this design, there's no setter.

      Returns:
      always non-null
    • setReceiveTimeout

      public void setReceiveTimeout(long value)
      Sets the value of the receiveTimeout property.
    • unsetReceiveTimeout

      public void unsetReceiveTimeout()
    • isSetReceiveTimeout

      public boolean isSetReceiveTimeout()
    • getReceiveTimeout

      public long getReceiveTimeout()
      Receive timeout in milliseconds, 0 is infinite
    • setSuppressClientSendErrors

      public void setSuppressClientSendErrors(boolean value)
      Sets the value of the suppressClientSendErrors property.
    • unsetSuppressClientSendErrors

      public void unsetSuppressClientSendErrors()
    • isSetSuppressClientSendErrors

      public boolean isSetSuppressClientSendErrors()
    • isSuppressClientSendErrors

      public boolean isSuppressClientSendErrors()
      When set to false, exceptions will be thrown when an error is encountered receiving a request from the client. When set to true these errors will be suppressed. The default is false.
    • setSuppressClientReceiveErrors

      public void setSuppressClientReceiveErrors(boolean value)
      Sets the value of the suppressClientReceiveErrors property.
    • unsetSuppressClientReceiveErrors

      public void unsetSuppressClientReceiveErrors()
    • isSetSuppressClientReceiveErrors

      public boolean isSetSuppressClientReceiveErrors()
    • isSuppressClientReceiveErrors

      public boolean isSuppressClientReceiveErrors()
      When set to false, exceptions will be thrown when an error is encountered sending a reply from to client. When set to true these errors will be suppressed. The default is false.
    • setHonorKeepAlive

      public void setHonorKeepAlive(boolean value)
      Sets the value of the honorKeepAlive property.
    • unsetHonorKeepAlive

      public void unsetHonorKeepAlive()
    • isSetHonorKeepAlive

      public boolean isSetHonorKeepAlive()
    • isHonorKeepAlive

      public boolean isHonorKeepAlive()
      When set to true, the request socket will remain open after the reply is sent to the client, if the client has requested keep-alive and is using at least version 1.1 of HTTP. If set to false, the socket will be closed after each reply is sent, even if the client requests the server to keep the connection alive. Keep-Alive improves performance for the client requesting such behavior, but can limit overall scalability of the server for handling many clients. The Default is true.
    • addPropertyChangeListener

      public void addPropertyChangeListener(PropertyChangeListener listener)
    • removePropertyChangeListener

      public void removePropertyChangeListener(PropertyChangeListener listener)