Documentation
¶
Index ¶
- Constants
- Variables
- type ADashClient
- type Attackers_t
- type AuthCallBack
- type AuthResponse
- type AuthValid
- type CharacterInfo
- type CharacterInfoExt
- type CntrItems
- type Contracts
- type CorpMiningSettings
- type CorpWallet
- type Ctrl
- func (obj *Ctrl) AddLogEntry(entry string)
- func (obj *Ctrl) CheckIfDirector(char *EsiChar) bool
- func (obj *Ctrl) CheckServerUp(char *EsiChar) (retval bool)
- func (obj *Ctrl) CheckUpdatePreCon() (ok bool, err error)
- func (obj *Ctrl) GenerateMiningData()
- func (obj *Ctrl) GetAllyInfoFromEsi(char *EsiChar, allyID int) (dbAllyInfo *model.DBallyInfo, result bool)
- func (obj *Ctrl) GetCharInfo(char *EsiChar)
- func (obj *Ctrl) GetCharInfoExt(char *EsiChar)
- func (obj *Ctrl) GetContractItems(char *EsiChar, corp bool, contractID int)
- func (obj *Ctrl) GetCorp(char *EsiChar) *EsiCorp
- func (obj *Ctrl) GetCorpDirector(corpId int) *EsiChar
- func (obj *Ctrl) GetCorpInfoFromEsi(char *EsiChar, corpId int) (dbcorp *model.DBcorpInfo, result bool)
- func (obj *Ctrl) GetCorpTicker(char *EsiChar) (corpTicker string)
- func (obj *Ctrl) GetKillMail(char *EsiChar, dbKM *model.DBKillmail, nameMapping map[int]string, ...)
- func (obj *Ctrl) GetOreValueByAmount(oreTypeID int, amount int) (totalValue float64, err error)
- func (obj *Ctrl) GetOreValueByM3(oreTypeID int, volumeM3 float64) (value float64, err error)
- func (obj *Ctrl) GetRequestMock() (result ReqMockFuncT)
- func (obj *Ctrl) GetStructureNameCached(structureID int64, char *EsiChar) (name string)
- func (obj *Ctrl) GetStructureNameFromEsi(char *EsiChar, structureId int64) (retval string)
- func (obj *Ctrl) GetUniverseMock(inputReq string, inputUniData string) (result string)
- func (obj *Ctrl) HTTPShutdown()
- func (obj *Ctrl) InitiateKMSkipList(char *EsiChar, corp bool)
- func (obj *Ctrl) Load(cfgFileName string, testEnable bool) (retval error)
- func (obj *Ctrl) OpenAuthInBrowser()
- func (obj *Ctrl) ParseJournalDescription(jourEntry *Journal)
- func (obj *Ctrl) RefreshAuth(char *EsiChar, enforce bool) (result bool)
- func (obj *Ctrl) Save(cfgFileName string, testEnable bool) (retval error)
- func (obj *Ctrl) ServerCancelled() bool
- func (obj *Ctrl) StartServer()
- func (obj *Ctrl) SummaryLogEntry(typeStr string, char *EsiChar, corp bool, statusMap map[string]int64)
- func (obj *Ctrl) UpdateAllDataCmd(updateProg func(c float64), finishCb func())
- func (obj *Ctrl) UpdateChar(char *EsiChar)
- func (obj *Ctrl) UpdateContractItems(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateContracts(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateContractsInDb(char *EsiChar, corp bool, contractList []Contracts)
- func (obj *Ctrl) UpdateCorp(director *EsiChar)
- func (obj *Ctrl) UpdateCorpMembers(director *EsiChar, corp bool)
- func (obj *Ctrl) UpdateCorpMiningObs(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateGuiStatus1(entry string)
- func (obj *Ctrl) UpdateGuiStatus2(entry string)
- func (obj *Ctrl) UpdateIndustry(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateIndustryInDb(char *EsiChar, corp bool, jobList []JobInfos, statusMap map[string]int64)
- func (obj *Ctrl) UpdateJournal(char *EsiChar, corp bool, division int)
- func (obj *Ctrl) UpdateKillMails(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateMail(char *EsiChar)
- func (obj *Ctrl) UpdateMailLabels(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateMarket(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateMiningAllies(char *EsiChar, allyMap map[int]int)
- func (obj *Ctrl) UpdateMiningChars(char *EsiChar)
- func (obj *Ctrl) UpdateMiningCorps(char *EsiChar)
- func (obj *Ctrl) UpdateMiningMeta(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateNotifications(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateOrders(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateOrdersInDb(char *EsiChar, corp bool, orderList []Order)
- func (obj *Ctrl) UpdateSkippListLastMonth(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateStructures(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateTransaction(char *EsiChar, corp bool)
- func (obj *Ctrl) UpdateWallet(char *EsiChar, corp bool)
- func (obj *Ctrl) ZkillOk(kmId int) (retval bool)
- type EsiChar
- type EsiCorp
- type EsiData
- type EsiFileErrCode
- type EsiFileError
- type EsiUpdate
- type GuiSettings
- type Items_t
- type JobInfos
- type Journal
- type JournalSettings
- type KillMail_t
- type KillMailsRecent_t
- type Mail
- type MailLabel
- type MailStatus
- type MarketPrice
- type MiningData
- type MiningObservers
- type NVConfigData
- type Notification
- type Order
- type PapElem
- type Position_t
- type Recipients
- type ReqMockFuncT
- type ServerStatus
- type Transaction
- type UpdateFlags
- type UpdateFunc
- type Victim_t
Constants ¶
View Source
const ( ConfigFileName = "omipCfg.dat" DebounceTime = 60 * 60 * 4 TstCfgJson = "TestCtrlMain.json" )
View Source
const (
// id ranges https://gist.github.com/a-tal/5ff5199fdbeb745b77cb633b7f4400bb
EsiCorpIdLimit = 98000000
)
Variables ¶
View Source
var ADhttpGetMock func(url string, data url.Values) (bodyBytes []byte, err error, resp *http.Response)
View Source
var CtrlTestEnable bool
View Source
var HttpPostDataMock string
View Source
var HttpRequestMock func(req *http.Request) (bodyBytes []byte, err error, resp *http.Response)
View Source
var TestAdashFlag bool
Functions ¶
This section is empty.
Types ¶
type ADashClient ¶
type ADashClient struct {
Username string
Password string
CorpTicker string
CorpName string
LoginOK bool
Model *model.Model
CorpID int
AddLogCB func(entry string)
PapLogMap map[string]int
// contains filtered or unexported fields
}
func NewADashClient ¶
func (*ADashClient) CheckPapLinks ¶
func (obj *ADashClient) CheckPapLinks() (result string)
func (*ADashClient) ConvertAdashPap2DB ¶
func (obj *ADashClient) ConvertAdashPap2DB(pap *PapElem) *model.DBpap
func (*ADashClient) ConvertPapTimeStrToInt ¶
func (obj *ADashClient) ConvertPapTimeStrToInt(timeString string) int64
func (*ADashClient) GetPapLinks ¶
func (obj *ADashClient) GetPapLinks() bool
func (*ADashClient) Login ¶
func (obj *ADashClient) Login() bool
type Attackers_t ¶
type Attackers_t struct {
AllianceID int32 `json:"alliance_id"`
CharacterID int32 `json:"character_id"`
CorporationID int32 `json:"corporation_id"`
DamageDone int32 `json:"damage_done"`
FactionID int32 `json:"faction_id"`
FinalBlow bool `json:"final_blow"`
SecurityStatus float32 `json:"security_status"`
ShipTypeID int32 `json:"ship_type_id"`
WeaponTypeID int32 `json:"weapon_type_id"`
}
type AuthCallBack ¶
type AuthCallBack func(newChar *EsiChar)
type AuthResponse ¶
type CharacterInfo ¶
type CharacterInfoExt ¶
type Contracts ¶
type Contracts struct {
Acceptor_id int32 `json:"acceptor_id"`
Assignee_id int32 `json:"assignee_id"`
Availability string `json:"availability"`
Buyout float64 `json:"buyout"`
Collateral float64 `json:"collateral"`
Contract_id int32 `json:"contract_id"`
Date_accepted string `json:"date_accepted"`
Date_completed string `json:"date_completed"`
Date_expired string `json:"date_expired"`
Date_issued string `json:"date_issued"`
Days_to_complete int32 `json:"days_to_complete"`
End_location_id int64 `json:"end_location_id"`
For_corporation bool `json:"for_corporation"`
Issuer_corporation_id int32 `json:"issuer_corporation_id"`
Issuer_id int32 `json:"issuer_id"`
Price float64 `json:"price"`
Reward float64 `json:"reward"`
Start_location_id int64 `json:"start_location_id"`
Status string `json:"status"`
Title string `json:"title"`
Type string `json:"type"`
Volume float64 `json:"volume"`
}
type CorpMiningSettings ¶ added in v1.0.11
type CorpWallet ¶
type Ctrl ¶
type Ctrl struct {
Model *model.Model
Esi EsiData
Svr httpSrvData
AuthCb AuthCallBack
ADash map[int]*ADashClient
LogEntries []string
AddLogCB func(entry string)
GuiStatusCB func(entry string, fieldId int)
Up EsiUpdate
NotifyInfo map[int64]bool // initialized in UpdateAllData()
// contains filtered or unexported fields
}
func (*Ctrl) AddLogEntry ¶
func (*Ctrl) CheckIfDirector ¶
func (*Ctrl) CheckServerUp ¶
func (*Ctrl) CheckUpdatePreCon ¶
func (*Ctrl) GenerateMiningData ¶ added in v1.0.11
func (obj *Ctrl) GenerateMiningData()
func (*Ctrl) GetAllyInfoFromEsi ¶ added in v1.0.11
func (*Ctrl) GetCharInfo ¶
func (*Ctrl) GetCharInfoExt ¶
func (*Ctrl) GetContractItems ¶
func (*Ctrl) GetCorpDirector ¶
func (*Ctrl) GetCorpInfoFromEsi ¶ added in v1.0.11
func (*Ctrl) GetCorpTicker ¶
func (*Ctrl) GetKillMail ¶
func (*Ctrl) GetOreValueByAmount ¶ added in v1.0.11
func (*Ctrl) GetOreValueByM3 ¶ added in v1.0.11
func (*Ctrl) GetRequestMock ¶ added in v1.0.11
func (obj *Ctrl) GetRequestMock() (result ReqMockFuncT)
func (*Ctrl) GetStructureNameCached ¶
func (*Ctrl) GetStructureNameFromEsi ¶
func (*Ctrl) GetUniverseMock ¶ added in v1.0.11
func (*Ctrl) HTTPShutdown ¶
func (obj *Ctrl) HTTPShutdown()
func (*Ctrl) InitiateKMSkipList ¶
func (*Ctrl) OpenAuthInBrowser ¶
func (obj *Ctrl) OpenAuthInBrowser()
func (*Ctrl) ParseJournalDescription ¶
func (*Ctrl) ServerCancelled ¶
func (*Ctrl) StartServer ¶
func (obj *Ctrl) StartServer()
func (*Ctrl) SummaryLogEntry ¶
func (*Ctrl) UpdateAllDataCmd ¶
func (*Ctrl) UpdateChar ¶
func (*Ctrl) UpdateContractItems ¶
func (*Ctrl) UpdateContracts ¶
func (*Ctrl) UpdateContractsInDb ¶
func (*Ctrl) UpdateCorp ¶
func (*Ctrl) UpdateCorpMembers ¶
func (*Ctrl) UpdateCorpMiningObs ¶ added in v1.0.11
UpdateCorpMiningObs retrieve list of corp mining observers via /corporation/{corporation_id}/mining/observers/
func (*Ctrl) UpdateGuiStatus1 ¶
func (*Ctrl) UpdateGuiStatus2 ¶
func (*Ctrl) UpdateIndustry ¶
func (*Ctrl) UpdateIndustryInDb ¶
func (*Ctrl) UpdateKillMails ¶
func (*Ctrl) UpdateMail ¶
func (*Ctrl) UpdateMailLabels ¶
func (*Ctrl) UpdateMarket ¶
func (*Ctrl) UpdateMiningAllies ¶ added in v1.0.11
func (*Ctrl) UpdateMiningChars ¶ added in v1.0.11
func (*Ctrl) UpdateMiningCorps ¶ added in v1.0.11
func (*Ctrl) UpdateMiningMeta ¶ added in v1.0.11
UpdateMiningMeta ensure we know all the names from all entities
func (*Ctrl) UpdateNotifications ¶
func (*Ctrl) UpdateOrders ¶
func (*Ctrl) UpdateOrdersInDb ¶
func (*Ctrl) UpdateSkippListLastMonth ¶
func (*Ctrl) UpdateStructures ¶
func (*Ctrl) UpdateTransaction ¶
func (*Ctrl) UpdateWallet ¶
type EsiChar ¶
type EsiChar struct {
InitAuth AuthResponse
RefreshAuthData AuthResponse
CharInfoData CharacterInfo
CharInfoExt CharacterInfoExt
ImageFile string
NextAuthTimeStamp int64
UpdateFlags UpdateFlags
KmSkipList map[int32]bool // map[KillmailID]bool
AuthValid AuthValid
GuiSettings GuiSettings
// contains filtered or unexported fields
}
var NewChar *EsiChar
type EsiFileErrCode ¶
type EsiFileErrCode int
const ( ESI_FILE_DECRYPT_ERROR EsiFileErrCode = iota ESI_FILE_OPEN_ERROR ESI_FILE_WRITE_ERROR ESI_FILE_JSON_ERROR )
type EsiFileError ¶
type EsiFileError struct {
ErrorCode EsiFileErrCode
FileName string
ExtErr string
}
func (EsiFileError) Error ¶
func (obj EsiFileError) Error() (result string)
type EsiUpdate ¶
type EsiUpdate struct {
UpdateFuncList []UpdateFunc
UpdateMutex sync.Mutex
JobList []string
}
type GuiSettings ¶ added in v1.0.11
type GuiSettings struct {
Jour JournalSettings
CorpMining CorpMiningSettings
}
type JobInfos ¶
type JobInfos struct {
ActivityId int `json:"activity_id"`
BlueprintId int64 `json:"blueprint_id"`
BlueprintLocationId int64 `json:"blueprint_location_id"`
BlueprintTypeId int `json:"blueprint_type_id"`
CompletedCharacterId int `json:"completed_character_id"`
CompletedDate string `json:"completed_date"`
Cost float64 `json:"cost"`
Duration int `json:"duration"`
EndDate string `json:"end_date"`
FacilityId int64 `json:"facility_id"`
InstallerId int `json:"installer_id"`
JobId int `json:"job_id"`
LicensedRuns int `json:"licensed_runs"`
OutputLocationId int64 `json:"output_location_id"`
PauseDate string `json:"pause_date"`
Probability float64 `json:"probability"`
ProductTypeId int `json:"product_type_id"`
Runs int `json:"runs"`
StartDate string `json:"start_date"`
StationId int64 `json:"station_id"`
Status string `json:"status"`
SuccessfulRuns int `json:"successful_runs"`
}
type Journal ¶
type Journal struct {
Amount float64 `json:"amount"`
Balance float64 `json:"balance"`
Context_id int64 `json:"context_id"`
Context_id_type string `json:"context_id_type"`
Date string `json:"date"`
Description string `json:"description"`
First_party_id int64 `json:"first_party_id"`
Id int64 `json:"id"`
Reason string `json:"reason"`
Ref_type string `json:"ref_type"`
Second_party_id int64 `json:"second_party_id"`
Tax float64 `json:"tax"`
Tax_receiver_id int64 `json:"tax_receiver_id"`
}
type JournalSettings ¶ added in v1.0.11
type KillMail_t ¶
type KillMailsRecent_t ¶
type MailStatus ¶
type MailStatus struct {
Labels []MailLabel `json:"labels"`
TotalUnreadCount int `json:"total_unread_count"`
}
MailStatus struct for mail labels https://esi.evetech.net/v3/characters/%d/mail/labels/?datasource=tranquility
type MarketPrice ¶
type MiningData ¶ added in v1.0.11
type MiningObservers ¶ added in v1.0.11
type NVConfigData ¶
type NVConfigData struct {
PeriodFilter string
}
NVConfigData non-volatile config
type Notification ¶
type Order ¶
type Order struct {
Duration int64 `json:"duration"`
Escrow float64 `json:"escrow"`
IsBuyOrder bool `json:"is_buy_order"`
IsCorporation bool `json:"is_corporation"`
Issued string `json:"issued"`
LocationID int64 `json:"location_id"`
MinVolume int `json:"min_volume"`
OrderID int64 `json:"order_id"`
Price float64 `json:"price"`
Range string `json:"range"`
RegionID int `json:"region_id"`
TypeID int `json:"type_id"`
VolumeRemain int `json:"volume_remain"`
VolumeTotal int `json:"volume_total"`
}
type Position_t ¶
type Recipients ¶
type ReqMockFuncT ¶ added in v1.0.11
var TestMockReq ReqMockFuncT
type ServerStatus ¶
type Transaction ¶
type Transaction struct {
ClientID int `json:"client_id"`
Date string `json:"date"`
IsBuy bool `json:"is_buy"`
JournalRefID int64 `json:"journal_ref_id"`
LocationID int64 `json:"location_id"`
Quantity int `json:"quantity"`
TransactionID int64 `json:"transaction_id"`
TypeID int `json:"type_id"`
UnitPrice float64 `json:"unit_price"`
}
type UpdateFlags ¶
type UpdateFunc ¶
type Victim_t ¶
type Victim_t struct {
AllianceID int32 `json:"alliance_id"`
CharacterID int32 `json:"character_id"`
CorporationID int32 `json:"corporation_id"`
DamageTaken int32 `json:"damage_taken"`
FactionID int32 `json:"faction_id"`
Items []Items_t `json:"items"`
Position Position_t `json:"position"`
ShipTypeID int32 `json:"ship_type_id"`
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.