/****************************************************************************/1// Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.dev/sumo2// Copyright (C) 2001-2025 German Aerospace Center (DLR) and others.3// This program and the accompanying materials are made available under the4// terms of the Eclipse Public License 2.0 which is available at5// https://www.eclipse.org/legal/epl-2.0/6// This Source Code may also be made available under the following Secondary7// Licenses when the conditions for such availability set forth in the Eclipse8// Public License 2.0 are satisfied: GNU General Public License, version 29// or later which is available at10// https://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html11// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later12/****************************************************************************/13/// @file GNEEvent_FileLoaded.h14/// @author Jakob Erdmann15/// @date Feb 201116///17// Event to send when the network has been loaded by GNELoadThread18/****************************************************************************/19#pragma once20#include <config.h>2122#include <string>2324#include <utils/gui/events/GUIEvent.h>2526// ===========================================================================27// class declarations28// ===========================================================================2930class GNENet;3132// ===========================================================================33// class definitions34// ===========================================================================3536class GNEEvent_FileLoaded : public GUIEvent {3738public:39/// @brief type of loaded element40enum class Type {41NETECFG, // netedit config42SUMOCFG, // sumo config43NETCCFG, // netconvert config44NETWORK, // sumo network45OSM, // OSM network46CONSOLE, // console options47NEW, // new network48INVALID_TYPE, // invalid loading type49INVALID_OPTIONS, // invalid options50INVALID_PROJECTION, // invalid options51INVALID_CONFIG // invalid config52};5354/// @brief constructor55GNEEvent_FileLoaded(GNEEvent_FileLoaded::Type type, GNENet* net, const std::string& file,56const std::string& settingsFile, const bool viewportFromRegistry);5758/// @brief destructor59~GNEEvent_FileLoaded();6061/// @brief get event type62GNEEvent_FileLoaded::Type getType() const;6364/// @brief get the loaded net65GNENet* getNet() const;6667/// @brief get the name of the loaded file68const std::string& getFile() const;6970/// @brief get the name of the settings file to load71const std::string& getSettingsFile() const;7273/// @brief get whether loading viewport from registry74bool getViewportFromRegistry() const;7576protected:77/// @brief event type78GNEEvent_FileLoaded::Type myType = GNEEvent_FileLoaded::Type::INVALID_TYPE;7980/// @brief the loaded net81GNENet* myNet;8283/// @brief the name of the loaded file84std::string myFile;8586/// @brief the name of the settings file to load87std::string mySettingsFile;8889/// @brief whether loading viewport from registry90bool myViewportFromRegistry;9192private:93/// @brief Invalidated copy constructor.94GNEEvent_FileLoaded(const GNEEvent_FileLoaded&) = delete;9596/// @brief Invalidated assignment operator97GNEEvent_FileLoaded& operator=(const GNEEvent_FileLoaded& src) = delete;98};99100101