Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
eclipse
GitHub Repository: eclipse/sumo
Path: blob/main/src/netedit/elements/moving/GNEMoveResult.h
185790 views
1
/****************************************************************************/
2
// Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.dev/sumo
3
// Copyright (C) 2001-2025 German Aerospace Center (DLR) and others.
4
// This program and the accompanying materials are made available under the
5
// terms of the Eclipse Public License 2.0 which is available at
6
// https://www.eclipse.org/legal/epl-2.0/
7
// This Source Code may also be made available under the following Secondary
8
// Licenses when the conditions for such availability set forth in the Eclipse
9
// Public License 2.0 are satisfied: GNU General Public License, version 2
10
// or later which is available at
11
// https://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html
12
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later
13
/****************************************************************************/
14
/// @file GNEMoveResult.h
15
/// @author Pablo Alvarez Lopez
16
/// @date Mar 2020
17
///
18
// Class used for define move results
19
/****************************************************************************/
20
#pragma once
21
#include <config.h>
22
23
#include "GNEMoveOperation.h"
24
25
// ===========================================================================
26
// class definitions
27
// ===========================================================================
28
29
class GNEMoveResult {
30
31
public:
32
/// @brief constructor
33
GNEMoveResult(const GNEMoveOperation* moveOperation);
34
35
/// @brief destructor
36
~GNEMoveResult();
37
38
/// @brief shape to update (edited in moveElement)
39
PositionVector shapeToUpdate;
40
41
/// @brief shape points to move (of shapeToMove)
42
std::vector<int> geometryPointsToMove;
43
44
/// @brief move operation
45
const GNEMoveOperation::OperationType operationType;
46
47
/// @brief lane offset
48
double firstLaneOffset = 0;
49
50
/// @brief new first Lane
51
const GNELane* newFirstLane = nullptr;
52
53
/// @brief new first position
54
double newFirstPos = INVALID_DOUBLE;
55
56
/// @brief lane offset
57
double lastLaneOffset = 0;
58
59
/// @brief new last Lane
60
const GNELane* newLastLane = nullptr;
61
62
/// @brief new last position
63
double newLastPos = INVALID_DOUBLE;
64
65
private:
66
/// @brief Invalidated copy constructor.
67
GNEMoveResult(const GNEMoveResult&) = delete;
68
69
/// @brief Invalidated assignment operator.
70
GNEMoveResult& operator=(const GNEMoveResult&) = delete;
71
};
72
73