RE: Perl OO
by Charles K. Clarkson other posts by this author
Sep 29 2004 3:25PM messages near this date
view in the new Beta List Site
RE: Perl OO
|
Re: [Distutils] Add RPM-friendly Record Option
In separate messages, Bharucha, Nikhil <NBharucha@[...].com> top-posted:
: [snip]
: sub send
: {
: my $self = shift;
: print "\nIn send self is $self";
: my $process;
: $process = $self-> writePrefs();
: $process = $self-> batchTransmitter("+XMIT");
: }
: [snip]
Methods that return values should do so specifically.
sub send
{
my $self = shift;
print "In send self is $self\n";
my $process = $self-> writePrefs();
return $self-> batchTransmitter( '+XMIT' );
}
Which illustrates $process is unnecessary.
sub send
{
my $self = shift;
print "In send self is $self\n";
$self-> writePrefs();
return $self-> batchTransmitter("+XMIT");
}
: I forgot, the following error occurs when strict is used "Can't
: use string ("Transmitter") as a HASH ref while "strict refs" in
: use at"
: use ISO::Transmitter;
: [snip]
: .
: .
: .
: [snip]
: $process = Transmitter-> new(%transmitterArgs);
: $process = Transmitter-> send();
That should probably be:
use ISO::Transmitter;
[snip]
.
.
.
[snip]
$process = ISO::Transmitter-> new(%transmitterArgs);
$process = $process-> send();
Additionally, Transmitter.pm should be located in the
"ISO" directory.
HTH,
Charles K. Clarkson
--
Mobile Homes Specialist
254 968-8328
_______________________________________________
Perl-Win32-Users mailing list
Perl-Win32-Users@[...].com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Thread:
Bharucha, Nikhil
Charles K. Clarkson
|