combined set/clear functions