finished node, rel and entity casting functions