type SetFunc … func GenNetworkPolicy(fn ...SetFunc) *networkingv1.NetworkPolicy { … } func GenNetworkPolicyWithNameAndPodMatchLabel(name string, targetLabels map[string]string, otherFunc ...SetFunc) *networkingv1.NetworkPolicy { … } func GenNetworkPolicyWithNameAndPodSelector(name string, targetSelector metav1.LabelSelector, otherFunc ...SetFunc) *networkingv1.NetworkPolicy { … } func SetObjectMetaName(name string) SetFunc { … } func SetGenerateName(name string) SetFunc { … } func SetObjectMetaLabel(targetLabels map[string]string) SetFunc { … } func SetSpecPodSelector(targetSelector metav1.LabelSelector) SetFunc { … } func SetSpecPodSelectorMatchLabels(targetLabels map[string]string) SetFunc { … } func SetSpecIngressRules(rules ...networkingv1.NetworkPolicyIngressRule) SetFunc { … } func SetSpecEgressRules(rules ...networkingv1.NetworkPolicyEgressRule) SetFunc { … }