Appende...ayBuffer(3)

πŸ’… Appende...ayBuffer(3) β€” like, the whole tea πŸ“

okay bestie, before we even start: this page is Appende...ayBuffer(3) from the Perl world, and it's giving "internal test helper, do not perceive her" energy. but we're gonna perceive her anyway because that's what we do 🫢


✨ NAME ✨

Log::Log4perl::Appender::TestArrayBuffer β€” she's a subclass of Appender::TestBuffer, no cap πŸ’…


🌸 SYNOPSIS 🌸

bestie just copy this exactly, i'm not joking, character for character, don't touch anything 😭

use Log::Log4perl::Appender::TestArrayBuffer;

my $appender = Log::Log4perl::Appender::TestArrayBuffer->new(
    name      => 'buffer',
);

    # Append to the buffer
$appender->log(
    level =  > 'alert',
    message => ['first', 'second', 'third'],
);

    # Retrieve the result
my $result = $appender->buffer();

    # Reset the buffer to the empty string
$appender->reset();

(yes, level = > 'alert' really is written like that in the original β€” i'm keeping it exactly as-is, that's the rule, don't come for me πŸ™ˆ)

so the vibe is: make one with new(...) and a name of 'buffer', shove messages in with log(...), pull the result back out with buffer(), and yeet it all with reset() which sets the buffer back to the empty string πŸŽ€


πŸ¦‹ DESCRIPTION πŸ¦‹

okay so here's the situation. this class is a subclass of Log::Log4perl::Appender::TestBuffer, and honestly the whole extra thing she brings to the table is: message array refs. that's it. that's the feature. she's an icon for it though ⭐

and just like Log::Log4perl::Appender::TestBuffer, Log::Log4perl::Appender::TestArrayBuffer is used for internal Log::Log4perl testing only. so like β€” internal. testing. only. bestie, do not build your whole app on her, she's not that kind of girl πŸ’€


πŸ‘‘ LICENSE πŸ‘‘

Copyright 2002-2013 by Mike Schilli <m@perlmeister.com> and Kevin Goess <cpan@goess.org>.

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

periodt. that's the whole license. free software, same terms as Perl itself, slay ✨


🌈 AUTHOR 🌈

please contribute patches to the project on Github, that's the assignment 🫢

http://github.com/mschilli/log4perl

send bug reports or requests for enhancements to the authors via our β€” and listen β€” MAILING LIST (questions, bug reports, suggestions/patches):

log4perl-devel@lists.sourceforge.net

Authors (please contact them via the list above, not directly): Mike Schilli <m@perlmeister.com>, Kevin Goess <cpan@goess.org>

ok this part is genuinely important: contact them via the list above, not directly. do not slide into their DMs with your bug report, that's not the move πŸ™ˆ

Contributors (in alphabetical order): Ateeq Altaf, Cory Bennett, Jens Berthold, Jeremy Bopp, Hutton Davidson, Chris R. Donnelly, Matisse Enzer, Hugh Esco, Anthony Foiani, James FitzGibbon, Carl Franks, Dennis Gregorovic, Andy Grundman, Paul Harrington, Alexander Hartmaier David Hull, Robert Jacobson, Jason Kohles, Jeff Macdonald, Markus Peter, Brett Rann, Peter Rabbitson, Erik Selberg, Aaron Straup Cope, Lars Thegler, David Viner, Mac Yang.

look at that contributor list β€” absolute main character energy from every single one of them πŸ‘‘


and that's the whole page, bestie! πŸ’– cute little sign-off: this one's from perl v5.42.0, dated 2022-10-22 β€” so she's got a little vintage moment going on, and honestly? she ate. πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from