OpenTTD Source: src/saveload/saveload_filter.h File Reference

OpenTTD Source 15.3

Data Structures | Functions
saveload_filter.h File Reference

Declaration of filters used for saving and loading savegames. More...

Go to the source code of this file.

## Data Structures
struct | LoadFilter
| Interface for filtering a savegame till it is loaded. More...
struct | SaveFilter
| Interface for filtering a savegame till it is written. More...

## Functions
template<typename T >
std::shared_ptr< LoadFilter > | CreateLoadFilter (std::shared_ptr< LoadFilter > chain)
| Instantiator for a load filter.
template<typename T >
std::shared_ptr< SaveFilter > | CreateSaveFilter (std::shared_ptr< SaveFilter > chain, uint8_t compression_level)
| Instantiator for a save filter.

## Detailed Description

Declaration of filters used for saving and loading savegames.

Definition in file saveload_filter.h.

## Function Documentation

## ◆ CreateLoadFilter()

template<typename T >

std::shared_ptr< LoadFilter > CreateLoadFilter | ( | std::shared_ptr< LoadFilter > | chain | ) |

Instantiator for a load filter.

Parameters

  chain | The next filter in this chain.

Template Parameters

  T | The type of load filter to create.

Definition at line 51 of file saveload_filter.h.

## ◆ CreateSaveFilter()

template<typename T >

std::shared_ptr< SaveFilter > CreateSaveFilter | ( | std::shared_ptr< SaveFilter > | chain,
|  | uint8_t | compression_level
| ) |  |

Instantiator for a save filter.

Parameters

  chain | The next filter in this chain.
  compression_level | The requested level of compression.

Template Parameters

  T | The type of save filter to create.

Definition at line 94 of file saveload_filter.h.