Documentation
¶
Index ¶
- type ReportSummary
- type Statistics
- type Storage
- func (s *Storage) Close() error
- func (s *Storage) GetReportByID(id int64) (*parser.Feedback, error)
- func (s *Storage) GetReports(limit, offset int) ([]ReportSummary, error)
- func (s *Storage) GetStatistics() (*Statistics, error)
- func (s *Storage) GetTopSourceIPs(limit int) ([]TopSourceIP, error)
- func (s *Storage) SaveReport(feedback *parser.Feedback) error
- type TopSourceIP
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ReportSummary ¶
type ReportSummary struct {
ID int64 `json:"id"`
ReportID string `json:"report_id"`
OrgName string `json:"org_name"`
Domain string `json:"domain"`
DateBegin int64 `json:"date_begin"`
DateEnd int64 `json:"date_end"`
TotalMessages int `json:"total_messages"`
CompliantMessages int `json:"compliant_messages"`
ComplianceRate float64 `json:"compliance_rate"`
PolicyP string `json:"policy_p"`
}
type Statistics ¶
type Storage ¶
type Storage struct {
// contains filtered or unexported fields
}
func NewStorage ¶
NewStorage creates a new storage instance
func (*Storage) GetReports ¶
func (s *Storage) GetReports(limit, offset int) ([]ReportSummary, error)
func (*Storage) GetStatistics ¶
func (s *Storage) GetStatistics() (*Statistics, error)
func (*Storage) GetTopSourceIPs ¶
func (s *Storage) GetTopSourceIPs(limit int) ([]TopSourceIP, error)
Click to show internal directories.
Click to hide internal directories.