perl-embperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gerald Richter" <rich...@ecos.de>
Subject Re: eval and Execute and subs
Date Wed, 19 Mar 2003 20:01:15 GMT


> HTML::EmbperlObject
>
> $obj = Execute({ object => $file });
> try {
> $obj->foo();
> } otherwise {
> $this->Error(0); # $this is the ref to this page object
> handle error
> };
>
> This doesn't work.  The page still returns with an error value, and
> my handler in the EmbperlObject template sees the error and handles
> it internally.
>

You could try to place a

$@='' ;

inside of the otherwise part.

>
> On a slightly different topic.  { object => $file, isa => $otherfile
> } did not do what I expected.  I thought it would make $file a
> subclass of $otherfile, but  it does not seem to.  I had to do an
> Execute({ isa => $otherfile }) in each of the subroutines in $file.

Yes, this comination is not support (or does a differnt thing), also it
would be usefull.

I think I will add this at some point in to 2.0

Gerald


--------------------------------------------------------------
Gerald Richter     ecos electronic communication services gmbh
IT-Securitylösungen * dynamische Webapplikationen * Consulting

Post:       Tulpenstrasse 5          D-55276 Dienheim b. Mainz
E-Mail:     richter@ecos.de          Voice:   +49 6133 939-122
WWW:        http://www.ecos.de/      Fax:     +49 6133 939-333
--------------------------------------------------------------
|
|   Besuchen Sie uns auf der CeBIT vom 12. - 19. März 2003
|   Messe Hannover * Halle 17 * Stand F 36
|   http://www.cebit.de/
|
+-------------------------------------------------------------


---------------------------------------------------------------------
To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org
For additional commands, e-mail: embperl-help@perl.apache.org


Mime
View raw message