| 1 | package Pod::Markdown::Passthrough; | ||
| 2 | 2 | ▶ | use 5.008001; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 3 | 2 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 4 | 2 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 5 | |||
| 6 | 2 | ▶ | use base 'Pod::Markdown'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | |||
| 8 | 2 | our $VERSION = "0.01"; | |
| 9 | |||
| 10 | 1 | ▶ | sub new { |
|
Subroutine
new: called CC=1 SCAR=0.0
Pod
documented
| |||
| 11 | 1 | my $class = shift; | |
| 12 | |||
| 13 | 1 | bless {}, $class; | |
| 14 | } | ||
| 15 | |||
| 16 | # Read the contents of a file and stash in object. | ||
| 17 | 1 | ▶ | sub parse_from_file { |
|
Subroutine
parse_from_file: called CC=1 SCAR=0.0
Pod
documented
| |||
| 18 | 1 | my $self = shift; | |
| 19 | 1 | my $file = shift; | |
| 20 | |||
| 21 | 1 | $self->{_markdown} = do { local ( @ARGV, $/ ) = $file; <> }; | |
| 22 | |||
| 23 | } | ||
| 24 | |||
| 25 | # Return any stashed raw file content. | ||
| 26 | 1 | ▶ | sub as_markdown { |
|
Subroutine
as_markdown: called CC=1 SCAR=0.0
Pod
documented
| |||
| 27 | 1 | my $self = shift; | |
| 28 | |||
| 29 | 1 | return $self->{_markdown}; | |
| 30 | |||
| 31 | } | ||
| 32 | |||
| 33 | 2 | 1; | |
| 34 | __END__ | ||