move implementation details out of templat'ized container code