inmemory

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Jun 7, 2020 License: MIT Imports: 6 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PaymentConfigRepository

type PaymentConfigRepository struct {
	// contains filtered or unexported fields
}

PaymentConfigRepository is storage for payment configurations

func NewPaymentConfigRepository

func NewPaymentConfigRepository(source string) *PaymentConfigRepository

NewPaymentConfigRepository creates payment configuration data source by reading a file located on `source`

func (PaymentConfigRepository) FindAll

FindAll returns all payment configurations.

func (PaymentConfigRepository) FindByPaymentType

func (r PaymentConfigRepository) FindByPaymentType(ctx context.Context, paymentType payment.PaymentType, opts ...payment.Option) (config.FeeConfigReader, error)

FindByPaymentType return FeeConfigReader for a given payment type. If it is a credit card, credit card option will be check to get the type of installment, term and its aqcuiring bank. Otherwise 0 month installment offline from BCA will be used.

Jump to

Keyboard shortcuts

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