~ubuntu-branches/debian/sid/libembperl-perl/sid

« back to all changes in this revision

Viewing changes to Embperl/Module.pm

  • Committer: Bazaar Package Importer
  • Author(s): Angus Lees
  • Date: 2004-02-15 14:23:39 UTC
  • Revision ID: james.westby@ubuntu.com-20040215142339-n21gqf7mx9tmyb8d
Tags: upstream-2.0b10
ImportĀ upstreamĀ versionĀ 2.0b10

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
###################################################################################
 
2
#
 
3
#   Embperl - Copyright (c) 1997-2004 Gerald Richter / ECOS
 
4
#
 
5
#   You may distribute under the terms of either the GNU General Public
 
6
#   License or the Artistic License, as specified in the Perl README file.
 
7
#
 
8
#   THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
 
9
#   IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
 
10
#   WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
 
11
#
 
12
#   $Id: Module.pm,v 1.31 2004/01/23 06:50:56 richter Exp $
 
13
#
 
14
###################################################################################
 
15
 
 
16
 
 
17
 
 
18
package Embperl::Module ;
 
19
 
 
20
use Embperl ;
 
21
 
 
22
 
 
23
$VERSION = '0.01_dev-1';
 
24
 
 
25
 
 
26
# define subs
 
27
 
 
28
sub init
 
29
    {
 
30
    local $/ = undef ;
 
31
    my $hdl  = shift ;
 
32
    my $data = <$hdl> ;
 
33
 
 
34
    # compile page
 
35
 
 
36
    Embperl::Execute ({'inputfile' => __FILE__, 
 
37
                            'input' => \$data,
 
38
                            'mtime' => -M __FILE__ ,
 
39
                            'import' => 0,
 
40
                            'options' => Embperl::optKeepSrcInMemory,
 
41
                            'package' => __PACKAGE__}) ;
 
42
 
 
43
 
 
44
    }
 
45
 
 
46
# import subs
 
47
 
 
48
sub import
 
49
 
 
50
    {
 
51
    Embperl::Execute ({'inputfile' => __FILE__, 
 
52
                            'import' => 2,
 
53
                            'package' => __PACKAGE__}) ;
 
54
 
 
55
 
 
56
    1 ;
 
57
    }
 
58
 
 
59
 
 
60
 
 
61
1 ;