-
Notifications
You must be signed in to change notification settings - Fork 60
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[tmp] RJD-1057 (3/5): Remove non-API member functions: EntityManager’s member functions forwarded to EntityBase (1/2) #1333
Draft
TauTheLepton
wants to merge
51
commits into
RJD-1057-traffic-lights-tests
Choose a base branch
from
RJD-1057-remove-functions-forwarded-to-entity-base-middle
base: RJD-1057-traffic-lights-tests
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
… exceptions were thrown Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
… API Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
…p-time' into RJD-1057-remove-functions-forwarded-to-entity-base
…d' into RJD-1057-remove-functions-forwarded-to-entity-base
…ntityBase, remove forwarding
…ion to EntityBase, remove forwarding
…sInLanelet, remove forwarding
…tityBase, also some getters, left setVelocityLimit and setBehaviorParameter
…develop templated is() in EntityBase and use it, rename isEgoSpawned to isAnyEgoSpawned, refactor
…ng setBehaviorParameter and setVelocityLimit
…ng request*, move requestLaneChange to EntityBase
…n forwarding, set "waiting" as init action state in behavior_tree
…awned, move checkCollision directly to API
…develop getEgoEntity and dedicated methods in EgoEntity
…o RJD-1057-remove-functions-forwarded-to-entity-base
…y in calc it directly in evaluateTimeHeadway
Signed-off-by: Mateusz Palczuk <[email protected]>
…om-entity-manager' into RJD-1057-remove-functions-forwarded-to-entity-base-middle Signed-off-by: Mateusz Palczuk <[email protected]>
…to RJD-1057-remove-functions-forwarded-to-entity-base-middle Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
yamacir-kit
deleted the
RJD-1057-remove-functions-forwarded-to-entity-base-middle
branch
September 18, 2024 01:42
TauTheLepton
restored the
RJD-1057-remove-functions-forwarded-to-entity-base-middle
branch
October 2, 2024 07:32
…ctions-forwarded-to-entity-base-middle Signed-off-by: Mateusz Palczuk <[email protected]>
TauTheLepton
added
the
bump major
If this pull request merged, bump major version of the scenario_simulator_v2
label
Oct 3, 2024
…nto RJD-1057-remove-functions-forwarded-to-entity-base-middle
dmoszynski
changed the title
[tmp] Remove non-API member functions: EntityManager’s member functions forwarded to EntityBase (1/2)
[tmp] RJD-1057 (3/5): Remove non-API member functions: EntityManager’s member functions forwarded to EntityBase (1/2)
Oct 15, 2024
…nto RJD-1057-remove-functions-forwarded-to-entity-base-middle
…etSpeedReached arguments
…ctions-forwarded-to-entity-base-middle
Quality Gate passedIssues Measures |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
bump major
If this pull request merged, bump major version of the scenario_simulator_v2
wait for regression test
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
DO NOT MERGE | THIS IS A TEMPORARY PR | WHEN THE RIGHT TIME COMES, A CLONE WILL BE CAST TO MASTER
Abstract
This pull request introduces the change of exposing direct access to Entity objects through the API. This change increases flexibility of using the API and removes the need to have many forwarding functions to Entities member functions.
Background
This pull request is one of many that aim to modularize the scenario_simulator_v2.
Details
The main goal of this PR was to remove numerous member functions of
EntityManager
(and subsequently some of API too) that forwarded calls to Entities member functions:scenario_simulator_v2/simulation/traffic_simulator/include/traffic_simulator/entity/entity_manager.hpp
Lines 162 to 216 in 0dbf4ec
This has largely been achieved by exposing direct access to Entity and its member functions through the
API::getEntity
function:scenario_simulator_v2/simulation/traffic_simulator/include/traffic_simulator/api/api.hpp
Line 303 in 8940b3e
The following change was to adjust all cpp mock scenarios to use the new interface.
This is the main reason why this PR is so large - all mock scenarios had to be corrected.
Scenarios using the new interface have been changed similarly to the example below.
Before:
scenario_simulator_v2/mock/cpp_mock_scenarios/src/follow_lane/acquire_position_in_world_frame.cpp
Lines 41 to 64 in 0dbf4ec
After:
scenario_simulator_v2/mock/cpp_mock_scenarios/src/follow_lane/acquire_position_in_world_frame.cpp
Lines 41 to 64 in 8940b3e
Similar changes had to be applied to the whole codebase relying on the API like
simulator_core.hpp
.What is more,
EgoEntity
has been modified in such a way, that the functionscenario_simulator_v2/simulation/traffic_simulator/include/traffic_simulator/entity/ego_entity.hpp
Line 68 in 0dbf4ec
has been replaced with a set of other functions below:
scenario_simulator_v2/simulation/traffic_simulator/include/traffic_simulator/entity/ego_entity.hpp
Lines 155 to 164 in 8940b3e
This change simplifies the interface of calling Ego specific actions like
engage
orsendCooperateCommand
.References
INTERNAL LINK
Destructive Changes
Known Limitations