Text::Markdown::Discount
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

99 lines
2.0 KiB

package Text::Markdown::PegMarkdown;
use 5.008000;
use strict;
use warnings;
require Exporter;
our @ISA = qw(Exporter);
our %EXPORT_TAGS = ( 'all' => [ qw(
markdown
) ] );
our @EXPORT_OK = ( @{ $EXPORT_TAGS{'all'} } );
our @EXPORT = qw(
);
our $VERSION = '0.01';
require XSLoader;
XSLoader::load('Text::Markdown::PegMarkdown', $VERSION);
sub new {
return bless {}, 'Text::Markdown::PegMarkdown';
}
sub markdown {
my ($self, $text) = @_;
# Detect functional mode, and create an instance for this run..
unless (ref $self) {
if ( $self ne __PACKAGE__ ) {
my $ob = __PACKAGE__->new();
# $self is text, $text is options
return $ob->markdown($self, $text);
}
else {
croak('Calling ' . $self . '->markdown (as a class method) is not supported.');
}
}
return _markdown($text);
}
1;
__END__
# Below is stub documentation for your module. You'd better edit it!
=head1 NAME
Text::Markdown::PegMarkdown - Perl extension for blah blah blah
=head1 SYNOPSIS
use Text::Markdown::PegMarkdown;
blah blah blah
=head1 DESCRIPTION
Stub documentation for Text::Markdown::PegMarkdown, created by h2xs. It looks like the
author of the extension was negligent enough to leave the stub
unedited.
Blah blah blah.
=head2 EXPORT
None by default.
=head1 SEE ALSO
Mention other useful documentation such as the documentation of
related modules or operating system documentation (such as man pages
in UNIX), or any relevant external documentation such as RFCs or
standards.
If you have a mailing list set up for your module, mention it here.
If you have a web site set up for your module, mention it here.
=head1 AUTHOR
Masayoshi Sekimura, E<lt>sekimura@E<gt>
=head1 COPYRIGHT AND LICENSE
Copyright (C) 2009 by Masayoshi Sekimura
This library is free software; you can redistribute it and/or modify
it under the same terms as Perl itself, either Perl version 5.10.0 or,
at your option, any later version of Perl 5 you may have available.
=cut