functions for constraints into own trait