PurpleWiki::InlineNode Perl module offers inline node object.
SYNOPSIS
use PurpleWiki::InlineNode;
# Create node of type 'text' and content 'Hello, world!'
my $inlineNode1 =
PurpleWiki::InlineNode->new(type => 'text',
content => 'Hello, world!');
# Represent bolded and italicized 'Hello, world!'.
# First, create node of type 'b'.
my $boldNode = PurpleWiki::InlineNode->new(type => 'b');
# Create node of type 'i'.
my $italicsNode = PurpleWiki::InlineNode->new(type => 'i');
# Create 'text' node with content 'Hello, world!'.
my $textNode =
PurpleWiki::InlineNode->new(type => 'text',
content => 'Hello, world!');
# Make 'text' node a child of 'i' node, and 'i' node a child
# of 'b' node.
$italicsNode->children([$textNode]);
$boldNode->children([$italicsNode]);
Inline nodes make up the content of structural nodes. They are mostly content containers, although some types use children to handle nested inline content, such as bold and italicized content.
The data structure looks like:
PurpleWiki::InlineNode = {
type => text|nowiki|b|i|tt|wikiword|freelink|link|url|image
href => string
content => string
children => [PurpleWiki::InlineNode, ...]
}
Product's homepage
Requirements:
· Perl