Class astrea::astro::StateHistory¶
ClassList > astrea > astro > StateHistory
Class to manage the history of states for an object over date. More...
#include <StateHistory.hpp>
Public Types¶
| Type | Name |
|---|---|
| typedef StateMap::const_iterator | const_iterator Constant iterator types for iterating over the states in the history. |
| typedef StateMap::iterator | iterator Iterator types for iterating over the states in the history. |
Public Functions¶
| Type | Name |
|---|---|
| StateHistory () = default Default constructor for StateHistory . |
|
| StateHistory (const std::size_t & objectId) Constructor that initializes StateHistory with a specific object ID. |
|
| const State & | at (const Date & date) const Retrieves the state at a specific date. |
| iterator | begin () Returns an iterator to the beginning of the state history. |
| const_iterator | begin () const Returns a constant iterator to the beginning of the state history. |
| const_iterator | cbegin () const Returns a constant iterator to the beginning of the state history. |
| const_iterator | cend () const Returns a constant iterator to the end of the state history. |
| void | clear () Clears the state history, removing all stored states. |
| iterator | end () Returns an iterator to the end of the state history. |
| const_iterator | end () const Returns a constant iterator to the end of the state history. |
| const Date & | epoch () const Retrieves the epoch (first date) of the state history. |
| const State & | first () const Retrieves the first and last states in the history. |
| const State & | get_closest_state (const Date & date) const Retrieves the closest state to a given date. |
| const EventTimesMap & | get_event_times () const Retrieves the event times recorded during propagation. |
| EventTimesMap & | get_event_times () Retrieves the event times recorded during propagation. |
| std::size_t | get_object_id () const Gets the object ID for this state history. |
| State | get_state_at (const Date & date) const Retrieves the state at a specific date. |
| void | insert (const State & state) Inserts a state at a specific date into the history. |
| const State & | last () const Retrieves the last state in the history. |
| State & | operator[] (const Date & date) Accesses the state at a specific date. |
| void | set_event_times (const EventTimesMap & eventTimes) Sets the event times recorded during propagation. |
| void | set_object_id (const std::size_t & objectId) Sets the object ID for this state history. |
| std::size_t | size () const Get the number of states in the history. |
| ~StateHistory () = default Destructor for StateHistory . |
Detailed Description¶
This class allows storing, retrieving, and managing the states of an object at different dates, providing functionality to access the closest state to a given date and to convert between different orbital elements.
Public Types Documentation¶
typedef const_iterator¶
Constant iterator types for iterating over the states in the history.
typedef iterator¶
Iterator types for iterating over the states in the history.
Public Functions Documentation¶
function StateHistory [1/2]¶
Default constructor for StateHistory .
function StateHistory [2/2]¶
Constructor that initializes StateHistory with a specific object ID.
Parameters:
objectIdThe ID of the object for which the state history is maintained.
function at¶
Retrieves the state at a specific date.
Parameters:
dateThe date at which the state is requested.
Returns:
const State& Reference to the state at the specified date.
function begin [1/2]¶
Returns an iterator to the beginning of the state history.
Returns:
iterator An iterator to the first state in the history.
function begin [2/2]¶
Returns a constant iterator to the beginning of the state history.
Returns:
const_iterator A constant iterator to the first state in the history.
function cbegin¶
Returns a constant iterator to the beginning of the state history.
Returns:
const_iterator A constant iterator to the first state in the history.
function cend¶
Returns a constant iterator to the end of the state history.
Returns:
const_iterator A constant iterator to the position after the last state in the history.
function clear¶
Clears the state history, removing all stored states.
function end [1/2]¶
Returns an iterator to the end of the state history.
Returns:
iterator An iterator to the position after the last state in the history.
function end [2/2]¶
Returns a constant iterator to the end of the state history.
Returns:
const_iterator A constant iterator to the position after the last state in the history.
function epoch¶
Retrieves the epoch (first date) of the state history.
Returns:
const Date& Reference to the epoch of the state history.
function first¶
Retrieves the first and last states in the history.
Returns:
const State& Reference to the first state.
function get_closest_state¶
Retrieves the closest state to a given date.
This function finds the state that is closest to the specified date, either before or after it, and returns it.
Parameters:
dateThe date for which the closest state is requested.
Returns:
const State& Reference to the closest state.
function get_event_times [1/2]¶
Retrieves the event times recorded during propagation.
Returns:
const EventTimesMap& A vector of dates representing the event times.
function get_event_times [2/2]¶
Retrieves the event times recorded during propagation.
Returns:
const EventTimesMap& A vector of dates representing the event times.
function get_object_id¶
Gets the object ID for this state history.
Returns:
std::size_t The ID of the object for which this state history is maintained.
function get_state_at¶
Retrieves the state at a specific date.
This function returns the state at the specified date, or the closest state if no exact match is found.
Parameters:
dateThe date for which the state is requested.
Returns:
State The state at the specified date.
function insert¶
Inserts a state at a specific date into the history.
Parameters:
dateThe date at which the state is recorded.stateThe state to be inserted.
function last¶
Retrieves the last state in the history.
Returns:
const State& Reference to the last state.
function operator[]¶
Accesses the state at a specific date.
Parameters:
dateThe date at which the state is requested.
Returns:
State& Reference to the state at the specified date.
function set_event_times¶
Sets the event times recorded during propagation.
Parameters:
eventTimesA vector of dates representing the event times.
function set_object_id¶
Sets the object ID for this state history.
Parameters:
objectIdThe ID of the object for which this state history is maintained.
function size¶
Get the number of states in the history.
Returns:
std::size_t The number of states in the history.
function ~StateHistory¶
Destructor for StateHistory .
The documentation for this class was generated from the following file astrea/astro/astro/state/StateHistory.hpp