Add __hash__ method to Content classes.