// GetTotalMilestones returns the TotalMilestones field if it's non-nil, zero value otherwise.
332818
func (m *MilestoneStats) GetTotalMilestones() int {
	if m == nil || m.TotalMilestones == nil {
		return 0
	}
	return *m.TotalMilestones
}
13503
func (c *Client) GetBareMetalPlans() ([]BareMetalPlan, error) {
	var bareMetalPlanMap map[string]BareMetalPlan
	if err := c.get(`plans/list_baremetal`, &bareMetalPlanMap); err != nil {
		return nil, err
	}

	var b bareMetalPlans
	for _, bareMetalPlan := range bareMetalPlanMap {
		b = append(b, bareMetalPlan)
	}

	sort.Sort(bareMetalPlans(b))
	return b, nil
}
47533
func (r Billing_Currency_ExchangeRate) GetAllCurrencyExchangeRates(stringDate *string) (resp []datatypes.Billing_Currency_ExchangeRate, err error) {
	params := []interface{}{
		stringDate,
	}
	err = r.Session.DoRequest("SoftLayer_Billing_Currency_ExchangeRate", "getAllCurrencyExchangeRates", params, &r.Options, &resp)
	return
}
1285272
func (t *Tombstoner) HasTombstones() bool {
	files := t.TombstoneFiles()
	t.mu.RLock()
	n := len(t.tombstones)
	t.mu.RUnlock()

	return len(files) > 0 && files[0].Size > 0 || n > 0
}
637110
func (s *RegisterContainerInstanceInput) SetTotalResources(v []*Resource) *RegisterContainerInstanceInput {
	s.TotalResources = v
	return s
}
396723
func (o *OrgStats) GetTotalOrgs() int {
	if o == nil || o.TotalOrgs == nil {
		return 0
	}
	return *o.TotalOrgs
}
530162
func (c *CommentStats) GetTotalIssueComments() int {
	if c == nil || c.TotalIssueComments == nil {
		return 0
	}
	return *c.TotalIssueComments
}
1340769
func getTotalMem() int64 {
	pagesize := C.sysconf(C._SC_PAGESIZE)
	npages := C.sysconf(C._SC_PHYS_PAGES)
	return int64(pagesize * npages)
}
327405
func (d *downloader) getTotalBytes() int64 {
	d.m.Lock()
	defer d.m.Unlock()

	return d.totalBytes
}
192463
func GetMilestones(repoID int64, page int, isClosed bool) ([]*Milestone, error) {
	miles := make([]*Milestone, 0, setting.UI.IssuePagingNum)
	sess := x.Where("repo_id = ? AND is_closed = ?", repoID, isClosed)
	if page > 0 {
		sess = sess.Limit(setting.UI.IssuePagingNum, (page-1)*setting.UI.IssuePagingNum)
	}
	return miles, sess.Find(&miles)
}
1028819
func (m *Milestone) GetOpenIssues() int {
	if m == nil || m.OpenIssues == nil {
		return 0
	}
	return *m.OpenIssues
}
379171
func (d *Dataset) GetTotalSize() int64 {
	if d.Meta.TotalSize >= 0 {
		return d.Meta.TotalSize
	}
	var currentDatasetTotalSize int64
	for _, ds := range d.Step.InputDatasets {
		currentDatasetTotalSize += ds.GetTotalSize()
	}
	d.Meta.TotalSize = currentDatasetTotalSize
	return currentDatasetTotalSize
}
725499
func (api artistApi) GetTopTracks(args map[string]interface{}) (result ArtistGetTopTracks, err error) {
	defer func() { appendCaller(err, "lastfm.Artist.GetTopTracks") }()
	err = callGet("artist.gettoptracks", api.params, args, &result, P{
		"plain": []string{"artist", "mbid", "autocorrect", "page", "limit"},
	})
	return
}
365007
func (r *SearchRequest) TrackTotalHits(trackTotalHits interface{}) *SearchRequest {
	r.searchSource = r.searchSource.TrackTotalHits(trackTotalHits)
	return r
}
481102
func (api userApi) GetTopAlbums(args map[string]interface{}) (result UserGetTopAlbums, err error) {
	defer func() { appendCaller(err, "lastfm.User.GetTopAlbums") }()
	err = callGet("user.gettopalbums", api.params, args, &result, P{
		"plain": []string{"user", "period", "limit", "page"},
	})
	return
}
359468
func (s *Storage) GetTotalCount() int64 {
	count := atomic.LoadInt64(&s.stat.TotalCount)

	return count
}
346857
func (c Client) getTotalMultipartSize(bucketName, objectName, uploadID string) (size int64, err error) {
	// Iterate over all parts and aggregate the size.
	partsInfo, err := c.listObjectParts(bucketName, objectName, uploadID)
	if err != nil {
		return 0, err
	}
	for _, partInfo := range partsInfo {
		size += partInfo.Size
	}
	return size, nil
}