notify

package
v3.2.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 6, 2024 License: MIT Imports: 13 Imported by: 1

Documentation

Index

Constants

View Source
const FAIL = "FAIL"
View Source
const SUCCESS = "SUCCESS"

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

type Handler struct {
	App     kernel.ApplicationPaymentInterface
	Message *request.RequestNotify

	Attributes *object.StringMap
	Check      bool
	Sign       bool

	ExternalRequest *http.Request
	// contains filtered or unexported fields
}

func (*Handler) DecryptMessage

func (handler *Handler) DecryptMessage() (string, error)

func (*Handler) Fail

func (handler *Handler) Fail(message string)

func (*Handler) GetMessage

func (handler *Handler) GetMessage() (notify *request.RequestNotify, err error)

func (*Handler) RespondWith

func (handler *Handler) RespondWith(attributes *object.StringMap, sign bool) *Handler

func (*Handler) Strict

func (handler *Handler) Strict(result interface{})

func (*Handler) ToResponse

func (handler *Handler) ToResponse() (response *http.Response, err error)
type Paid struct {
	*Handler
}

func NewPaidNotify

func NewPaidNotify(app kernel.ApplicationPaymentInterface, request *http.Request) *Paid

func (*Paid) Handle

func (comp *Paid) Handle(closure func(message *request.RequestNotify, transaction *models.Transaction, fail func(message string)) interface{}) (*http.Response, error)

type Refund

type Refund struct {
	*Handler
}

func NewRefundNotify

func NewRefundNotify(app kernel.ApplicationPaymentInterface, request *http.Request) *Refund

func (*Refund) Handle

func (comp *Refund) Handle(closure func(message *request.RequestNotify, refund *models.Refund, fail func(message string)) interface{}) (*http.Response, error)

type Scanned

type Scanned struct {
	*Handler
	// contains filtered or unexported fields
}

func NewScannedNotify

func NewScannedNotify(app kernel.ApplicationPaymentInterface, request *http.Request) *Scanned

func (*Scanned) Alert

func (comp *Scanned) Alert(message string)

func (*Scanned) Handle

func (comp *Scanned) Handle(closure func(message *request.RequestNotify, fail func(message string), alert func(message string)) interface{}) (*http.Response, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL