func BaseFromReference(client *govmomi.Client, ref types.ManagedObjectReference) (BaseComputeResource, error) {
	switch ref.Type {
	case "ComputeResource":
		return StandaloneFromID(client, ref.Value)
	case "ClusterComputeResource":
		return StandaloneFromID(client, ref.Value)
	}
	return nil, fmt.Errorf("unknown object type %s", ref.Type)
}
func BaseFromReference(client *govmomi.Client, ref types.ManagedObjectReference) (BaseComputeResource, error) {
	switch ref.Type {
	case "ComputeResource":
		return StandaloneFromID(client, ref.Value)
	case "ClusterComputeResource":
		return StandaloneFromID(client, ref.Value)
	}
	return nil, fmt.Errorf("unknown object type %s", ref.Type)
}
func BaseFromReference ( client * govmomi . Client , ref types . ManagedObjectReference ) ( BaseComputeResource , error ) { switch ref . Type { case " " : return StandaloneFromID ( client , ref . Value ) case " " : return StandaloneFromID ( client , ref . Value ) } return nil , fmt . Errorf ( " " , ref . Type ) }
// BaseFromReference returns a BaseComputeResource for a given managed object
// reference.
BaseFromReference returns a BaseComputeResource for a given managed object reference .