Created namecomparator class