Documentation ¶
Index ¶
- type Database
- func (db *Database) Close()
- func (db *Database) Delete(key string)
- func (db *Database) GetMostRecentMessageForCallsign(callsign string) (*models.AprsMessage, error)
- func (db *Database) GetRecordsForCallsign(callsign string, page int64) (*PaginatedCallsignResults, error)
- func (db *Database) GetRecordsNearPosition(lat float64, long float64, timeInterval int64, radiusKM int64) (*PositionResults, error)
- func (db *Database) NumberOfCallsigns() (int64, error)
- func (db *Database) NumberOfMessagesForCallsign(callsign string) (int64, error)
- func (db *Database) PaginatedMessagesForCallsign(callsign string, start int64, stop int64) ([]string, error)
- func (db *Database) Ping() error
- func (db *Database) RecordMessage(sourceCallsign string, message *models.AprsMessage) error
- type PaginatedCallsignResults
- type PositionResults
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Database ¶
type Database struct {
// contains filtered or unexported fields
}
func NewDatabase ¶
func NewDatabase() *Database
func (*Database) GetMostRecentMessageForCallsign ¶
func (db *Database) GetMostRecentMessageForCallsign(callsign string) (*models.AprsMessage, error)
func (*Database) GetRecordsForCallsign ¶
func (db *Database) GetRecordsForCallsign(callsign string, page int64) (*PaginatedCallsignResults, error)
func (*Database) GetRecordsNearPosition ¶
func (*Database) NumberOfCallsigns ¶
func (*Database) NumberOfMessagesForCallsign ¶
func (*Database) PaginatedMessagesForCallsign ¶
func (*Database) RecordMessage ¶
func (db *Database) RecordMessage(sourceCallsign string, message *models.AprsMessage) error
type PaginatedCallsignResults ¶
type PaginatedCallsignResults struct { Page int64 `json:"page"` NumberOfPages int64 `json:"number_of_pages"` TotalNumberOfRecords int64 `json:"total_number_of_records"` Records []models.AprsMessage `json:"records"` }
type PositionResults ¶
type PositionResults struct { Size int64 `json:"size"` Records []models.AprsMessage `json:"records"` }
Click to show internal directories.
Click to hide internal directories.