pyuff_ustb.objects.eager_load

Contents

pyuff_ustb.objects.eager_load#

pyuff_ustb.objects.eager_load(obj: T) T[source]#

Eagerly and recursively load all the lazy fields in an object.

pyuff_ustb is lazily loaded by default, meaning that most fields are not read from file until they are needed. This function will recursively load all such fields.

A new instance of the same type as the input object is returned, but with all its fields guaranteed to be loaded into memory.

Parameters:

obj (T) – An object to eagerly load.

Returns:

A new object of the same type as the input object, with all its fields

guaranteed to be loaded into memory.

Return type:

T