local-perl-Class-Accessor-0.31-1.noarch.rpm


Advertisement

Description

local-perl-Class-Accessor - Class-Accessor - Automated accessor generation

Property Value
Distribution CentOS 5
Repository End Point i386
Package name local-perl-Class-Accessor
Package version 0.31
Package release 1
Package architecture noarch
Package type rpm
Installed size 59.37 KB
Download size 18.80 KB
Official Mirror packages.endpoint.com
This module automagically generates accessors/mutators for your class.
Most of the time, writing accessors is an exercise in cutting and
pasting.  You usually wind up with a series of methods like this:
sub name {
my $self = shift;
if(@_) {
$self->{name} = $_[0];
}
return $self->{name};
}
sub salary {
my $self = shift;
if(@_) {
$self->{salary} = $_[0];
}
return $self->{salary};
}
One for each piece of data in your object.  While some will be unique,
doing value checks and special storage tricks, most will simply be
exercises in repetition.  Not only is it Bad Style to have a bunch of
repetitious code, but its also simply not lazy, which is the real
tragedy.
If you make your module a subclass of Class::Accessor and declare your
accessor fields with mk_accessors() then you'll find yourself with a
set of automatically generated accessors which can even be
customized!
The basic set up is very simple:
package My::Class;
use base qw(Class::Accessor);
My::Class->mk_accessors( qw(foo bar car) );
Done.  My::Class now has simple foo(), bar() and car() accessors
defined.

Alternatives

Package Version Architecture Repository
local-perl-Class-Accessor-0.31-1.noarch.rpm 0.31 noarch End Point
local-perl-Class-Accessor - - -

Requires

Name Value
local-perl >= 5.00502
local-perl(Carp) -
local-perl(base) -
local-perl(strict) -

Provides

Name Value
local-perl(Class::Accessor) -
local-perl(Class::Accessor::Fast) -
local-perl(Class::Accessor::Faster) -
local-perl-Class-Accessor = 0.31-1

Download

Type URL
Binary Package local-perl-Class-Accessor-0.31-1.noarch.rpm
Source Package local-perl-Class-Accessor-0.31-1.src.rpm

Install Howto

  1. Download latest endpoint-release rpm from https://packages.endpoint.com/rhel/5/os/i386/
  2. Install endpoint-release rpm:
    # rpm -Uvh endpoint-release*rpm
  3. Install local-perl-Class-Accessor rpm package:
    # yum install local-perl-Class-Accessor

Files

Path
/usr/local/lib/perl5/site_perl/5.10.0/Class/Accessor.pm
/usr/local/lib/perl5/site_perl/5.10.0/Class/Accessor/Fast.pm
/usr/local/lib/perl5/site_perl/5.10.0/Class/Accessor/Faster.pm
/usr/local/share/man/man3/Class::Accessor.3pm
/usr/local/share/man/man3/Class::Accessor::Fast.3pm
/usr/local/share/man/man3/Class::Accessor::Faster.3pm
/usr/share/doc/local-perl-Class-Accessor-0.31/Changes
/usr/share/doc/local-perl-Class-Accessor-0.31/INSTALL
/usr/share/doc/local-perl-Class-Accessor-0.31/README
/usr/share/doc/local-perl-Class-Accessor-0.31/examples/benchmark

Changelog

2008-08-07 - rpmbuild-local@sl4-rhel5-build64.endpoint.com
- Initial build.

See Also

Package Description
local-perl-Class-Accessor-Chained-0.01-1.noarch.rpm Class-Accessor-Chained - Perl module
local-perl-Class-Accessor-Grouped-0.10006-1.noarch.rpm Class-Accessor-Grouped - Lets you build groups of accessors
local-perl-Class-Accessor-Grouped-0.10010-1.noarch.rpm Class-Accessor-Grouped - Lets you build groups of accessors
local-perl-Class-Autouse-1.99_02-1.noarch.rpm Class-Autouse - Run-time load a class the first time you call a method in it
local-perl-Class-C3-0.25-1.noarch.rpm Class-C3 - A pragma to use the C3 method resolution order algorithm
local-perl-Class-C3-Componentised-1.001000-1.noarch.rpm Class-C3-Componentised - ins or components to your C3-based class
local-perl-Class-Container-0.12-1.noarch.rpm Class-Container - Perl module
local-perl-Class-Data-Inheritable-0.08-1.noarch.rpm Class-Data-Inheritable - Inheritable, overridable class data
local-perl-Class-ErrorHandler-0.01-2.noarch.rpm Class-ErrorHandler - Perl module
local-perl-Class-Factory-1.06-1.noarch.rpm Class-Factory - Useful base class for factory classes
local-perl-Class-Factory-Util-1.7-1.noarch.rpm Class-Factory-Util - Perl module
local-perl-Class-InsideOut-1.13-1.noarch.rpm Class-InsideOut - a safe, simple inside-out object construction kit
local-perl-Class-Inspector-1.23-2.noarch.rpm Class-Inspector - Get information about a class and its structure
local-perl-Class-Load-0.06-1.noarch.rpm Class-Load - a working (require "Class::Name") and more
local-perl-Class-Loader-2.03-1.noarch.rpm Class-Loader - Load modules and create objects on demand
Advertisement
Advertisement