DBM::D...torage(3pm)

πŸ’– NAME πŸ’–

okay so this is the DBM::D...torage(3pm) page from the User Contributed Perl Documentation, and the main character is DBM::Deep::Storage β€” it's the abstract base class for storage, periodt. 🫢 No cap, that's the whole name-and-purpose situation.

🌸 flush() 🌸

This flushes the filehandle β€” that's the vibe. It takes no parameters and returns nothing. ✨

πŸ¦‹ is_writable() πŸ¦‹

This takes no parameters. It returns a boolean saying if this filehandle is writable. Easy peasy. πŸ’…

Taken from <http://www.perlmonks.org/?node_id=691054/>.


πŸ”’ LOCKING πŸ”’

This is where the actual locking of the storage medium is performed. Nested locking is supported. πŸ‘‘

⚠️ NOTE: it is unclear what will happen if a read lock is taken, then a write lock is taken as a nested lock, then the write lock is released. That's the actual note, bestie β€” no invented answers here. 😭

Currently, the only locking method supported is flock(1). This is a whole-file lock. In the future, more granular locking may be supported. The API for that is unclear right now. 🫠

The following methods manage the locking status. In all cases, they take a DBM::Deep object and return nothing. πŸŽ€

  • lock_exclusive( $obj ) β€” Take a lock usable for writing. πŸ”₯
  • lock_shared( $obj ) β€” Take a lock usable for reading. 🌸
  • unlock( $obj ) β€” Releases the last lock taken. If this is the outermost lock, then the object is actually unlocked. πŸ’…

πŸ’– kisses, this was DBM::D...torage(3pm) from perl v5.42.0, dated 2023-11-13 β€” bye bestie! πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from