// Retrieve The solution deployment type.
324739
func (r Product_Package) GetDeploymentType() (resp string, err error) {
	err = r.Session.DoRequest("SoftLayer_Product_Package", "getDeploymentType", nil, &r.Options, &resp)
	return
}
196253
func (r Layout_Container) GetLayoutContainerType() (resp datatypes.Layout_Container_Type, err error) {
	err = r.Session.DoRequest("SoftLayer_Layout_Container", "getLayoutContainerType", nil, &r.Options, &resp)
	return
}
26328
func (dc *DeploymentController) getPodMapForDeployment(d *apps.Deployment, rsList []*apps.ReplicaSet) (map[types.UID]*v1.PodList, error) {
	// Get all Pods that potentially belong to this Deployment.
	selector, err := metav1.LabelSelectorAsSelector(d.Spec.Selector)
	if err != nil {
		return nil, err
	}
	pods, err := dc.podLister.Pods(d.Namespace).List(selector)
	if err != nil {
		return nil, err
	}
	// Group Pods by their controller (if it's in rsList).
	podMap := make(map[types.UID]*v1.PodList, len(rsList))
	for _, rs := range rsList {
		podMap[rs.UID] = &v1.PodList{}
	}
	for _, pod := range pods {
		// Do not ignore inactive Pods because Recreate Deployments need to verify that no
		// Pods from older versions are running before spinning up new Pods.
		controllerRef := metav1.GetControllerOf(pod)
		if controllerRef == nil {
			continue
		}
		// Only append if we care about this UID.
		if podList, ok := podMap[controllerRef.UID]; ok {
			podList.Items = append(podList.Items, *pod)
		}
	}
	return podMap, nil
}
1272248
func (s *RepositoriesService) GetDeploymentStatus(ctx context.Context, owner, repo string, deploymentID, deploymentStatusID int64) (*DeploymentStatus, *Response, error) {
	u := fmt.Sprintf("repos/%v/%v/deployments/%v/statuses/%v", owner, repo, deploymentID, deploymentStatusID)

	req, err := s.client.NewRequest("GET", u, nil)
	if err != nil {
		return nil, nil, err
	}

	// TODO: remove custom Accept headers when APIs fully launch.
	acceptHeaders := []string{mediaTypeDeploymentStatusPreview, mediaTypeExpandDeploymentStatusPreview}
	req.Header.Set("Accept", strings.Join(acceptHeaders, ", "))

	d := new(DeploymentStatus)
	resp, err := s.client.Do(ctx, req, d)
	if err != nil {
		return nil, resp, err
	}

	return d, resp, nil
}
408697
func (c *CloudPersister) GetTerrainType(id int64) (*types.TerrainType, error) {
	ctx := context.Background()
	k := datastore.NewKey(ctx, "TerrainType", "", id, nil)
	TerrainType := &types.TerrainType{}
	if err := c.DatastoreClient().Get(ctx, k, TerrainType); err != nil {
		return nil, fmt.Errorf("datastoredb: could not get TerrainType: %v", err)
	}
	TerrainType.ID = id
	return TerrainType, nil
}
371720
func (p *Plugin) GetTypes() []types.PluginInterfaceType {
	p.mu.RLock()
	defer p.mu.RUnlock()

	return p.PluginObj.Config.Interface.Types
}
524807
func (n *managedNode) GetSoftwareVersion() (string, error) {
	n.RLock()
	defer n.RUnlock()
	ctx, _ := context.WithTimeout(context.Background(), DEFAULT_CTX_TIMEOUT)
	version, err := n.client.SoftwareVersion(ctx, &cc.EmptyMsg{})
	return version.Version, err
}
1054865
func Convert_apps_DeploymentConfigList_To_v1_DeploymentConfigList(in *apps.DeploymentConfigList, out *v1.DeploymentConfigList, s conversion.Scope) error {
	return autoConvert_apps_DeploymentConfigList_To_v1_DeploymentConfigList(in, out, s)
}
367235
func (r *Resource) getResourceType(resourceTypes map[string]ResourceType) (*ResourceType, error) {
	// check if it's specify a resource type to inherit
	if r.Type == nil || r.Type.Name == "" {
		return nil, nil
	}

	// get resource type from array of resource type map
	for k, rt := range resourceTypes {
		if k == r.Type.Name {
			return &rt, nil
		}
	}
	return nil, fmt.Errorf("can't find resource type named :%v", r.Type.Name)
}
951668
func (r Network_DirectLink_Location) GetServiceType() (resp datatypes.Network_DirectLink_ServiceType, err error) {
	err = r.Session.DoRequest("SoftLayer_Network_DirectLink_Location", "getServiceType", nil, &r.Options, &resp)
	return
}
357745
func (c *Client) GetDeployments() ([]Deployment, error) {
	r := c.NewRequest("GET", "/deployments")
	resp, err := c.DoRequest(r)

	if err != nil {
		log.Printf("Error requesting deployments  %v", err)
		return nil, err
	}
	defer resp.Body.Close()

	resBody, err := ioutil.ReadAll(resp.Body)
	if err != nil {
		log.Printf("Error reading deployments request %v", resBody)
		return nil, err
	}
	deployments := []Deployment{}
	err = json.Unmarshal(resBody, &deployments)
	if err != nil {
		log.Printf("Error unmarshaling deployments %v", err)
	}
	return deployments, err
}
1201044
func (r FlexibleCredit_Program) GetCompanyTypes() (resp []datatypes.FlexibleCredit_Company_Type, err error) {
	err = r.Session.DoRequest("SoftLayer_FlexibleCredit_Program", "getCompanyTypes", nil, &r.Options, &resp)
	return
}
93672
func (d *dataSet) GetDeploymentConfig(controller *corev1.ReplicationController) (*appsv1.DeploymentConfig, bool, error) {
	name := appsutil.DeploymentConfigNameFor(controller)
	if len(name) == 0 {
		return nil, false, nil
	}

	var deploymentConfig *appsv1.DeploymentConfig
	key := &appsv1.DeploymentConfig{ObjectMeta: metav1.ObjectMeta{Name: name, Namespace: controller.Namespace}}
	item, exists, err := d.deploymentConfigStore.Get(key)
	if exists {
		deploymentConfig = item.(*appsv1.DeploymentConfig)
	}
	return deploymentConfig, exists, err
}
314668
func (c *CloudPersister) GetAttackType(id int64) (*types.AttackType, error) {
	ctx := context.Background()
	k := datastore.NewKey(ctx, "AttackType", "", id, nil)
	AttackType := &types.AttackType{}
	if err := c.DatastoreClient().Get(ctx, k, AttackType); err != nil {
		return nil, fmt.Errorf("datastoredb: could not get AttackType: %v", err)
	}
	AttackType.ID = id
	return AttackType, nil
}
170982
func (r Scale_Policy_Trigger_ResourceUse) GetType() (resp datatypes.Scale_Policy_Trigger_Type, err error) {
	err = r.Session.DoRequest("SoftLayer_Scale_Policy_Trigger_ResourceUse", "getType", nil, &r.Options, &resp)
	return
}
226985
func (d *Deployment) GetEnvironment() string {
	if d == nil || d.Environment == nil {
		return ""
	}
	return *d.Environment
}
541537
func (r Account_Link_Bluemix) GetSupportTierType() (resp string, err error) {
	err = r.Session.DoRequest("SoftLayer_Account_Link_Bluemix", "getSupportTierType", nil, &r.Options, &resp)
	return
}