// Retrieve The bandwidth allotment type of this virtual rack.
424646
func (r Network_Bandwidth_Version1_Allotment) GetBandwidthAllotmentType() (resp datatypes.Network_Bandwidth_Version1_Allotment_Type, err error) {
	err = r.Session.DoRequest("SoftLayer_Network_Bandwidth_Version1_Allotment", "getBandwidthAllotmentType", nil, &r.Options, &resp)
	return
}
338652
func (vm *VM) getVirtualNetworkClient() (virtualnetwork.VirtualNetworkClient, error) {
	c, err := vm.getClient()
	if err != nil {
		return virtualnetwork.VirtualNetworkClient{}, err
	}

	return virtualnetwork.NewClient(c), nil
}
160420
func (r Virtual_Storage_Repository) GetType() (resp datatypes.Virtual_Storage_Repository_Type, err error) {
	err = r.Session.DoRequest("SoftLayer_Virtual_Storage_Repository", "getType", nil, &r.Options, &resp)
	return
}
1275294
func (r Network_Component) GetInterface() (resp datatypes.Network_Bandwidth_Version1_Interface, err error) {
	err = r.Session.DoRequest("SoftLayer_Network_Component", "getInterface", nil, &r.Options, &resp)
	return
}
455362
func (r Security_Certificate) GetLoadBalancerVirtualIpAddresses() (resp []datatypes.Network_Application_Delivery_Controller_LoadBalancer_VirtualIpAddress, err error) {
	err = r.Session.DoRequest("SoftLayer_Security_Certificate", "getLoadBalancerVirtualIpAddresses", nil, &r.Options, &resp)
	return
}
312287
func GetVolumeFSType(v api.Volume) (policy.FSType, error) {
	switch {
	case v.HostPath != nil:
		return policy.HostPath, nil
	case v.EmptyDir != nil:
		return policy.EmptyDir, nil
	case v.GCEPersistentDisk != nil:
		return policy.GCEPersistentDisk, nil
	case v.AWSElasticBlockStore != nil:
		return policy.AWSElasticBlockStore, nil
	case v.GitRepo != nil:
		return policy.GitRepo, nil
	case v.Secret != nil:
		return policy.Secret, nil
	case v.NFS != nil:
		return policy.NFS, nil
	case v.ISCSI != nil:
		return policy.ISCSI, nil
	case v.Glusterfs != nil:
		return policy.Glusterfs, nil
	case v.PersistentVolumeClaim != nil:
		return policy.PersistentVolumeClaim, nil
	case v.RBD != nil:
		return policy.RBD, nil
	case v.FlexVolume != nil:
		return policy.FlexVolume, nil
	case v.Cinder != nil:
		return policy.Cinder, nil
	case v.CephFS != nil:
		return policy.CephFS, nil
	case v.Flocker != nil:
		return policy.Flocker, nil
	case v.DownwardAPI != nil:
		return policy.DownwardAPI, nil
	case v.FC != nil:
		return policy.FC, nil
	case v.AzureFile != nil:
		return policy.AzureFile, nil
	case v.ConfigMap != nil:
		return policy.ConfigMap, nil
	case v.VsphereVolume != nil:
		return policy.VsphereVolume, nil
	case v.Quobyte != nil:
		return policy.Quobyte, nil
	case v.AzureDisk != nil:
		return policy.AzureDisk, nil
	case v.PhotonPersistentDisk != nil:
		return policy.PhotonPersistentDisk, nil
	case v.StorageOS != nil:
		return policy.StorageOS, nil
	case v.Projected != nil:
		return policy.Projected, nil
	case v.PortworxVolume != nil:
		return policy.PortworxVolume, nil
	case v.ScaleIO != nil:
		return policy.ScaleIO, nil
	case v.CSI != nil:
		return policy.CSI, nil
	}

	return "", fmt.Errorf("unknown volume type for volume: %#v", v)
}
91160
func (r Scale_LoadBalancer) GetRoutingType() (resp datatypes.Network_Application_Delivery_Controller_LoadBalancer_Routing_Type, err error) {
	err = r.Session.DoRequest("SoftLayer_Scale_LoadBalancer", "getRoutingType", nil, &r.Options, &resp)
	return
}
340711
func (r Billing_Item) GetBandwidthAllocation() (resp datatypes.Network_Bandwidth_Version1_Allocation, err error) {
	err = r.Session.DoRequest("SoftLayer_Billing_Item", "getBandwidthAllocation", nil, &r.Options, &resp)
	return
}
651781
func (r Network_Bandwidth_Version1_Allotment) ReassignServers(templateObjects []datatypes.Hardware, newAllotmentId *int) (resp bool, err error) {
	params := []interface{}{
		templateObjects,
		newAllotmentId,
	}
	err = r.Session.DoRequest("SoftLayer_Network_Bandwidth_Version1_Allotment", "reassignServers", params, &r.Options, &resp)
	return
}
961855
func (r Hardware_Component_Model) GetType() (resp string, err error) {
	err = r.Session.DoRequest("SoftLayer_Hardware_Component_Model", "getType", nil, &r.Options, &resp)
	return
}
1322367
func (r Virtual_Guest) GetType() (resp datatypes.Virtual_Guest_Type, err error) {
	err = r.Session.DoRequest("SoftLayer_Virtual_Guest", "getType", nil, &r.Options, &resp)
	return
}
885142
func (r Network_Vlan) GetType() (resp datatypes.Network_Vlan_Type, err error) {
	err = r.Session.DoRequest("SoftLayer_Network_Vlan", "getType", nil, &r.Options, &resp)
	return
}
711582
func getDiskManager(disk *VirtualDisk, diskOperation string) VirtualDiskProvider {
	var diskProvider VirtualDiskProvider
	switch diskOperation {
	case VirtualDiskDeleteOperation:
		diskProvider = virtualDiskManager{disk.DiskPath, disk.VolumeOptions}
	case VirtualDiskCreateOperation:
		if disk.VolumeOptions.StoragePolicyName != "" || disk.VolumeOptions.VSANStorageProfileData != "" || disk.VolumeOptions.StoragePolicyID != "" {
			diskProvider = vmDiskManager{disk.DiskPath, disk.VolumeOptions, disk.VMOptions}
		} else {
			diskProvider = virtualDiskManager{disk.DiskPath, disk.VolumeOptions}
		}
	}
	return diskProvider
}
92862
func getTenantFromContainerInspect(containerInfo *types.ContainerJSON) string {
	tenant := "default"
	if containerInfo != nil && containerInfo.NetworkSettings != nil {
		for network := range containerInfo.NetworkSettings.Networks {
			if strings.Contains(network, "/") {
				//network name is of the form networkname/tenantname for non default tenant
				tenant = strings.Split(network, "/")[1]
			}
		}
	}
	return tenant
}
1325091
func (r Network_LoadBalancer_Global_Account) GetLoadBalanceType() (resp datatypes.Network_LoadBalancer_Global_Type, err error) {
	err = r.Session.DoRequest("SoftLayer_Network_LoadBalancer_Global_Account", "getLoadBalanceType", nil, &r.Options, &resp)
	return
}
993037
func GetAllType(err error, v interface{}) []error {
	var result []error

	var search string
	if v != nil {
		search = reflect.TypeOf(v).String()
	}
	Walk(err, func(err error) {
		var needle string
		if err != nil {
			needle = reflect.TypeOf(err).String()
		}

		if needle == search {
			result = append(result, err)
		}
	})

	return result
}
63980
func (_class VMPPClass) GetBackupType(sessionID SessionRef, self VMPPRef) (_retval VmppBackupType, _err error) {
	_method := "VMPP.get_backup_type"
	_sessionIDArg, _err := convertSessionRefToXen(fmt.Sprintf("%s(%s)", _method, "session_id"), sessionID)
	if _err != nil {
		return
	}
	_selfArg, _err := convertVMPPRefToXen(fmt.Sprintf("%s(%s)", _method, "self"), self)
	if _err != nil {
		return
	}
	_result, _err := _class.client.APICall(_method, _sessionIDArg, _selfArg)
	if _err != nil {
		return
	}
	_retval, _err = convertEnumVmppBackupTypeToGo(_method + " -> ", _result.Value)
	return
}