LoaderFileTypeRegistry

from acron.core import LoaderFileTypeRegistry
class LoaderFileTypeRegistry

Bases:

This class maintains the set of all known LoaderFileTypes in the universe.

Inheritance diagram

digraph inheritanced5ae386385 { bgcolor=transparent; rankdir=BT; size="8.0, 12.0"; "DTOOL_SUPER_BASE" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=11,height=0.25,shape=box,style=""]; "LoaderFileTypeRegistry" [URL="acron.core.LoaderFileTypeRegistry.html#acron.core.LoaderFileTypeRegistry",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=11,height=0.25,shape=box,style="",target="_top",tooltip="/**"]; "DTOOL_SUPER_BASE" -> "LoaderFileTypeRegistry" [arrowsize=0.75,style=""]; }
__init__()
__reduce__()
static get_global_ptr()

Returns a pointer to the global LoaderFileTypeRegistry object.

get_num_types()

Returns the total number of types registered.

get_type()

Returns the nth type registered.

get_type_from_extension()

Determines the type of the file based on the indicated extension (without a leading dot). Returns NULL if the extension matches no known file types.

get_types() → list
register_deferred_type()

Records a type associated with a particular extension to be loaded in the future. The named library will be dynamically loaded the first time files of this extension are loaded; presumably this library will call register_type() when it initializes, thus making the extension loadable.

register_type()

Defines a new LoaderFileType in the universe.

property types → Sequence[LoaderFileType]

Returns the nth type registered.

unregister_type()

Removes a type previously registered using register_type().

write()

Writes a list of supported file types to the indicated output stream, one per line.