changed the interface for getDevices to return a vector of pairs of platform and devices for that platform that satisfies the criteria