MCPcopy
hub / github.com/beetbox/beets / load

Method load

beets/dbcore/db.py:636–647  ·  view source on GitHub ↗

Refresh the object's metadata from the library database. If check_revision is true, the database is only queried loaded when a transaction has been committed since the item was last loaded.

(self)

Source from the content-addressed store, hash-verified

634 self.clear_dirty()
635
636 def load(self):
637 """Refresh the object's metadata from the library database.
638
639 If check_revision is true, the database is only queried loaded when a
640 transaction has been committed since the item was last loaded.
641 """
642 if not self._dirty and self.db.revision == self._revision:
643 # Exit early
644 return
645
646 self.__dict__.update(self.get_fresh_from_db().__dict__)
647 self.clear_dirty()
648
649 def remove(self):
650 """Remove the object's associated rows from the database."""

Calls 3

get_fresh_from_dbMethod · 0.95
clear_dirtyMethod · 0.95
updateMethod · 0.45