OpenTTD Source 20260109-master-g241b5fcdfe
init.h
Go to the documentation of this file.
1/*
2 * This file is part of OpenTTD.
3 * OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
4 * OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
5 * See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <https://www.gnu.org/licenses/old-licenses/gpl-2.0>.
6 */
7
10#ifndef INIT_H
11#define INIT_H
12
13#include "linkgraphjob_base.h"
14
20public:
21
26 void Run(LinkGraphJob &job) const override { job.Init(); }
27};
28
29#endif /* INIT_H */
A handler doing "something" on a link graph component.
Stateless, thread safe initialization handler.
Definition init.h:19
void Run(LinkGraphJob &job) const override
Initialize the link graph job.
Definition init.h:26
Class for calculation jobs to be run on link graphs.
void Init()
Initialize the link graph job: Resize nodes and edges and populate them.
Some typedefs for component handlers.