code: func PodMatchesTermsNamespaceAndSelector(pod *v1.Pod, namespaces sets.String, selector labels.Selector) bool {
  	if !namespaces.Has(pod.Namespace) {
  		return false
  	}
  
  	if !selector.Matches(labels.Set(pod.Labels)) {
  		return false
  	}
  	return true
  }
docs: // PodMatchesTermsNamespaceAndSelector returns true if the given <pod>
  // matches the namespace and selector defined by <affinityPod>`s <term>.