Alzabo::Schema(3pm)
π Alzabo::Schema β the whole vibe π
okay bestie, so this is the manual page for Alzabo::Schema (yes, the (3pm) one, the User Contributed Perl Documentation one, that's the girlies we're talking about) and she is literally the blueprint for schema objects. like, the base class. the mother of all schemas. main character energy, no cap. π
β¨ SYNOPSIS β¨
use base qw(Alzabo::Schema);
that's it. that's the whole entrance. she said "inherit from me, bestie" π
πΈ DESCRIPTION πΈ
This is the base class for schema objects..
yes there are two periods at the end, i'm not fixing her, she's iconic π
π METHODS π
π¦ name
Returns a string containing the name of the schema. that's it, that's her name, that's what she answers to. simple. elegant. slay. β¨
π¦ table ($name)
Returns an Alzabo::Table object representing the specified table.
π¨ heads up bestie: an Alzabo::Exception::Params exception is throws if the schema does not contain the table. (the original page says "is throws" and honestly? we respect her grammar choices, but the vibe is: it throws. it will absolutely throw at you. π)
π¦ tables (@optional_list)
okay so this one has range:
- If no arguments are given, this method returns a list of all the
Alzabo::Tableobjects in the schema β or, in a scalar context, the number of such tables. π - If one or more arguments are given, it returns a list of table objects with those names, in the same order given (or, in a scalar context, the number of such tables β but ngl, that's not terribly useful, the page said it, not me π« ).
π¨ and again: an Alzabo::Exception::Params exception is throws if the schema does not contain one or more of the specified tables. she does not do half-friendships with tables that don't exist. periodt.
π¦ has_table ($name)
Returns a boolean value indicating whether the table exists in the schema. a simple yes/no, exists/doesn't, real/fake, in/out. vibe check for tables. π§
π¦ begin_work
Starts a transaction. Calls to this function may be nested and it will be handled properly. so go ahead and nest them, she can hold all those thoughts at once, multitasking queen. π
π¦ rollback
Rollback a transaction. we're undoing it. we're pretending it never happened. no evidence, no receipts. π
π¦ commit
Finishes a transaction with a commit.
β οΈ real talk: if you make multiple calls to begin_work(), make sure to call this method the same number of times. count them. keep the count. do not lose the count. π
π¦ run_in_transaction ( sub { code... } )
This method takes a subroutine reference and wraps it in a transaction.
It will preserve the context of the caller and returns whatever the wrapped code would have returned. so she matches your energy and hands you back exactly what your code gave her. obsessed. π«Ά
π¦ driver
Returns the Alzabo::Driver object for the schema. π₯
π¦ rules
Returns the Alzabo::RDBMSRules object for the schema. π
π¦ sqlmaker
Returns the Alzabo::SQLMaker object for the schema. making that SQL, bestie. β
π AUTHOR π
Dave Rolsky, <autarch@urth.org> β the actual author, the one who wrote all this, credit where credit is due, respect the architect. π
and that's a wrap!! this page is from perl v5.34.0, dated 2022-06-14, filed under Alzabo::Schema(3pm) β go forth and schema responsibly, bestie, you're gonna do amazing πβ¨ππ¦πΈπ
π«Άπ
π¦ where this page comes from
- debian bookworm: libalzabo-perl 0.92-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- debian trixie: libalzabo-perl 0.92-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libalzabo-perl 0.92-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libalzabo-perl 0.92-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libalzabo-perl 0.92-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms