Main > Free Download Search >

Free blatte software for linux

blatte

Sponsored Links
Sponsored Links
Sort by >> Relevance
rss
Secleted [ 0 ] software to compare
Results 1 - 15 of about 6
Blatte 0.9.4

Blatte 0.9.4


Blatte is a Perl module with text macro/markup/template language. more>>
Blatte is a Perl module with text macro/markup/template language.

SYNOPSIS

use Blatte;
use Blatte::Builtins;

my $perl = &Blatte::Parse(...some Blatte program ...);
if (defined($perl)) {
my $result = eval $perl;
if (defined($result)) {
&Blatte::traverse($result, &callback);
} elsif ($@) {
...handle execution error...
}
} else {
...handle parsing error...
}

Blatte is a very powerful text markup and transformation language with a very simple syntax. A Blatte document can be translated into a Perl program that, when executed, produces a transformed version of the input document.

This module itself contains some utility functions for handling Blatte documents, described below in the FUNCTIONS section. However, writers of Blatte-based software will generally be more interested in other associated modules. See in particular Blatte::Compiler (for processing files full of Blatte code) and Blatte::Builtins (for a description of the Blatte languages intrinsic functions).

Most casual end users will probably be interested in Blattes ability to serve as a higher-level language for writing web pages. This requires the additional CPAN package Blatte::HTML.

Most of the remainder of this document describes the syntax and semantics of the Blatte language.

<<less
Download (0.031MB)
Added: 2007-05-14 License: GPL (GNU General Public License) Price:
893 downloads
Blatte::HTML 0.9

Blatte::HTML 0.9


Blatte::HTML is a Perl module that contains tools for generating HTML with Blatte. more>>
Blatte::HTML is a Perl module that contains tools for generating HTML with Blatte.

SYNOPSIS

use Blatte;
use Blatte::Builtins;
use Blatte::HTML;

$perl = &Blatte::Parse(...string of Blatte code...);
$val = eval $perl;
&Blatte::HTML::render($val, &emit);

sub emit {
print shift;
}

<<less
Download (0.014MB)
Added: 2007-04-20 License: Perl Artistic License Price:
917 downloads
Blatte::Ws 0.9.4

Blatte::Ws 0.9.4


Blatte::Ws is a whitespace wrapper for Blatte objects. more>>
Blatte::Ws is a whitespace wrapper for Blatte objects.

SYNOPSIS

You probably dont want to use this module directly. Instead, use the ws functions (wrapws, unwrapws, wsof) in Blatte.pm.

Blatte objects are frequently nested inside of whitespace objects, representing the whitespace that preceded the object on input, or that should precede the object on output. The outermost whitespace wrapper takes precedence.

<<less
Download (0.031MB)
Added: 2007-04-20 License: GPL (GNU General Public License) Price:
917 downloads
Blatte::Parser 0.9.4

Blatte::Parser 0.9.4


Blatte::Parser is a Perl module that contains a parser for Blatte syntax. more>>
Blatte::Parser is a Perl module that contains a parser for Blatte syntax.

SYNOPSIS

use Blatte::Parser;

$parser = new Blatte::Parser();

$perl_expr = $parser->parse(INPUT);

or

$parsed_expr = $parser->expr(INPUT);
if (defined($parsed_expr)) {
$perl_expr = $parsed_expr->transform();
}

METHODS

$parser->parse(INPUT)

Parses the first Blatte expression in INPUT and returns the corresponding Perl string, or undef if an error occurred.

INPUT may be a string or a reference to a string. If its the latter, then after a successful parse, the parsed expression will be removed from the beginning of the string.

$parser->expr(INPUT)

Like parse(), except the result is not converted to Perl; its left in Blattes internal parse-tree format, which uses the Blatte::Syntax family of objects.

$parser->eof(INPUT)

Tests INPUT for end-of-file. Leading whitespace is removed from INPUT with consume_whitespace and, if nothing remains, true is returned, else undef.

<<less
Download (0.031MB)
Added: 2007-04-20 License: Perl Artistic License Price:
917 downloads
Blatte::Builtins 0.9.4

Blatte::Builtins 0.9.4


Blatte::Builtins is a Perl module with Blatte-callable intrinsics. more>>
Blatte::Builtins is a Perl module with Blatte-callable intrinsics.

SYNOPSIS

package MyPackage;

use Blatte::Builtins;

eval(...compiled Blatte program...);

This module defines the standard Blatte-callable intrinsic functions.

A Blatte intrinsic is simply a Perl subroutine that (a) has been assigned (by reference) to a scalar variable (whose name begins with a letter), and (b) takes a hash reference as its first argument, in which named parameter values are passed.

<<less
Download (0.031MB)
Added: 2007-04-19 License: Perl Artistic License Price:
918 downloads
Blatte::Compiler 0.9.4

Blatte::Compiler 0.9.4


Blatte::Compiler is a Perl module to compile a Blatte document into Perl. more>>
Blatte::Compiler is a Perl module to compile a Blatte document into Perl.

SYNOPSIS

use Blatte::Compiler;

&Blatte::Compiler::compile($file_handle, &callback);

&Blatte::Compiler::compile_sparse($file_handle, &callback);

sub callback {
my($val, $src) = @_;

if (defined($src)) {
...Blatte expression...
} else {
...plain text...
}
}

This is a convenient interface for parsing a file full of Blatte code. A file handle and a callback are passed to compile() or compile_sparse() (see below for the difference between the two). The callback is then invoked for each top-level item parsed from the input.

The compile() function treats its entire input as a sequence of Blatte expressions, including plain text at the top level, which is divided up into Blatte "words," each of which is one Blatte expression. The callback is called once for each expression, with two arguments: the Perl string resulting from parsing the Blatte expression; and the Blatte source string itself.

The compile_sparse() function works the same way, except that plain text at the top-level of the input is not divided into words. Only Blatte expressions beginning with a Blatte metacharacter are parsed as described above. All text in between such expressions is passed as a single string to the callback, with no second argument.

<<less
Download (0.031MB)
Added: 2007-04-20 License: Perl Artistic License Price:
917 downloads
Secleted [ 0 ] software to compare
  • Page: 1 of 1
  • 1