Class Signature


  • public class Signature
    extends Object
    Signature
    • Constructor Detail

      • Signature

        public Signature()
    • Method Detail

      • askSignatureOnScreen

        public Signature askSignatureOnScreen​(Boolean askSignatureOnScreen)
      • getAskSignatureOnScreen

        public Boolean getAskSignatureOnScreen()
        If `skipSignature` is false, indicates whether the shopper should provide a signature on the display (**true**) or on the merchant receipt (**false**).
        Returns:
        askSignatureOnScreen
      • setAskSignatureOnScreen

        public void setAskSignatureOnScreen​(Boolean askSignatureOnScreen)
      • getDeviceName

        public String getDeviceName()
        Name that identifies the terminal.
        Returns:
        deviceName
      • setDeviceName

        public void setDeviceName​(String deviceName)
      • getDeviceSlogan

        public String getDeviceSlogan()
        Slogan shown on the start screen of the device.
        Returns:
        deviceSlogan
      • setDeviceSlogan

        public void setDeviceSlogan​(String deviceSlogan)
      • getSkipSignature

        public Boolean getSkipSignature()
        Skip asking for a signature. This is possible because all global card schemes (American Express, Diners, Discover, JCB, MasterCard, VISA, and UnionPay) regard a signature as optional.
        Returns:
        skipSignature
      • setSkipSignature

        public void setSkipSignature​(Boolean skipSignature)
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • validateJsonObject

        public static void validateJsonObject​(com.google.gson.JsonObject jsonObj)
                                       throws IOException
        Validates the JSON Object and throws an exception if issues found
        Parameters:
        jsonObj - JSON Object
        Throws:
        IOException - if the JSON Object is invalid with respect to Signature
      • fromJson

        public static Signature fromJson​(String jsonString)
                                  throws IOException
        Create an instance of Signature given an JSON string
        Parameters:
        jsonString - JSON string
        Returns:
        An instance of Signature
        Throws:
        IOException - if the JSON string is invalid with respect to Signature
      • toJson

        public String toJson()
        Convert an instance of Signature to an JSON string
        Returns:
        JSON string