Platon Technologies
not logged in Login Registration
EnglishSlovak
open source software development celebrating 10 years of open source development! Monday, December 9, 2019

File: [Platon] / iotta / Iotta.pm (download)

Revision 1.1.1.1 (vendor branch), Sun Feb 16 15:48:06 2003 UTC (16 years, 9 months ago) by yenar


Changes since 1.1: +0 -0 lines

initial import of iotta into platon cvs

package Iotta;
use strict;
use Carp;

our $AUTOLOAD;

#sub ieval {
#    my $self = shift;
#    my $expr = shift;
#    return eval "$expr";
#}

sub new {
    my $self = {};
    my $proto = shift;
    my $class = ref ($proto) || $proto;
    $self->{type}="";
    #$self->{_public} = 
    bless $self, $class;
    $self->initialize (@_);
    return $self;
}

sub initialize {
}

sub DESTROY {
}

sub AUTOLOAD {
    my $self = shift;
    my $type = ref ($self);
    my $name = $AUTOLOAD;
    my $ex = 0; my $priv = 1;
    my $err;
    $name =~ s/.*://;

    $ex = exists $self->{$name};
    $priv = $name eq "priv";
    if (!$ex || $priv) {
        $err = "cannot access nonexistent object member: $type->$name" unless $ex;
        $err = "cannot access private object member: $type->$name" if $priv;
        print STDERR "error: $err\n";
        my $i = 0;
        while ($i < 128) {
            my @bt = caller ($i);
            my $bt = join (" - ", @bt);
            print STDERR "$bt\n" if $bt;
            $i ++;
        }
        die "Fatal error";
    }

    if (@_)    {
        return $self->{$name} = shift;
    } else {
        return $self->{$name};
    }
}

sub main {
}

1;

Platon Group <platon@platon.org> http://platon.org/
Copyright © 2002-2006 Platon Group
Site powered by Metafox CMS
Go to Top