Mic::ArrayImpl
package Example::ArrayImps::HashSet; use Mic::ArrayImpl has => { set => { default => sub { {} } } }, ; sub has { my ($self, $e) = @_; exists $self->[ $SET ]{$e}; } sub add { my ($self, $e) = @_; ++$self->[ $SET ]{$e}; } 1;
Mic::ArrayImpl can be used to create implementations based on blessed array refs (which may be desirable due to having faster access and less memory usage compared to hash based objects).
Mic::ArrayImpl is used in the same way as Mic::Implementation, the only difference being that the former creates array based objects.
To install Mic, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Mic
CPAN shell
perl -MCPAN -e shell install Mic
For more information on module installation, please visit the detailed CPAN module installation guide.