com.aspose.html.net

Class RequestMessage

  • java.lang.Object
    • com.aspose.html.net.RequestMessage
  • All Implemented Interfaces:
    com.aspose.ms.System.IDisposable


    public class RequestMessage
    extends java.lang.Object
    implements com.aspose.ms.System.IDisposable

    Represents a request message.

    See Also:
    IDisposable
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void dispose()
      Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
      protected void dispose(boolean disposing)
      Releases unmanaged and - optionally - managed resources.
      Content getContent()
      Gets or sets the request content.
      com.aspose.ms.System.Net.CookieContainer getCookieContainer()
      Gets or sets the cookie container used to store server cookies by the handler.
      com.aspose.ms.System.Net.ICredentials getCredentials()
      Gets or sets authentication information for the request.
      RequestHeaders getHeaders()
      Gets the RequestHeaders.
      HttpMethod getMethod()
      Gets or sets the HttpMethod.
      boolean getPreAuthenticate()
      Gets or sets a value that indicates whether to send an Authorization header with the request.
      Url getRequestUri()
      Gets or sets the request URI.
      com.aspose.ms.System.TimeSpan getTimeout()
      The number of milliseconds to wait before the request times out.
      void setContent(Content value)
      Gets or sets the request content.
      void setCookieContainer(com.aspose.ms.System.Net.CookieContainer value)
      Gets or sets the cookie container used to store server cookies by the handler.
      void setCredentials(com.aspose.ms.System.Net.ICredentials value)
      Gets or sets authentication information for the request.
      void setMethod(HttpMethod value)
      Gets or sets the HttpMethod.
      void setPreAuthenticate(boolean value)
      Gets or sets a value that indicates whether to send an Authorization header with the request.
      void setRequestUri(Url value)
      Gets or sets the request URI.
      void setTimeout(com.aspose.ms.System.TimeSpan value)
      The number of milliseconds to wait before the request times out.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • RequestMessage

        public RequestMessage(java.lang.String address)

        Initializes a new instance of the RequestMessage class.

        Parameters:
        address - The request address.
      • RequestMessage

        public RequestMessage(Url uri)

        Initializes a new instance of the RequestMessage class.

        Parameters:
        uri - The request URL.
    • Method Detail

      • getRequestUri

        public Url getRequestUri()

        Gets or sets the request URI.

        Value: The request URI.
      • setRequestUri

        public void setRequestUri(Url value)

        Gets or sets the request URI.

        Value: The request URI.
      • getContent

        public Content getContent()

        Gets or sets the request content.

        Value: The body.
      • setContent

        public void setContent(Content value)

        Gets or sets the request content.

        Value: The body.
      • getTimeout

        public com.aspose.ms.System.TimeSpan getTimeout()

        The number of milliseconds to wait before the request times out. The default value is 100,000 milliseconds (100 seconds).

      • setTimeout

        public void setTimeout(com.aspose.ms.System.TimeSpan value)

        The number of milliseconds to wait before the request times out. The default value is 100,000 milliseconds (100 seconds).

      • getCredentials

        public com.aspose.ms.System.Net.ICredentials getCredentials()

        Gets or sets authentication information for the request.

        Value: An System.Net.ICredentials that contains the authentication credentials associated with the request. The default is null.
      • setCredentials

        public void setCredentials(com.aspose.ms.System.Net.ICredentials value)

        Gets or sets authentication information for the request.

        Value: An System.Net.ICredentials that contains the authentication credentials associated with the request. The default is null.
      • getCookieContainer

        public com.aspose.ms.System.Net.CookieContainer getCookieContainer()

        Gets or sets the cookie container used to store server cookies by the handler.

        Value: A System.Net.CookieContainer that contains the cookies associated with this request.
      • setCookieContainer

        public void setCookieContainer(com.aspose.ms.System.Net.CookieContainer value)

        Gets or sets the cookie container used to store server cookies by the handler.

        Value: A System.Net.CookieContainer that contains the cookies associated with this request.
      • getPreAuthenticate

        public boolean getPreAuthenticate()

        Gets or sets a value that indicates whether to send an Authorization header with the request.

        Value: true to send an HTTP Authorization header with requests after authentication has taken place; otherwise, false. The default is false.
      • setPreAuthenticate

        public void setPreAuthenticate(boolean value)

        Gets or sets a value that indicates whether to send an Authorization header with the request.

        Value: true to send an HTTP Authorization header with requests after authentication has taken place; otherwise, false. The default is false.
      • dispose

        protected void dispose(boolean disposing)

        Releases unmanaged and - optionally - managed resources.

        Parameters:
        disposing - true to release both managed and unmanaged resources; false to release only unmanaged resources.
      • dispose

        public void dispose()

        Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

        Specified by:
        dispose in interface com.aspose.ms.System.IDisposable