add isReferenced function to querry the referenced state