validator

package module
v0.0.0-...-f7473f3 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2025 License: Apache-2.0 Imports: 3 Imported by: 0

README

Generic interface around validating emails

Any type of validation

type SmtpValidator interface {
	Validate(*mailiosmtp.Mail) error
}

Errors producted by SmtpValidator

Any type of error

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Handlers

func Handlers() []string

Drivers returns a sorted list of the names of the registered drivers.

func RegisterSmtpValidatorHandler

func RegisterSmtpValidatorHandler(name string, h SmtpValidator)

RegisterSmtpValidatorHandler makes a smtp handler available by the provided name. If RegisterSmtpValidatorHandler is called twice with the same name or if driver is nil, it panics.

Types

type SmtpValidator

type SmtpValidator interface {
	Validate(*mailiosmtp.Mail) error
}

func GetHandler

func GetHandler(name string) SmtpValidator

Jump to

Keyboard shortcuts

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