App::Sp...esponse(3)

πŸ“¦ version 0.15.0, in opensuse-leap 16.0

πŸ’– NAME πŸ’–

okay so this is App::Sp...esponse(3) from the User Contributed Perl Documentation β€” the manual for App::Spec::Run::Response, aka the Response class for App::Spec::Run. periodt. πŸ’…


✨ METHODS ✨

🫢 add_output

If you pass it a string, it will create a App::Spec::Run::Output. yes bestie, that's the class πŸ’–

$res->add_output("string\n", "string2\n");
my $output = App::Spec::Run::Output->new(
    content => "string\n",
);
$res->add_output($output);

This will call print_output if buffered is false, otherwise it will add the output to outputs. no cap. ✨

πŸ™ˆ add_error

Like add_output, but the created Output object will have an attribute error set to 1. same energy, different flag πŸ’œ

$res->add_error("string\n", "string2\n");
my $output = App::Spec::Run::Output->new(
    error => 1,
    content => "string\n",
);
$res->add_error($output);
$res->print_output(@out);

Prints the given output and all output in outputs. iconic behavior honestly πŸ¦‹

πŸŽ€ add_callbacks

$response->add_callbacks(print_output => \@callbacks);

Where @callbacks are coderefs. iykyk πŸ’…


πŸŽ€ ATTRIBUTES πŸŽ€

🌸 buffered

If true, output should be buffered until print_output is called.

Default: false

πŸ’€ exit

The exit code.

πŸ¦‹ outputs

Holds an array of App::Spec::Run::Output objects.

βœ… finished

Set to 1 after print_output has been called.

βœ‹ halted

If set to 1, no further processing should be done.

🫢 callbacks

Contains a hashref of callbacks:

{
    print_output => $coderef,
},

that's the whole manual, bestie 🫢 β€” it's perl v5.42.0, dated 2025-03-26, and the page is App::Sp...esponse(3). slay. πŸ’…βœ¨

πŸ“¦ where this page comes from