smah.settings.system.stats.memory_stats

Classes

MemoryStats()

Represents memory statistics.

class smah.settings.system.stats.memory_stats.MemoryStats[source]

Bases: BaseStats

Represents memory statistics.

time_stamp

The timestamp of the last update.

Type:

datetime

total

The last recorded total memory.

Type:

float

available

The last recorded available memory.

Type:

float

used

The last recorded used memory.

Type:

float

percent

The last recorded memory usage percentage.

Type:

float

static memory_info(reading)[source]

Retrieves memory information based on the specified reading type.

Parameters:

reading (str) – The type of memory information to retrieve.

Returns:

The requested memory information.

Return type:

float

readings(threshold=100)[source]

Retrieves the current memory readings, updating if necessary.

Parameters:

threshold (int) – The threshold in microseconds.

Returns:

The current memory readings.

Return type:

dict

show(options=None)[source]
update()[source]

Updates the memory statistics.