NAME
MooseX::Clone::Meta::Attribute::Trait::NoClone - A trait for attrs that should not be copied while cloning.
SYNOPSIS
with qw(MooseX::Clone);
has _some_special_thingy => (
traits => [qw(NoClone)],
);
DESCRIPTION
Sometimes certain values should not be carried over when cloning an object.
This attribute trait implements just that.
METHODS
- clone_value
-
If the
init_argparam is set (that means an explicit value was given toclone) sets the attribute to that value.Otherwise calls
clear_valueandinitialize_instance_slot.