Name : perl-Class-Roles
| |
Version : 0.300.0
| Vendor : obs://build_opensuse_org/devel:languages:perl
|
Release : 1.4
| Date : 2011-05-03 08:17:19
|
Group : Unspecified
| Source RPM : perl-Class-Roles-0.300.0-1.4.src.rpm
|
Size : 0.01 MB
| |
Packager : (none)
| |
Summary : Use Perl 6 roles in Perl 5
|
Description :
Class::Roles provides a Perl 5 implementation of Perl 6 roles.
Roles are named collections of reusable behavior. They provide a mechanism to mark that a class performs certain behaviors and to reuse the code that performs those behaviors.
Polymorphism is a fundamental feature of object orientation. It\'s important that behaviors that are similar in a semantic sense but different in specific details can be abstracted behind the same name. A dog may sleep by turning in circles three times then lying down while a cat may sprawl out across the nearest human lap. Both sleep, however.
Allomorphism -- polymorphic equivalence -- is a lesser-known feature. This suggests that objects with compatible behavior should be able to be treated interchangeably. A \'Dog\' and a \'Lifeguard\' may both understand the \'rescue_drowning_swimmer\' message, not because they share a common ancestor class but because they share a role.
|
RPM found in directory: /packages/linux-pbone/ftp5.gwdg.de/pub/opensuse/repositories/devel:/languages:/perl/openSUSE_Tumbleweed/noarch |