Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Domain ¶
type Domain struct { ID uint `json:"-" gorm:"primaryKey;unique;autoIncrement"` Name string `json:"name" gorm:"index:idx_name,unique" example:"gmail.com"` Type string `json:"type" example:"whitelist"` Coverage string `json:"coverage" example:"equals"` CreatedAt time.Time `json:"-"` UpdatedAt time.Time `json:"-"` }
type DomainRepository ¶
type DomainRepository interface { FindAll() (*[]Domain, error) FindByID(id int) (*Domain, error) FindByName(name string) (*Domain, error) Create(domain *Domain) error Update(domain *Domain) error Delete(domain *Domain) error MatchEquals(name string) (*Domain, error) MatchContains(name string) (*Domain, error) MatchBegins(name string) (*Domain, error) MatchEnds(name string) (*Domain, error) }
type RootDomain ¶
type RootDomain struct { ID uint `json:"id" gorm:"primaryKey;unique;autoIncrement"` Name string `json:"name" gorm:"index:idx_name,unique"` Type string `json:"type"` TLD string `json:"tld"` Source string `json:"source"` CreatedAt time.Time `json:"created_at"` UpdatedAt time.Time `json:"updated_at"` }
type RootDomainRepository ¶
type RootDomainRepository interface { FindByID(id int) (*RootDomain, error) FindByName(name string) (*RootDomain, error) Create(rootDomain *RootDomain) error Update(rootDomain *RootDomain) error Delete(rootDomain *RootDomain) error }
Click to show internal directories.
Click to hide internal directories.