FERS 1.0.0
The Flexible Extensible Radar Simulator
Loading...
Searching...
No Matches
schedule_period.h
Go to the documentation of this file.
1// SPDX-License-Identifier: GPL-2.0-only
2//
3// Copyright (c) 2025-present FERS Contributors (see AUTHORS.md).
4//
5// See the GNU GPLv2 LICENSE file in the FERS project root for more information.
6
7#pragma once
8
9#include <string>
10#include <vector>
11
12#include "core/config.h"
13
14namespace radar
15{
16 /**
17 * @struct SchedulePeriod
18 * @brief Represents a time period during which the transmitter is active.
19 */
25
26 /**
27 * @brief Processes a raw list of schedule periods.
28 *
29 * This function performs the following operations:
30 * 1. Filters invalid periods (start >= end).
31 * 2. Filters periods completely outside simulation bounds.
32 * 3. Sorts periods by start time.
33 * 4. Merges overlapping or adjacent periods.
34 * 5. Checks against PRI constraints (if pulsed).
35 *
36 * @param periods The raw vector of periods.
37 * @param ownerName The name of the object owning this schedule (for logging).
38 * @param isPulsed Whether the object is operating in pulsed mode.
39 * @param pri The Pulse Repetition Interval (only used if isPulsed is true).
40 * @return A sorted, merged, and validated vector of periods.
41 */
42 std::vector<SchedulePeriod> processRawSchedule(std::vector<SchedulePeriod> periods, const std::string& ownerName,
43 bool isPulsed, RealType pri);
44}
Global configuration file for the project.
double RealType
Type for real numbers.
Definition config.h:27
std::vector< SchedulePeriod > processRawSchedule(std::vector< SchedulePeriod > periods, const std::string &ownerName, const bool isPulsed, const RealType pri)
Processes a raw list of schedule periods.
Represents a time period during which the transmitter is active.