Documentation ¶
Index ¶
- func GetEnvOrDefault(variable string, defaultValue string) string
- type Domain
- type IPv4
- type IPv6
- type MySqlReader
- type MySqlStorage
- func (m MySqlStorage) AddDomain(domain Domain) (d Domain, err error)
- func (m MySqlStorage) AddDomainAsString(domain string, zoneId int64) (d Domain, err error)
- func (m MySqlStorage) AddZone(zone Zone) (z Zone, err error)
- func (m MySqlStorage) DeleteDomain(domain Domain) (err error)
- func (m MySqlStorage) DeleteDomainById(domainId int64) (err error)
- func (m MySqlStorage) DeleteZone(zone Zone) (err error)
- func (m MySqlStorage) DeleteZoneById(zoneId int64) (err error)
- func (m MySqlStorage) FetchZones() (z []Zone, err error)
- func (m MySqlStorage) LookupDomain(domain string) (d Domain, err error)
- func (m MySqlStorage) UpdateDomain(d Domain) (dom Domain, err error)
- func (m MySqlStorage) UpdateZone(zone Zone) (z Zone, err error)
- type Zone
- type ZoneReader
- type ZoneStorage
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetEnvOrDefault ¶
Types ¶
type Domain ¶
type MySqlReader ¶
type MySqlReader struct {
// contains filtered or unexported fields
}
func BuildMySqlReader ¶
func NewMySqlReader ¶
func NewMySqlReader() (MySqlReader, error)
func (*MySqlReader) FetchZones ¶
func (m *MySqlReader) FetchZones() (z []Zone, err error)
This methods retrieves list of Zones from the database server
func (*MySqlReader) LookupDomain ¶
func (m *MySqlReader) LookupDomain(domain string) (d Domain, err error)
This method retrieves Zone id from the database server. This ZoneID can be converted to A or AAAA record.
type MySqlStorage ¶
type MySqlStorage struct {
// contains filtered or unexported fields
}
func BuildMySqlStorage ¶
func NewMySqlStorage ¶
func NewMySqlStorage() (MySqlStorage, error)
func (MySqlStorage) AddDomain ¶
func (m MySqlStorage) AddDomain(domain Domain) (d Domain, err error)
This method adds specified domain to the database
func (MySqlStorage) AddDomainAsString ¶
func (m MySqlStorage) AddDomainAsString(domain string, zoneId int64) (d Domain, err error)
This method adds specified domain
func (MySqlStorage) DeleteDomain ¶
func (m MySqlStorage) DeleteDomain(domain Domain) (err error)
This method allows to delete specified domain from the database
func (MySqlStorage) DeleteDomainById ¶
func (m MySqlStorage) DeleteDomainById(domainId int64) (err error)
This method allows to delete domain with specified ID from the database
func (MySqlStorage) DeleteZone ¶
func (m MySqlStorage) DeleteZone(zone Zone) (err error)
func (MySqlStorage) DeleteZoneById ¶
func (m MySqlStorage) DeleteZoneById(zoneId int64) (err error)
func (MySqlStorage) FetchZones ¶
func (m MySqlStorage) FetchZones() (z []Zone, err error)
func (MySqlStorage) LookupDomain ¶
func (m MySqlStorage) LookupDomain(domain string) (d Domain, err error)
func (MySqlStorage) UpdateDomain ¶
func (m MySqlStorage) UpdateDomain(d Domain) (dom Domain, err error)
This method updates specified domain in the database.
func (MySqlStorage) UpdateZone ¶
func (m MySqlStorage) UpdateZone(zone Zone) (z Zone, err error)
type ZoneReader ¶
type ZoneStorage ¶
type ZoneStorage interface { FetchZones() (z []Zone, err error) AddZone(zone Zone) (z Zone, err error) UpdateZone(zone Zone) (z Zone, err error) DeleteZone(zone Zone) (err error) DeleteZoneById(zoneId int64) (err error) LookupDomain(domain string) (d Domain, err error) AddDomainAsString(domain string, zoneId int64) (d Domain, err error) AddDomain(domain Domain) (d Domain, err error) UpdateDomain(domain Domain) (d Domain, err error) DeleteDomain(domain Domain) (err error) DeleteDomainById(domainId int64) (err error) }
Click to show internal directories.
Click to hide internal directories.