Interface nsIPaymentRequestServiceType

nsPaymentRequestService is used to manage the created PaymentRequest in the chrome process. It is also the IPC agent for payment UI to communicate with merchant side.

Hierarchy

Methods

  • Increases the reference count for this interface. The associated instance will not be deleted unless the reference count is returned to zero.

    Returns

    The resulting reference count.

    Returns number

  • Parameters

    • aIID: object
    • Optional aInstancePtr: object

    Returns any

  • A run time mechanism for interface discovery.

    Returns

    NS_OK if the interface is supported by the associated instance, NS_NOINTERFACE if it is not.

    aInstancePtr must not be null.

    Parameters

    • aIID: object

      [in] A requested interface IID

    • aInstancePtr: object

      [out] A pointer to an interface pointer to receive the result.

    Returns void

  • Decreases the reference count for this interface. Generally, if the reference count returns to zero, the associated instance is deleted.

    Returns

    The resulting reference count.

    Returns number

  • Inform the merchant the payer's details changed in the PaymentResponse.

    Parameters

    • requestId: string

      the request identifier of the payment request.

    • aPayerName: string

      the changed payer's name.

    • aPayerEmail: string

      the changed payer's email.

    • aPayerPhone: string

      the changed payer's phone.

    Returns void

  • Inform the merchant the payment method has changed.

    Parameters

    • requestId: string

      the request identifier of the payment request.

    • aMethodName: string

      the changed payment method's name.

    • aMethodDetails: nsIMethodChangeDetails

      the changed payment method's details.

    Returns void

  • Inform the merchant the shipping address has changed.

    Parameters

    • requestId: string

      the request identifier of the payment request.

    • aAddress: nsIPaymentAddress

      the new payment address.

    Returns void

  • Inform the merchant the shipping option has changed.

    Parameters

    • requestId: string

      the request identifier of the payment request.

    • option: string

      the shipping option ID string.

    Returns void

  • Following APIs are for testing or platform code only. UI implementation should not use them.

    Clean up the all managed payment requests. This API is for testing only.

    Returns void

  • Get the enumerator for all managed nsIPaymentRequests.

    Returns

    • an enumerator for all managed nsIPaymentRequests.

    Returns nsISimpleEnumerator

  • Get the nsIPaymentRequest through the given payment request identifier.

    Returns

    • the requested payment request. null if there is no coressponding nsIPaymentRequest for aRequestId.

    Parameters

    • aRequestId: string

      the payment request identifier. This is an internal id generated by Gecko.

    Returns nsIPaymentRequest

  • Send the user's response to the merchant.

    Parameters

    • aResponse: nsIPaymentActionResponse

      the user's response.

    Returns void

  • Setup the customized nsIPaymentUIService. This API is for testing only.

    Parameters

    • aUIService: nsIPaymentUIService

    Returns void

Generated using TypeDoc