user: What is BlendData(bpy_struct) and how is it used in Blender Python scripting?

assistant:  RNA type identifier.

        Returns:
        :   The class or default when not found.

        Return type:
        :   type

    file_path_foreach(*visit_path_fn*, *\**, *subset=None*, *visit_types=None*, *flags={'SKIP_PACKED', 'SKIP_WEAK_REFERENCES'}*)
    :   Call `visit_path_fn` for the file paths used by all ID data-blocks in current `bpy.data`.

        For list of valid set members for visit_types, see: [`bpy.types.KeyingSetPath.id_type`](bpy.types.KeyingSetPath.html#bpy.types.KeyingSetPath.id_type "bpy.types.KeyingSetPath.id_type").

        Parameters:
        :   - **visit_path_fn** (Callable[[[`bpy.types.ID`](bpy.types.ID.html#bpy.types.ID "bpy.types.ID"), str, Any], str|None]) – function that takes three parameters: the data-block, a file path, and a placeholder for future use. The function should return either `None` or a `str`. In the latter case, the visited file path will be replaced with the returned string.
            - **subset** (*set**[**str**]*) – When given, only these data-blocks and their used file paths will be visited.
            - **visit_types** (*set**[**str**]*) – When given, only visit data-blocks of these types. Ignored if `subset` is also given.
            - **flags** (*set**[**str**]*) – Set of flags that influence which data-blocks are visited. See [File Path Foreach Flag Items](bpy_types_enum_items/file_path_foreach_flag_items.html#rna-enum-file-path-foreach-flag-items).

    file_path_map(*\**, *subset=None*, *key_types=None*, *include_libraries=False*)
    :   Returns a mapping of all ID data-blocks in current `bpy.data` to a set of all file paths used by them.

        For list of valid set members for key_types, see: [`bpy.types.KeyingSetPath.id_type`](bpy.types.KeyingSetPath.html#bpy.types.KeyingSetPath.id_type "bpy.types.KeyingSetPath.id_type").

        Parameters:
        :   - **subset** (*sequence*) – When given, only these data-blocks and their used file paths will be included as keys/values in the map.
            - **key_types** (*set**[**str**]*) – When given, filter the keys mapped by ID types. Ignored if `subset` is also given.
            - **include_libraries** (*bool*) – Include library file paths of linked data. False by default.

        Returns:
        :   dictionary of [`bpy.types.ID`](bpy.types.ID.html#bpy.types.ID "bpy.types.ID") instances, with sets of file path strings as their values.

        Return type:
        :   dict

    orphans_purge()
    :   Remove (delete) all IDs with no user.

        Parameters:
        :   - **do_local_ids** (*bool**,* *optional*) – Include unused local IDs in the deletion, defaults to True
            - **do_linked_ids** (*bool**,* *optional*) – Include unused linked IDs in the deletion, defaults to True
            - **do_recursive** (*bool**,* *optional*) – Recursively check for unused IDs, ensuring no orphaned one remain after a single run of that function, defaults to False

        Returns:
        :   The number of deleted IDs.

    temp_data(*\**, *filepath=None*)
    :   A context manager that temporarily creates blender file data.

        Parameters:
        :   **filepath** (*str* *|* *bytes* *|* *None*) – The file path for the newly temporary data. When None, the path of the currently open file is used.

        Returns:
        :   Blend file data which is freed once the context exists.

        Return type:
        :   [`bpy.types.BlendData`](#bpy.types.BlendData "bpy.types.BlendData")

    user_map(*\**, *subset=None*, *key_types=None*, *value_types=None*)
    :   Returns a mapping of all ID data-blocks in current `bpy.data` to a set of all data-blocks using them.

        For list of valid set members for key_types & value_types, see: [`bpy.types.KeyingSetPath.id_type`](bpy.types.KeyingSetPath.html#bpy.types.KeyingSetPath.id_type "bpy.types.KeyingSetPath.id_type").

        Parameters:
        :   - **subset** (Sequence[[`bpy.types.ID`](bpy.types.ID.html#bpy.types.ID "bpy.types.ID")]) – When passed, only these data-blocks and their users will be included as keys/values in the map.
            - **key_types** (*set**[**str**]*) – Filter the keys mapped by ID types.
            - **value_types** (*set**[**str**]*) – Filter the values in the set by ID types.

        Returns:
        :   dictionary that maps data-blocks ID’s to their users.

        Return type:
        :   dict[[`bpy.types.ID`](bpy.types.ID.html#bpy.types.ID "bpy.types.ID"), set[[`bpy.types.ID`](bpy.types.ID.html#bpy.types.ID "bpy.types.ID")]]