Agent-TCLI
view release on metacpan or search on metacpan
lib/Agent/TCLI/Command.pm view on Meta::CPAN
=cut
sub Aliases {
my ($self, $context_hash_key) = @_;
$self->Verbose("Aliases: context_hash_key dump",3,$context_hash_key);
my @aliases;
if ( ref( $context_hash_key ) =~ /ARRAY/ )
{
# There is a list of aliases to add.
push( @aliases , @{$context_hash_key} );
# %aliases = map { $_ => $self } @{$context_hash_key} };
}
elsif ( ref( $context_hash_key ) =~ /HASH/ )
{
# There are context shifts to add.
foreach my $key (keys %{$context_hash_key} )
{
push( @aliases , $key ) unless ( $key =~ qr(\*U) );
}
# %aliases = map { $_ => $self } keys %{$context_hash_key};
}
else
{
# There is a single alias to add.
push( @aliases , $context_hash_key );
# %aliases = ( $context_hash_key => $self );
}
return (\@aliases);
} # End Aliases
( run in 0.226 second using v1.01-cache-2.11-cpan-65fba6d93b7 )