com.aspose.html.net

Class HttpMethod

  • java.lang.Object
    • com.aspose.html.net.HttpMethod
  • All Implemented Interfaces:
    com.aspose.ms.System.IEquatable<HttpMethod>


    public class HttpMethod
    extends java.lang.Object
    implements com.aspose.ms.System.IEquatable<HttpMethod>

    Represents utility class for retrieving and comparing standard HTTP methods.

    • Constructor Summary

      Constructors 
      Constructor and Description
      HttpMethod(java.lang.String method)
      Initializes a new instance of the HttpMethod class with a specific HTTP method.
    • Constructor Detail

      • HttpMethod

        public HttpMethod(java.lang.String method)

        Initializes a new instance of the HttpMethod class with a specific HTTP method.

        Parameters:
        method - The method.
    • Method Detail

      • getGet

        public static HttpMethod getGet()

        Represents an HTTP GET protocol method.

        Value: The HTTP GET method.
      • getPut

        public static HttpMethod getPut()

        Represents an HTTP PUT protocol method.

        Value: The HTTP PUT protocol method.
      • getPost

        public static HttpMethod getPost()

        Represents an HTTP POST protocol method.

        Value: The HTTP POST protocol method.
      • getDelete

        public static HttpMethod getDelete()

        Represents an HTTP DELETE protocol method.

        Value: The HTTP DELETE protocol method.
      • op_Equality

        public static boolean op_Equality(HttpMethod left,
                                          HttpMethod right)

        Implements the equality operator.

        Parameters:
        left - The left operand.
        right - The left operand.
        Returns:
        The result of the operation.
      • op_Inequality

        public static boolean op_Inequality(HttpMethod left,
                                            HttpMethod right)

        Implements the equality operator.

        Parameters:
        left - The left operand.
        right - The left operand.
        Returns:
        The result of the operation.
      • to_HttpMethod

        public static HttpMethod to_HttpMethod(java.lang.String name)

        Performs an explicit conversion from String to HttpMethod.

        Parameters:
        name - The http-method name.
        Returns:
        The result of the conversion.
      • getName

        public java.lang.String getName()

        Gets the method name.

        Value: The name.
      • equals

        public boolean equals(HttpMethod other)

        Indicates whether the current object is equal to another object of the same type.

        Parameters:
        other - An object to compare with this object.
        Returns:
        true if the current object is equal to the other parameter; otherwise, false.
      • equals

        public boolean equals(java.lang.Object obj)

        Determines whether the specified Object, is equal to this instance.

        Specified by:
        equals in interface com.aspose.ms.System.IEquatable<HttpMethod>
        Overrides:
        equals in class java.lang.Object
        Parameters:
        obj - The Object to compare with this instance.
        Returns:
        true if the specified Object is equal to this instance; otherwise, false.
      • hashCode

        public int hashCode()

        Returns a hash code for this instance.

        Overrides:
        hashCode in class java.lang.Object
        Returns:
        A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table.
      • toString

        public java.lang.String toString()

        Returns a String that represents this instance.

        Overrides:
        toString in class java.lang.Object
        Returns:
        A String that represents this instance.