Searching within the hash values of an array of hashes
am 26.08.2007 06:18:20 von usenetI have an array of hashes that looks like this:
my @media = (
{
'Name' => 'foo'
'Format' => 'mp3',
},
{
'Name' => 'bar'
'Format' => 'ogg',
},
{
'Name' => 'baz'
'Format' => 'wav',
},
);
I want to know if I have any ogg formatted media. If this was a plain
hash then it would be simple to grep the values. Is there a way I can
do something simple like this on this AoH so I don't have to use a for
loop or something to iterate over the array?
Thanks!
--
David Filmer (http://DavidFilmer.com)