a method and apparatus adapted to perform content addressable memory lookup by performing a lookup in parallel using multiple classification rules in the cam with the same key , wherein the cam lookup is used to resolve ipv4 and ipv6 addresses .