How to Install and Uninstall perl-MooseX-Traits Package on openSUSE Leap
Last updated: November 23,2024
1. Install "perl-MooseX-Traits" package
Please follow the steps below to install perl-MooseX-Traits on openSUSE Leap
$
sudo zypper refresh
Copied
$
sudo zypper install
perl-MooseX-Traits
Copied
2. Uninstall "perl-MooseX-Traits" package
Please follow the steps below to uninstall perl-MooseX-Traits on openSUSE Leap:
$
sudo zypper remove
perl-MooseX-Traits
Copied
3. Information about the perl-MooseX-Traits package on openSUSE Leap
Information for package perl-MooseX-Traits:
-------------------------------------------
Repository : Main Repository
Name : perl-MooseX-Traits
Version : 0.13-bp155.2.8
Arch : noarch
Vendor : openSUSE
Installed Size : 36.7 KiB
Installed : No
Status : not installed
Source package : perl-MooseX-Traits-0.13-bp155.2.8.src
Upstream URL : http://search.cpan.org/dist/MooseX-Traits/
Summary : Automatically apply roles at object creation time
Description :
Often you want to create components that can be added to a class
arbitrarily. This module makes it easy for the end user to use these
components. Instead of requiring the user to create a named class with the
desired roles applied, or apply roles to the instance one-by-one, he can
just create a new class from yours with 'with_traits', and then instantiate
that.
There is also 'new_with_traits', which exists for compatibility reasons. It
accepts a 'traits' parameter, creates a new class with those traits, and
then instantiates it.
Class->new_with_traits( traits => [qw/Foo Bar/], foo => 42, bar => 1 )
returns exactly the same object as
Class->with_traits(qw/Foo Bar/)->new( foo => 42, bar => 1 )
would. But you can also store the result of 'with_traits', and call other
methods:
my $c = Class->with_traits(qw/Foo Bar/);
$c->new( foo => 42 );
$c->whatever( foo => 1234 );
And so on.
-------------------------------------------
Repository : Main Repository
Name : perl-MooseX-Traits
Version : 0.13-bp155.2.8
Arch : noarch
Vendor : openSUSE
Installed Size : 36.7 KiB
Installed : No
Status : not installed
Source package : perl-MooseX-Traits-0.13-bp155.2.8.src
Upstream URL : http://search.cpan.org/dist/MooseX-Traits/
Summary : Automatically apply roles at object creation time
Description :
Often you want to create components that can be added to a class
arbitrarily. This module makes it easy for the end user to use these
components. Instead of requiring the user to create a named class with the
desired roles applied, or apply roles to the instance one-by-one, he can
just create a new class from yours with 'with_traits', and then instantiate
that.
There is also 'new_with_traits', which exists for compatibility reasons. It
accepts a 'traits' parameter, creates a new class with those traits, and
then instantiates it.
Class->new_with_traits( traits => [qw/Foo Bar/], foo => 42, bar => 1 )
returns exactly the same object as
Class->with_traits(qw/Foo Bar/)->new( foo => 42, bar => 1 )
would. But you can also store the result of 'with_traits', and call other
methods:
my $c = Class->with_traits(qw/Foo Bar/);
$c->new( foo => 42 );
$c->whatever( foo => 1234 );
And so on.