added getParent method