🛰️航天仿真算法库 SpaceAST
0.0.1
载入中...
搜索中...
未找到
TLEDatabase.hpp
浏览该文件的文档.
1
21
22
#pragma once
23
24
#include "AstGlobal.h"
25
#include "
Database.hpp
"
26
#include "AstCore/TLE.hpp"
27
#include "AstUtil/StringView.hpp"
28
#include <string>
29
#include <vector>
30
31
AST_NAMESPACE_BEGIN
32
38
class
TLEDatabaseQuery;
39
46
class
AST_CORE_API
TLEDatabase
:
public
Database
47
{
48
public
:
49
using
Entry
=
TLE
;
50
using
EntryList = std::vector<TLE>;
51
52
TLEDatabase
();
53
explicit
TLEDatabase
(
StringView
filePath);
54
~TLEDatabase
()
override
;
55
56
// -- 加载 --
57
errc_t load(
StringView
filePath);
58
errc_t reload();
59
bool
isLoaded()
const
{
return
loaded_; }
60
61
// -- 查询 --
62
const
EntryList& getEntries()
const
{
return
tles_; }
63
EntryList getEntries(
const
TLEDatabaseQuery
& query)
const
;
64
size_t
size()
const
{
return
tles_.size(); }
65
66
const
std::string& filePath()
const
{
return
filePath_; }
67
68
private
:
70
errc_t loadTleFile(
StringView
filePath);
71
72
private
:
73
std::string filePath_{};
74
std::vector<TLE> tles_{};
75
bool
loaded_{
false
};
76
};
77
80
AST_NAMESPACE_END
Database.hpp
数据库抽象基类
ast::Database
数据库抽象基类
定义
Database.hpp:36
ast::StringViewBasic< char >
ast::TLEDatabaseQuery
TLE 数据库查询条件
定义
TLEDatabaseQuery.hpp:43
ast::TLEDatabase
TLE 数据库
定义
TLEDatabase.hpp:47
ast::TLE
两行根数(TLE)
定义
TLE.hpp:52
src
AstCore
Database
TLEDatabase.hpp
制作者
1.12.0