1 ==============================================================================
2 Release of version 0.77 of Attribute::Handlers
3 ==============================================================================
7 Attribute::Handlers - Simpler definition of attribute handlers
10 This module, when inherited by a package, allows that package's class to
11 define attribute handler subroutines for specific attributes. Variables
12 and subroutines subsequently defined in that package, or in packages
13 derived from that package may be given attributes with the same names as
14 the attribute handler subroutines, which will then be called at the end
15 of the compilation phase (i.e. in a `CHECK' block).
20 use Attribute::Handlers;
23 sub name { return $name{$_[2]}||*{$_[1]}{NAME} }
25 sub Name :ATTR { $name{$_[2]} = $_[4] }
27 sub Purpose :ATTR { print STDERR "Purpose of ", &name, " is $_[4]\n" }
29 sub Unit :ATTR { print STDERR &name, " measured in $_[4]\n" }
34 my $capacity : Name(capacity)
35 : Purpose(to store max storage capacity for files)
40 sub foo : Purpose(to foo all data before barring it) { }
44 Damian Conway (damian@conway.org)
47 Copyright (c) 2001, Damian Conway. All Rights Reserved.
48 This module is free software. It may be used, redistributed
49 and/or modified under the same terms as Perl itself.
52 ==============================================================================
54 0.77 Sat Jun 8 22:58:56 CEST 2002
56 - Since Attribute::Handlers now is core, I will refer to changes
57 with their patch number, please read Porting/repository.pod from
58 your a perl tarball for more information.
60 - Brought up to date with perl 5.8RC1 version
61 will be 5.8 if no more changes come in
63 - [#13686] This changes the behaviour of lexical attributes.
64 Prior to this lexical attributes were done at a compile time,
65 and they would loose their attribute on the next run over them.
66 Now perl 5.8 calls the attribute handler runtime whenever it hits my.
68 - [#14448] Fixes cases with too high refcounts on lexical attributes
70 - [#15945] Do not warn about too late CHECK and INIT block if
71 A::H is pulled in using a require.
74 ==============================================================================
78 Attribute::Handlers has been uploaded to the CPAN
79 and is also available from:
81 http://www.csse.monash.edu.au/~damian/CPAN/Attribute-Handlers.tar.gz
83 ==============================================================================