194 void SetValid(
bool valid) { bValid = valid; }
195 time_t GetFileTime()
const {
return file_date; }
196 time_t GetChartEditionDate()
const {
return edition_date; }
198 int GetnPlyEntries()
const {
return nPlyEntries; }
199 float *GetpPlyTable()
const {
return pPlyTable; }
201 int GetnAuxPlyEntries()
const {
return nAuxPlyEntries; }
202 float *GetpAuxPlyTableEntry(
int index)
const {
return pAuxPlyTable[index]; }
203 int GetAuxCntTableEntry(
int index)
const {
return pAuxCntTable[index]; }
205 int GetnNoCovrPlyEntries()
const {
return nNoCovrPlyEntries; }
206 float *GetpNoCovrPlyTableEntry(
int index)
const {
207 return pNoCovrPlyTable[index];
209 int GetNoCovrCntTableEntry(
int index)
const {
return pNoCovrCntTable[index]; }
211 const LLBBox &GetBBox()
const {
return m_bbox; }
213 char *GetpFullPath()
const {
return pFullPath; }
214 float GetLonMax()
const {
return LonMax; }
215 float GetLonMin()
const {
return LonMin; }
216 float GetLatMax()
const {
return LatMax; }
217 float GetLatMin()
const {
return LatMin; }
218 int GetScale()
const {
return Scale; }
219 int GetChartType()
const {
return ChartType; }
220 int GetChartFamily()
const {
return ChartFamily; }
221 int GetChartProjectionType()
const {
return ProjectionType; }
222 float GetChartSkew()
const {
return Skew; }
224 bool GetbValid() {
return bValid; }
225 void SetEntryOffset(
int n) { EntryOffset = n; }
226 const wxString *GetpFileName(
void)
const {
return m_pfilename; }
227 wxString *GetpsFullPath(
void)
const {
return m_psFullPath; }
228 wxString GetFullSystemPath()
const {
return m_fullSystemPath; }
229 const std::string &GetFullPath()
const {
return m_FullPath; }
231 const std::vector<int> &GetGroupArray(
void)
const {
return m_GroupArray; }
232 void ClearGroupArray(
void) { m_GroupArray.clear(); }
233 void AddIntToGroupArray(
int val) { m_GroupArray.push_back(val); }
234 void SetAvailable(
bool avail) { m_bavail = avail; }
236 std::vector<float> GetReducedPlyPoints();
237 std::vector<float> GetReducedAuxPlyPoints(
int iTable);
239 LLRegion quilt_candidate_region;
241 void SetScale(
int scale);
242 bool Scale_eq(
int b)
const {
return abs(Scale - b) <= rounding; }
243 bool Scale_ge(
int b)
const {
return Scale_eq(b) || Scale > b; }
244 bool Scale_gt(
int b)
const {
return Scale > b && !Scale_eq(b); }
262 float **pAuxPlyTable;
267 int nNoCovrPlyEntries;
268 int *pNoCovrCntTable;
269 float **pNoCovrPlyTable;
271 std::vector<int> m_GroupArray;
272 wxString *m_pfilename;
273 wxString *m_psFullPath;
274 wxString m_fullSystemPath;
275 std::string m_FullPath;
280 std::vector<float> m_reducedPlyPoints;
282 std::vector<std::vector<float>> m_reducedAuxPlyPointsVector;
320 bool Create(ArrayOfCDI &dir_array, wxGenericProgressDialog *pprog);
328 bool Update(ArrayOfCDI &dir_array,
bool bForce,
329 wxGenericProgressDialog *pprog);
331 bool Read(
const wxString &filePath);
332 bool Write(
const wxString &filePath);
334 bool AddSingleChart(wxString &fullpath,
bool b_force_full_search =
true);
335 bool RemoveSingleChart(wxString &ChartFullPath);
337 const wxString &GetDBFileName()
const {
return m_DBFileName; }
338 ArrayOfCDI &GetChartDirArray() {
return m_dir_array; }
339 wxArrayString &GetChartDirArrayString() {
return m_chartDirs; }
340 void SetChartDirArray(ArrayOfCDI array) { m_dir_array = array; }
341 bool CompareChartDirArray(ArrayOfCDI &test_array);
342 wxString GetMagicNumberCached(wxString dir);
344 void UpdateChartClassDescriptorArray(
void);
346 int GetChartTableEntries()
const {
return active_chartTable.size(); }
349 inline ChartTable &GetChartTable() {
return active_chartTable; }
351 bool IsValid()
const {
return bValid; }
352 int DisableChart(wxString &PathToDisable);
353 bool GetCentroidOfLargestScaleChart(
double *clat,
double *clon,
354 ChartFamilyEnum family);
355 int GetDBChartType(
int dbIndex);
356 int GetDBChartFamily(
int dbIndex);
357 float GetDBChartSkew(
int dbIndex);
358 int GetDBChartProj(
int dbIndex);
359 int GetDBChartScale(
int dbIndex);
361 bool GetDBBoundingBox(
int dbindex, LLBBox &box);
362 const LLBBox &GetDBBoundingBox(
int dbIndex);
364 int GetnAuxPlyEntries(
int dbIndex);
365 int GetDBPlyPoint(
int dbIndex,
int plyindex,
float *lat,
float *lon);
366 int GetDBAuxPlyPoint(
int dbIndex,
int plyindex,
int iAuxPly,
float *lat,
368 int GetVersion() {
return m_dbversion; }
369 wxString GetFullChartInfo(
ChartBase *pc,
int dbIndex,
int *char_width,
371 int FinddbIndex(wxString PathToFind);
372 wxString GetDBChartFileName(
int dbIndex);
373 void ApplyGroupArray(ChartGroupArray *pGroupArray);
374 bool IsChartAvailable(
int dbIndex);
375 ChartTable active_chartTable;
376 std::map<wxString, int> active_chartTable_pathindex;
378 std::vector<float> GetReducedPlyPoints(
int dbIndex);
379 std::vector<float> GetReducedAuxPlyPoints(
int dbIndex,
int iTable);
381 bool IsBusy() {
return m_b_busy; }
384 virtual ChartBase *GetChart(
const wxChar *theFilePath,
386 int AddChartDirectory(
const wxString &theDir,
bool bshow_prog);
387 void SetValid(
bool valid) { bValid = valid; }
392 std::vector<ChartClassDescriptor> m_ChartClassDescriptorArray;
393 ArrayOfCDI m_dir_array;
397 bool IsChartDirUsed(
const wxString &theDir);
399 int SearchDirAndAddCharts(wxString &dir_name_base,
401 wxGenericProgressDialog *pprog);
404 wxGenericProgressDialog *pprog,
405 wxString &dir_magic,
bool bForce);
406 bool DetectDirChange(
const wxString &dir_path,
const wxString &prog_label,
407 const wxString &magic, wxString &new_magic,
408 wxGenericProgressDialog *pprog);
411 wxGenericProgressDialog *pprog,
int isearch,
412 bool bthis_dir_in_dB);
414 bool Check_CM93_Structure(wxString dir_name);
417 wxArrayString m_chartDirs;
421 m_ChartTableEntryDummy;
422 wxString m_DBFileName;
Represents an entry in the chart table, containing information about a single chart.