Class::MixinFactory::InsideOutAttr(3pm)

Class::MixinFactory::InsideOutAttr3pm

Method maker for inside out data

Usage

  package My::Class;
  use Class::MixinFactory::InsideOutAttr qw( foo bar baz );
  sub new { ... } 
  package main;
  My::Class->foo( 'Foozle' );
  print My::Class->foo();
  my $object = My::Class->new();
  $object->foo( 'Bolix' );
  print $object->foo();

Overview

A simple method maker with opaque data storage.

Usage

To generate accessor methods for your class, use this package and pass the desired method names to the use or import statement.

Generates get/set accessor methods which can store values for a class or its instances. Each method stores the values associated with various objects in an hash keyed by the object's stringified identity.

Destruction

A DESTROY method is installed to remove data for expired objects from the storage hash. (If the DESTROY method is not called, your program will not release this data and memory will be wasted.)

If you implement your own DESTROY method, it should also call "Class::MixinFactory::InsideOutAttr::destroy($self)".

Releases

8 releases since Debian 6.0 (Squeeze); the text changed 3 times.

  1. 6.0–9
  2. 10
  3. 11
  4. 12–13

From libclass-mixinfactory-perl 0.92-5 in Debian 13 (Trixie). Parsed by carta from the page's man source.