Changed Pair to a new class TupleData that can accept a type querry