vsphere/internal/helper/clustercomputeresource/cluster_compute_resource_helper.go
func IsMember(cluster *object.ClusterComputeResource, host *object.HostSystem) (bool, error) {
	hprops, err := hostsystem.Properties(host)
	if err != nil {
		return false, fmt.Errorf("error getting properties for cluster %q: %s", host.Name(), err)
	}
	if hprops.Parent == nil {
		return false, nil
	}
	if *hprops.Parent != cluster.Reference() {
		return false, nil
	}
	return true, nil
}
func IsMember(cluster *object.ClusterComputeResource, host *object.HostSystem) (bool, error) {
	hprops, err := hostsystem.Properties(host)
	if err != nil {
		return false, fmt.Errorf("error getting properties for cluster %q: %s", host.Name(), err)
	}
	if hprops.Parent == nil {
		return false, nil
	}
	if *hprops.Parent != cluster.Reference() {
		return false, nil
	}
	return true, nil
}
func IsMember ( cluster * object . ClusterComputeResource , host * object . HostSystem ) ( bool , error ) { hprops , err := hostsystem . Properties ( host ) if err != nil { return false , fmt . Errorf ( " " , host . Name ( ) , err ) } if hprops . Parent == nil { return false , nil } if * hprops . Parent != cluster . Reference ( ) { return false , nil } return true , nil }
// IsMember checks to see if a host is a member of the compute cluster
// in question.
//
// This is a pretty basic operation that checks that the parent of the
// compute is the ClusterComputeResource.
IsMember checks to see if a host is a member of the compute cluster in question . This is a pretty basic operation that checks that the parent of the compute is the ClusterComputeResource .