| 1 | package Aut::Base64; | ||
| 2 | |||
| 3 | # $Id: Base64.pm,v 1.2 2004/04/08 16:55:13 cvs Exp $ | ||
| 4 | |||
| 5 | 1 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 6 | 1 | ▶ | use MIME::Base64; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | |||
| 8 | 1 | ▶ | sub new { |
|
Subroutine
new: called CC=1 SCAR=0.0
Pod
documented
| |||
| 9 | 1 | my $class=shift; | |
| 10 | 1 | my $self; | |
| 11 | |||
| 12 | 1 | $self->{"base64"}=1; | |
| 13 | 1 | bless $self,$class; | |
| 14 | |||
| 15 | 1 | return $self; | |
| 16 | } | ||
| 17 | |||
| 18 | 0 | ▶ | sub encode { |
|
Subroutine
encode: not called CC=1 SCAR=6.9
Pod
documented
| |||
| 19 | 0 | my $self=shift; | |
| 20 | 0 | my $text=shift; | |
| 21 | 0 | $text=encode_base64($text); | |
| 22 | 0 | chomp $text; | |
| 23 | 0 | return $text; | |
| 24 | } | ||
| 25 | |||
| 26 | 0 | ▶ | sub decode { |
|
Subroutine
decode: not called CC=1 SCAR=6.9
Pod
documented
| |||
| 27 | 0 | my $self=shift; | |
| 28 | 0 | my $text=shift; | |
| 29 | 0 | return decode_base64($text); | |
| 30 | } | ||
| 31 | |||
| 32 | 1 | 1; | |
| 33 | __END__ | ||