change function parent node claculation to transformer classes