Skip to content

Remove API

Interface for remote data removal

This script provides a APIRemove context manager exposing functions for removing data from the server.

APIRemove

Bases: APIRemoveInternal

Interface to upload data to server

Source code in src/rmlab/api/remove.py
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
class APIRemove(APIRemoveInternal):
    """Interface to upload data to server"""

    async def remove_data_full(self, scen_id: int) -> None:
        """Remove all the data of a scenario.

        Args:
            scen_id (int): Scenario ID
        """

        await self._remove_data(scen_id, DataRemoveKind.COMPLETE)

    async def remove_data_historic(self, scen_id: int) -> None:
        """Remove all the historic flight data of a scenario.

        Args:
            scen_id (int): Scenario ID
        """

        await self._remove_data(scen_id, DataRemoveKind.HISTORIC)

remove_data_full(scen_id) async

Remove all the data of a scenario.

Parameters:

NameTypeDescriptionDefault
scen_idint

Scenario ID

required
Source code in src/rmlab/api/remove.py
14
15
16
17
18
19
20
21
async def remove_data_full(self, scen_id: int) -> None:
    """Remove all the data of a scenario.

    Args:
        scen_id (int): Scenario ID
    """

    await self._remove_data(scen_id, DataRemoveKind.COMPLETE)

remove_data_historic(scen_id) async

Remove all the historic flight data of a scenario.

Parameters:

NameTypeDescriptionDefault
scen_idint

Scenario ID

required
Source code in src/rmlab/api/remove.py
23
24
25
26
27
28
29
30
async def remove_data_historic(self, scen_id: int) -> None:
    """Remove all the historic flight data of a scenario.

    Args:
        scen_id (int): Scenario ID
    """

    await self._remove_data(scen_id, DataRemoveKind.HISTORIC)