com.aspose.html.net

Class HttpMethod

  • All Implemented Interfaces:
    com.aspose.ms.System.IEquatable<HttpMethod>


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

    Represents utility class for retrieving and comparing standard HTTP methods.

    • Constructor Detail

      • HttpMethod

        public HttpMethod(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.
      • 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(Object obj)

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

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

        public int hashCode()

        Returns a hash code for this instance.

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

        public String toString()

        Returns a System.String that represents this instance.

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