Documentation ¶
Index ¶
- func MigrateDB(db *sqlx.DB) error
- func NewDB(cfg *config.Config) (*sqlx.DB, error)
- type DisposableStore
- func (db *DisposableStore) Create(domain string, score int) (*models.DisposableEmail, error)
- func (db *DisposableStore) Delete(id int) (bool, error)
- func (db *DisposableStore) Find(id int) (*models.DisposableEmail, error)
- func (db *DisposableStore) FindAll() (*[]string, error)
- func (db *DisposableStore) FindByDomain(domain string) (*models.DisposableEmail, error)
- type FreeEmailStore
- func (db *FreeEmailStore) Create(domain string, score int) (*models.FreeEmail, error)
- func (db *FreeEmailStore) Delete(id int) (bool, error)
- func (db *FreeEmailStore) Find(id int) (*models.FreeEmail, error)
- func (db *FreeEmailStore) FindAll() (*[]string, error)
- func (db *FreeEmailStore) FindByDomain(domain string) (*models.FreeEmail, error)
- type ProxyStore
- func (db *ProxyStore) Create(ip, port, types string) (*models.Proxy, error)
- func (db *ProxyStore) Delete(id int) (bool, error)
- func (db *ProxyStore) DeleteOld(hour int) (bool, error)
- func (db *ProxyStore) Find(id int) (*models.Proxy, error)
- func (db *ProxyStore) FindAll() (*[]models.Proxy, error)
- func (db *ProxyStore) FindByIP(ipaddress string) (*models.Proxy, error)
- type SpamEmailStore
- func (db *SpamEmailStore) Create(domain string, score int) (*models.SpamEmail, error)
- func (db *SpamEmailStore) Delete(id int) (bool, error)
- func (db *SpamEmailStore) Find(id int) (*models.SpamEmail, error)
- func (db *SpamEmailStore) FindAll() (*[]string, error)
- func (db *SpamEmailStore) FindByDomain(domain string) (*models.SpamEmail, error)
- type SpamStore
- func (db *SpamStore) Create(ip string, prefix byte, score int, iptype string) (*models.Spam, error)
- func (db *SpamStore) Delete(id int) (bool, error)
- func (db *SpamStore) DeleteOld(hour int) (bool, error)
- func (db *SpamStore) Find(id int) (*models.Spam, error)
- func (db *SpamStore) FindAll() (*[]models.Spam, error)
- func (db *SpamStore) FindAllIPs() (*[]string, error)
- func (db *SpamStore) FindByIP(ipaddress string) (*models.Spam, error)
- type TorStore
- func (db *TorStore) Create(ip string, prefix byte, iptype string, score int) (*models.Tor, error)
- func (db *TorStore) Delete(id int) (bool, error)
- func (db *TorStore) DeleteOld(hour int) (bool, error)
- func (db *TorStore) Find(id int) (*models.Tor, error)
- func (db *TorStore) FindAll() (*[]models.Tor, error)
- func (db *TorStore) FindAllIPs() (*[]string, error)
- func (db *TorStore) FindByIP(ipaddress string) (*models.Tor, error)
- type VpnStore
- func (db *VpnStore) Create(ip string, prefix byte, iptype string, score int) (*models.Vpn, error)
- func (db *VpnStore) Delete(id int) (bool, error)
- func (db *VpnStore) DeleteOld(hour int) (bool, error)
- func (db *VpnStore) Find(id int) (*models.Vpn, error)
- func (db *VpnStore) FindAll() (*[]models.Vpn, error)
- func (db *VpnStore) FindAllIPs() (*[]string, error)
- func (db *VpnStore) FindByIP(ip string) (*models.Vpn, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DisposableStore ¶
func (*DisposableStore) Create ¶
func (db *DisposableStore) Create(domain string, score int) (*models.DisposableEmail, error)
func (*DisposableStore) Find ¶
func (db *DisposableStore) Find(id int) (*models.DisposableEmail, error)
func (*DisposableStore) FindAll ¶
func (db *DisposableStore) FindAll() (*[]string, error)
func (*DisposableStore) FindByDomain ¶
func (db *DisposableStore) FindByDomain(domain string) (*models.DisposableEmail, error)
type FreeEmailStore ¶
func (*FreeEmailStore) FindAll ¶
func (db *FreeEmailStore) FindAll() (*[]string, error)
func (*FreeEmailStore) FindByDomain ¶
func (db *FreeEmailStore) FindByDomain(domain string) (*models.FreeEmail, error)
type ProxyStore ¶
type SpamEmailStore ¶
func (*SpamEmailStore) FindAll ¶
func (db *SpamEmailStore) FindAll() (*[]string, error)
func (*SpamEmailStore) FindByDomain ¶
func (db *SpamEmailStore) FindByDomain(domain string) (*models.SpamEmail, error)
Click to show internal directories.
Click to hide internal directories.