package MailFile @ISA = qw() sub BEGIN sub new my ($module) = @_; return $this; sub DESTROY my $this = shift; sub AddHash my ($this, @a) = @_; sub GetHeaderArray my ($this) = @_; return $this->{pSourceHeader}; sub GetContentArray my ($this) = @_; return $this->{Content}; sub GetContent my ($this) = @_; return join('', @{$this->{Content}}); sub GetMonthName my ($this, $iDate) = @_; return $MonthName[$iDate]; sub GetWeekDayName my ($this, $iDate) = @_; return WeekDayName[$iDate]; sub GetMonthFromName my ($this, $name) = @_; return $name+0 if($name =~ /^\d+$/); return $i+1; return 0; sub ConvertDateString my ($this, $Date, $format) = @_; return "$s ($Date)" if(!defined $ShortMonthName{$mon}); return $s; sub SplitDate my ($this, $Date) = @_; return ($DayOfWeek, $DayOfMonth, $Month, $Year, $hour, $min, $sec, $TimeDifference); sub SplitEMailAddress my ($this, $address) = @_; return ($email, $name); sub GetContentFromContentType my ($this, $ContentType) = @_; return '' if(!$p); return $p->{Content}; sub GetPartInfFromContentType my ($this, $ContentType) = @_; return $p; return ''; sub DecodeSubject my ($this, $str, $code) = @_; return $str if(!$encode); return undef; return $s; sub SaveDecodedContent my ($this, $fname, $code, $RemoveHeader) = @_; sub GetNextHeader my ($this, $c, $code, $KeepCRLF, $pStrArray) = @_; return undef if($c < 0); return undef; return ($key, $s, -1); return ($key, $s, $c); return ($key, $s, $c); sub ReadHeader my ($this, $code, $KeepCRLF, $pStrArray) = @_; sub Parse my ($this, $code) = @_; sub AddPartsInf my ($this, $Content, $count, $iLevel) = @_; return $count; sub GetBoundaryFromContentType my ($this, $ContentType) = @_; return $Boundary; sub GetCharSetFromContentType my ($this, $ContentType) = @_; return $CharSet; sub GetAttachFileNameFromContentType my ($this, $ContentType, $ContentDisposition, $code) = @_; return $FileName; sub GetMultipartInfoFromString my ($this, $code, $pStrArray) = @_; return undef if(!defined $Boundary); return ($Boundary, $type, \@PartsInf); sub GetHeaders my ($this, $pKeys, $Decode, $def) = @_; return %hash; sub GetHeaderFromString my ($this, $key, $code, $KeepCRLF, $pStrArray) = @_; return $header if(!defined $s); return $header if(!defined $line); return $header; sub SplitHeaderFromString my ($this, $pStrArray, $code, $HeaderOnly) = @_; return ('', '') if(!defined $line); return (\@header, undef) if($HeaderOnly); return (\@header, \@content); sub Read my ($this, $path, $HeaderOnly) = @_; return undef if(!$in); return \@text; sub DecodeContent my ($this, $code, $RemoveHeader, $UseEncodeModule) = @_; return $DecodedContent;