AxKit2::XSP::SimpleTaglib 1.1
Sponsored Links
AxKit2::XSP::SimpleTaglib 1.1 Ranking & Summary
File size:
0.63 MB
Platform:
Any Platform
License:
Perl Artistic License
Price:
Downloads:
1138
Date added:
2006-09-12
Publisher:
Jörg Walter
AxKit2::XSP::SimpleTaglib 1.1 description
AxKit2::XSP::SimpleTaglib is an alternate XSP taglib helper.
SYNOPSIS
package Your::XSP::Package;
use AxKit2::XSP::SimpleTaglib;
... more initialization stuff, start_document handler, utility functions, whatever
you like, but no parse_start/end handler needed - if in doubt, just leave empty ...
sub some_tag : XSP_attrib(id) XSP_attribOrChild(some-param) XSP_node(result) XSP_keepWhitespace {
my ($tag, $attr, $stack, $struct) = @_;
return do_something($$attr{some-param},$$attr{id});
}
# old style usage no longer documented, but still supported
This taglib helper allows you to easily write tag handlers with most of the common behaviours needed. It manages all Design Patterns from the XSP man page plus several other useful tag styles, including object-like access as in ESQL.
Simple handler subs
A tag "
" will trigger a call to sub "foo" during the closing tag event. What happens in between can be configured in many ways using Perl function attributes. In the rare cases where some action has to happen during the opening tag event, you may provide a sub "foo__open" (double underscore) which will be called at the appropriate time. Usually you would only do that for if- style tags which enclose some block of code. if-style tags usually also need the XSP_compile flag.
Contrary to the former behaviour, your tag handler is called during the XSP execution stage, so you should directly return the result value. The XSP_compile flag is available to have your handler called in the parse stage, when the XSP script is being constructed. Then, it is the responsibility of the handler to return a Perl code fragment to be appended to the XSP script.
As a comparison, TaglibHelper subs are strictly run-time called, while plain taglibs without any helper are strictly compile-time called.
Warning: The old usage is still fully supported, but you should not use it anymore. It may become deprecated in a future release and will be removed entirely afterwards. Porting it to the new style usage is quite easy: remove the line reading "package your-taglib::Handler;", then prefix "XSP_" to all Perl attributes (e.g., "childStruct" becomes "XSP_childStruct"), and add "XSP_compile" to every handler sub. If after your refactoring some handler sub doesnt carry any Perl attribute anymore, add a plain "XSP" Perl attribute.
Perl attributes without the XSP_ prefix cause a warning (actually, sometimes even two, one from Perl and one from SimpleTaglib), as lower-case Perl attributes are reserved for Perl itself.
SYNOPSIS
package Your::XSP::Package;
use AxKit2::XSP::SimpleTaglib;
... more initialization stuff, start_document handler, utility functions, whatever
you like, but no parse_start/end handler needed - if in doubt, just leave empty ...
sub some_tag : XSP_attrib(id) XSP_attribOrChild(some-param) XSP_node(result) XSP_keepWhitespace {
my ($tag, $attr, $stack, $struct) = @_;
return do_something($$attr{some-param},$$attr{id});
}
# old style usage no longer documented, but still supported
This taglib helper allows you to easily write tag handlers with most of the common behaviours needed. It manages all Design Patterns from the XSP man page plus several other useful tag styles, including object-like access as in ESQL.
Simple handler subs
A tag "
Contrary to the former behaviour, your tag handler is called during the XSP execution stage, so you should directly return the result value. The XSP_compile flag is available to have your handler called in the parse stage, when the XSP script is being constructed. Then, it is the responsibility of the handler to return a Perl code fragment to be appended to the XSP script.
As a comparison, TaglibHelper subs are strictly run-time called, while plain taglibs without any helper are strictly compile-time called.
Warning: The old usage is still fully supported, but you should not use it anymore. It may become deprecated in a future release and will be removed entirely afterwards. Porting it to the new style usage is quite easy: remove the line reading "package your-taglib::Handler;", then prefix "XSP_" to all Perl attributes (e.g., "childStruct" becomes "XSP_childStruct"), and add "XSP_compile" to every handler sub. If after your refactoring some handler sub doesnt carry any Perl attribute anymore, add a plain "XSP" Perl attribute.
Perl attributes without the XSP_ prefix cause a warning (actually, sometimes even two, one from Perl and one from SimpleTaglib), as lower-case Perl attributes are reserved for Perl itself.
AxKit2::XSP::SimpleTaglib 1.1 Screenshot
Advertisements
AxKit2::XSP::SimpleTaglib 1.1 Keywords
XSP
AxKit2
SimpleTaglib
SimpleTaglib 1.1
XSP Taglib
Perl
tag
handler
helper
called
TagLib
AxKit2::XSP::SimpleTaglib
AxKit2XSPSimpleTaglib
AxKit2::XSP::SimpleTaglib 1.1
Libraries
Programming
Bookmark AxKit2::XSP::SimpleTaglib 1.1
AxKit2::XSP::SimpleTaglib 1.1 Copyright
WareSeeker periodically updates pricing and software information of AxKit2::XSP::SimpleTaglib 1.1 full version from the publisher, so some information may be slightly out-of-date. You should confirm all information before relying on it. Software piracy is theft, Using crack, password, serial numbers, registration codes, key generators is illegal and prevent future development of AxKit2::XSP::SimpleTaglib 1.1 Edition. Download links are directly from our publisher sites, torrent files or links from rapidshare.com, yousendit.com or megaupload.com are not allowed
Featured Software
Want to place your software product here?
Please contact us for consideration.
Contact WareSeeker.com
Related Information
Related Software
Apache::AxKit::XSP::Language::SimpleTaglib is an alternate XSP taglib helper. Free Download
AxKit2::Plugin is a base class for all plugins. Free Download
AxKit::XSP::ESQL is an Extended SQL taglib for AxKit eXtensible Server Pages. Free Download
AxKit::XSP::WebUtils is a Perl module for utilities for building XSP web apps. Free Download
AxKit::XSP::PerForm is an XSP Taglib for making complex forms easy. Free Download
AxKit::XSP::BasicSession is a session wrapper tag library for AxKit eXtesible Server Pages. Free Download
Audio::TagLib is a library for reading and editing audio meta data, commonly known as tags. Free Download
AxKit2::Transformer::XSP Perl module contains eXtensible Server Pages. Free Download
Latest Software
Popular Software
Favourite Software