Chas,

On Wed, Nov 12, 2008 at 12:38 PM, Chas. Owens <[EMAIL PROTECTED]> wrote:
> You may want to also look at Readonly*.

New one for me.  Thanks.

> $WHOIS1 can be modified (not good)

That's an easy point.

> $WHOIS2 cannot be optimized away by the compiler (possible performance impact)

I have no idea what weight to give that optimization. Is it typically
large & very useful, or barely noticeable?

> WHOIS3 cannot be interpolated into strings (annoying)

I stumbled on that problem.  I have been able to work around it by
concatenating,

    "string data" . WHOIS3 . "more string data"

but I'm guessing that's what you mean by "annoying"?

> That said Readonly is a lot more flexible than the
> constant pragma.

More flexibility than just the ability to interpolate into strings?

> the big problem here is that you
> are using a program and then parsing its output.  You should really
> look into using Net::Whois::Proxy or a similar module instead.  Using
> external programs is generally a sign that you are doing something
> wrong (unless the point of the script is to puppet string an external
> utility).

I've just been working with WHOIS because that's what the online
examples/docs were using.  Thought it best to do one thing at a time.

I get your point that there are lots of Perl modules that mimic
programs' functions "in perl".

Still, for some programs, e.g. 'ipset' (which, along with my Shorewall
firewall is the reason I'm getting started with perl in the first
place) there are no available Perl modules (or at least none that I
found yet), so the Question is relevant at least for them.

--JC

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to