Basic HTML version of Foils prepared Sept 20 97

Foil 55 tie() and untie() Perl Functions - I

From Perl5 and Advanced Perl4 Features Computational Science for Information Age Course CPS616 -- Sept 20 97. by Geoffrey C. Fox,Nancy McCracken,Tom Scavo


1 tie() and untie() are described in PerlTIE Man Page
2 These generate "enchanted" variables ( magical blessing!) which allows one to access what seems to be an ordinary variables in a Perl Program but behind the scenes, the implementation of variable dioes a lot of work which could include computation, data access etc.
3 Examples in PerlTIE include:
4 tie a scalar $priority which returns process or user priority by accessing UNIX system
5 tie a hash to a database so that
6 $tiedhash{lookupkey} returns value of lookupkey in database
7 This latter tie is most powerful and could involve SQL access to the database sever when tied hash accessed

in Table To:


© Northeast Parallel Architectures Center, Syracuse University, npac@npac.syr.edu

If you have any comments about this server, send e-mail to webmaster@npac.syr.edu.

Page produced by wwwfoil on Sun Apr 5 1998