ostk.physics.environment.magnetic.earth.Manager

class Manager

Bases: Manager

Earth magnetic model data manager

Fetches and manages necessary magnetic model data files.

The following environment variables can be defined:

  • "OSTK_PHYSICS_ENVIRONMENT_MAGNETIC_EARTH_MANAGER_ENABLED" will override "DefaultEnabled"

  • "OSTK_PHYSICS_ENVIRONMENT_MAGNETIC_EARTH_MANAGER_LOCAL_REPOSITORY" will override "DefaultLocalRepository"

Methods

clear_local_repository

Clear the local repository.

fetch_data_files_for_type

Fetch data file from remote

get

Get manager singleton

get_local_repository

Get the local repository.

get_local_repository_lock_timeout

Get the local repository lock timeout.

get_mode

Get the manager mode.

has_data_files_for_type

Check if data files are available for the given type

local_data_files_for_type

Get local data files for the given type

reset

Reset the manager.

set_local_repository

Set the local repository.

set_mode

Set the manager mode.

class Mode(self: ostk.physics.Manager.Mode, value: int)

Bases: pybind11_object

Members:

Manual

Automatic

property name
clear_local_repository(self: ostk.physics.Manager) None

Clear the local repository.

fetch_data_files_for_type(
self: ostk.physics.environment.magnetic.earth.Manager,
model_type: ostk.physics.environment.magnetic.Earth.Type,
) None

Fetch data file from remote

Parameters:

model_type (EarthMagneticModel.Type) -- Model type

static get() ostk.physics.environment.magnetic.earth.Manager

Get manager singleton

Returns:

Reference to manager

Return type:

Manager

get_local_repository(
self: ostk.physics.Manager,
) ostk.core.filesystem.Directory

Get the local repository.

Returns:

Local repository.

Return type:

Directory

get_local_repository_lock_timeout(
self: ostk.physics.Manager,
) ostk::physics::time::Duration

Get the local repository lock timeout.

Returns:

Local repository lock timeout.

Return type:

Duration

get_mode(self: ostk.physics.Manager) ostk.physics.Manager.Mode

Get the manager mode.

Returns:

Manager mode.

Return type:

Mode

has_data_files_for_type(
self: ostk.physics.environment.magnetic.earth.Manager,
model_type: ostk.physics.environment.magnetic.Earth.Type,
) bool

Check if data files are available for the given type

Parameters:

model_type (EarthMagneticModel.Type) -- Model type

Returns:

True if data files are available for the given type

Return type:

bool

local_data_files_for_type(
self: ostk.physics.environment.magnetic.earth.Manager,
model_type: ostk.physics.environment.magnetic.Earth.Type,
) list[ostk.core.filesystem.File]

Get local data files for the given type

Parameters:

model_type (EarthMagneticModel.Type) -- Model type

Returns:

Local data files

Return type:

list[File]

reset(self: ostk.physics.Manager) None

Reset the manager.

set_local_repository(
self: ostk.physics.Manager,
directory: ostk.core.filesystem.Directory,
) None

Set the local repository.

Parameters:

directory (Directory) -- Local repository.

set_mode(self: ostk.physics.Manager, mode: ostk.physics.Manager.Mode) None

Set the manager mode.

Parameters:

mode (Mode) -- Manager mode.