callinfo

package
v0.20.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 25, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CallHistoryFinder added in v0.9.0

type CallHistoryFinder interface {
	FindEntry(string) (core.AnnotatedCallsign, bool)
	Find(string) ([]core.AnnotatedCallsign, error)
}

CallHistoryFinder returns additional information for a given callsign if a call history file is used.

type Callinfo

type Callinfo struct {
	// contains filtered or unexported fields
}

func New

func New(entities DXCCFinder, callsigns CallsignFinder, callHistory CallHistoryFinder, dupeChecker DupeChecker, valuer Valuer, exchangeFilter ExchangeFilter, asyncRunner core.AsyncRunner) *Callinfo

func (*Callinfo) BestMatch added in v0.20.0

func (c *Callinfo) BestMatch() string

func (*Callinfo) BestMatches added in v0.20.0

func (c *Callinfo) BestMatches() []string

func (*Callinfo) ContestChanged added in v0.11.0

func (c *Callinfo) ContestChanged(contest core.Contest)

func (*Callinfo) EntryOnFrequency added in v0.20.0

func (c *Callinfo) EntryOnFrequency(entry core.BandmapEntry, available bool)

func (*Callinfo) GetInfo added in v0.13.0

func (c *Callinfo) GetInfo(call callsign.Callsign, band core.Band, mode core.Mode, exchange []string) core.Callinfo

func (*Callinfo) GetValue added in v0.13.0

func (c *Callinfo) GetValue(call callsign.Callsign, band core.Band, mode core.Mode, exchange []string) (points, multis int, multiValues map[conval.Property]string)

func (*Callinfo) PredictedExchange added in v0.10.0

func (c *Callinfo) PredictedExchange() []string

func (*Callinfo) Refresh added in v0.14.0

func (c *Callinfo) Refresh()

func (*Callinfo) ScoreUpdated added in v0.20.0

func (c *Callinfo) ScoreUpdated(score core.Score)

func (*Callinfo) SetView

func (c *Callinfo) SetView(view View)

func (*Callinfo) ShowInfo added in v0.4.0

func (c *Callinfo) ShowInfo(call string, band core.Band, mode core.Mode, exchange []string)

type CallsignFinder

type CallsignFinder interface {
	FindStrings(string) ([]string, error)
	Find(string) ([]core.AnnotatedCallsign, error)
}

CallsignFinder returns a list of matching callsigns for the given partial string.

type DXCCFinder

type DXCCFinder interface {
	Find(string) (dxcc.Prefix, bool)
}

DXCCFinder returns a list of matching prefixes for the given string and indicates if there was a match at all.

type DupeChecker

type DupeChecker interface {
	FindWorkedQSOs(callsign.Callsign, core.Band, core.Mode) ([]core.QSO, bool)
}

DupeChecker can be used to find out if the given callsign was already worked, according to the contest rules.

type ExchangeFilter added in v0.10.0

type ExchangeFilter interface {
	FilterExchange([]string) []string
}

ExchangeFilter clears the exchange values that cannot be predicted (RST, serial).

type Valuer added in v0.4.0

type Valuer interface {
	Value(callsign callsign.Callsign, entity dxcc.Prefix, band core.Band, mode core.Mode, exchange []string) (points, multis int, multiValues map[conval.Property]string)
}

Valuer provides the points and multis of a QSO based on the given information.

type View

type View interface {
	SetBestMatchingCallsign(callsign core.AnnotatedCallsign)
	SetDXCC(string, string, int, int, bool)
	SetValue(points, multis, value int)
	SetPredictedExchange(index int, text string)
	SetPredictedExchangeFields(fields []core.ExchangeField)
	SetUserInfo(string)
	SetSupercheck(callsigns []core.AnnotatedCallsign)
}

View defines the visual part of the call information window.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL