.\" -*- mode: troff; coding: utf-8 -*- .\" Automatically generated by Pod::Man 5.01 (Pod::Simple 3.43) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>. .ie n \{\ . ds C` "" . ds C' "" 'br\} .el\{\ . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "HTML::Mason::Resolver::Null 3pm" .TH HTML::Mason::Resolver::Null 3pm 2024-03-05 "perl v5.38.2" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH NAME HTML::Mason::Resolver::Null \- a do\-nothing resolver .SH SYNOPSIS .IX Header "SYNOPSIS" .Vb 1 \& my $resolver = HTML::Mason::Resolver::Null\->new; .Ve .SH DESCRIPTION .IX Header "DESCRIPTION" This HTML::Mason::Resolver subclass is useful if you want to create components via the \f(CW\*(C`HTML::Mason::Interp\->make_component\*(C'\fR method and you never plan to interact with the filesystem. .PP Basically, it provides all of the necessary resolver methods but none of them do anything. .PP This means that if you use this method things like \f(CW\*(C`$interp\->exec\*(C'\fR will simply not work at all. .PP However, if you just want to make a component with an interpreter and execute that component it can be useful. For example: .PP .Vb 2 \& my $interp = HTML::Mason::Interp\->new( resolver_class => \*(AqHTML::Mason::Resolver::Null\*(Aq, \& data_dir => \*(Aq/tmp\*(Aq ); \& \& my $comp = $interp\->make_component( comp_source => <<\*(AqEOF\*(Aq ); \&% my $var = \*(AqWorld\*(Aq; \&Hello, <% $var %>! \&EOF \& \& my $buffer; \& my $request = $interp\->make_request( out_method => \e$buffer, comp => $comp ); \& $request\->exec; \& \& print $buffer; .Ve