Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

jifty::view::mason::handler(3pm) [debian man page]

Jifty::View::Mason::Handler(3pm)			User Contributed Perl Documentation			  Jifty::View::Mason::Handler(3pm)

NAME
Jifty::View::Mason::Handler - Handler for Mason requests inside of Jifty SUMMARY
Jifty controls all of the input and output from the Mason templating engine; this means that we cannot use the Mason's standard HTML::Mason::CGIHandler interface to interact with it. new PARAMHASH Takes a number of key-value parameters; see HTML::Mason::Params. Defaults the "out_method" to appending to "buffer" in Jifty::Handler and the "request_class" to Jifty::View::Mason::Request (below). Finally, adds "h" and "u" escapes, which map to "escape_uri" and escape_utf8 respectively. config Returns our Mason config. We use the component root specified in the "Web/TemplateRoot" framework configuration variable (or "html" by default). Additionally, we set up a "jifty" component root, as specified by the "Web/DefaultTemplateRoot" configuration. All interpolations are HTML-escaped by default, and we use the fatal error mode. escape_utf8 SCALARREF Does a css-busting but minimalist escaping of whatever html you're passing in. escape_uri SCALARREF Escapes in-place URI component according to RFC2396. Takes a reference to perl string. *Note* that octets would be treated as latin1 encoded sequence and converted to UTF-8 encoding and then escaped. So this sub always provide UTF-8 escaped string. See also Encode for more info about converting. template_exists COMPONENT Checks if the "COMPONENT" exists, or if "COMPONENT/index.html" exists, and returns which one did. If neither did, it searches for "dhandler" components which could match, returning "COMPONENT" if it finds one. Finally, if it finds no possible component matches, returns undef. Note that this algorithm does not actually decisively return if Mason will handle a given component; the dhandlers could defer handling, for instance. show COMPONENT Takes a component path to render. Deals with setting up a global HTML::Mason::FakeApache and Request object, and calling the component. handle_comp A synonym for show request_args The official source for request arguments is from the current Jifty::Request object. create_cache_directories Attempts to create our application's mason cache directory. perl v5.14.2 2010-12-08 Jifty::View::Mason::Handler(3pm)

Check Out this Related Man Page

HTML::Mason::Compiler::ToObject(3pm)			User Contributed Perl Documentation		      HTML::Mason::Compiler::ToObject(3pm)

NAME
HTML::Mason::Compiler::ToObject - A Compiler subclass that generates Mason object code SYNOPSIS
my $compiler = HTML::Mason::Compiler::ToObject->new; my $object_code = $compiler->compile( comp_source => $source, name => $comp_name, comp_path => $comp_path, ); DESCRIPTION
This Compiler subclass generates Mason object code (Perl code). It is the default Compiler class used by Mason. PARAMETERS TO THE new() CONSTRUCTOR All of these parameters are optional. comp_class The class into which component objects are blessed. This defaults to HTML::Mason::Component. subcomp_class The class into which subcomponent objects are blessed. This defaults to HTML::Mason::Component::Subcomponent. in_package This is the package in which a component's code is executed. For historical reasons, this defaults to "HTML::Mason::Commands". preamble Text given for this parameter is placed at the beginning of each component, but after the execution of any "<%once>" block. See also postamble. The request will be available as $m in preamble code. postamble Text given for this parameter is placed at the end of each component. See also preamble. The request will be available as $m in postamble code. use_strict True or false, default is true. Indicates whether or not a given component should "use strict". named_component_subs When compiling a component, use uniquely named subroutines for the a component's body, subcomponents, and methods. Doing this allows you to effectively profile Mason components. Without this, all components simply show up as __ANON__ or something similar in the profiler. define_args_hash One of "always", "auto", or "never". This determines whether or not an %ARGS hash is created in components. If it is set to "always", one is always defined. If set to "never", it is never defined. The default, "auto", will cause the hash to be defined only if some part of the component contains the string "ARGS". This is somewhat crude, and may result in some false positives, but this is preferable to false negatives. Not defining the args hash means that we can avoid copying component arguments, which can save memory and slightly improve execution speed. ACCESSOR METHODS
All of the above properties have read-only accessor methods of the same name. You cannot change any property of a compiler after it has been created (but you can create multiple compilers with different properties). METHODS
This class is primarily meant to be used by the Interpreter object, and as such has a very limited public API. compile(...) This method will take component source and return the compiled object code for that source. See "compile(...)" in HTML::Mason::Compiler for details on this method. This subclass also accepts a "comp_class" parameter, allowing you to override the class into which the component is compiled. perl v5.14.2 2012-02-04 HTML::Mason::Compiler::ToObject(3pm)
Man Page