Added queue class with "scan" method