Record Class CurlRequest

java.lang.Object
java.lang.Record
ch.so.agi.gretl.internal.http.CurlRequest

public record CurlRequest(String serverUrl, CurlMethod method, Integer expectedStatusCode, String expectedBody, Map<String,String> headers, Map<String,Object> formData, String data, Path dataBinary, Path outputFile, String user, String password) extends Record
  • Constructor Details

    • CurlRequest

      public CurlRequest(String serverUrl, CurlMethod method, Integer expectedStatusCode, String expectedBody, Map<String,String> headers, Map<String,Object> formData, String data, Path dataBinary, Path outputFile, String user, String password)
      Creates an instance of a CurlRequest record class.
      Parameters:
      serverUrl - the value for the serverUrl record component
      method - the value for the method record component
      expectedStatusCode - the value for the expectedStatusCode record component
      expectedBody - the value for the expectedBody record component
      headers - the value for the headers record component
      formData - the value for the formData record component
      data - the value for the data record component
      dataBinary - the value for the dataBinary record component
      outputFile - the value for the outputFile record component
      user - the value for the user record component
      password - the value for the password record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • serverUrl

      public String serverUrl()
      Returns the value of the serverUrl record component.
      Returns:
      the value of the serverUrl record component
    • method

      public CurlMethod method()
      Returns the value of the method record component.
      Returns:
      the value of the method record component
    • expectedStatusCode

      public Integer expectedStatusCode()
      Returns the value of the expectedStatusCode record component.
      Returns:
      the value of the expectedStatusCode record component
    • expectedBody

      public String expectedBody()
      Returns the value of the expectedBody record component.
      Returns:
      the value of the expectedBody record component
    • headers

      public Map<String,String> headers()
      Returns the value of the headers record component.
      Returns:
      the value of the headers record component
    • formData

      public Map<String,Object> formData()
      Returns the value of the formData record component.
      Returns:
      the value of the formData record component
    • data

      public String data()
      Returns the value of the data record component.
      Returns:
      the value of the data record component
    • dataBinary

      public Path dataBinary()
      Returns the value of the dataBinary record component.
      Returns:
      the value of the dataBinary record component
    • outputFile

      public Path outputFile()
      Returns the value of the outputFile record component.
      Returns:
      the value of the outputFile record component
    • user

      public String user()
      Returns the value of the user record component.
      Returns:
      the value of the user record component
    • password

      public String password()
      Returns the value of the password record component.
      Returns:
      the value of the password record component