// GetLocation returns the Location field if it's non-nil, zero value otherwise.
497505
func (o *Organization) GetLocation() string {
	if o == nil || o.Location == nil {
		return ""
	}
	return *o.Location
}
371231
func (s *Interconnect) SetLocation(v string) *Interconnect {
	s.Location = &v
	return s
}
505152
func getLocation() (*Data, error) {
	response, err := http.Get(URL)
	if err != nil {
		return nil, err
	}
	defer response.Body.Close()
	r := &Data{}
	if err = json.NewDecoder(response.Body).Decode(&r); err != nil {
		return nil, err
	}
	return r, nil
}
984679
func (s *VirtualInterface) SetLocation(v string) *VirtualInterface {
	s.Location = &v
	return s
}
170946
func (lm *locCache) getLoc(name string) (*time.Location, error) {
	if name == "System" {
		return time.Local, nil
	}
	lm.RLock()
	v, ok := lm.locMap[name]
	lm.RUnlock()
	if ok {
		return v, nil
	}

	if loc, err := time.LoadLocation(name); err == nil {
		// assign value back to map
		lm.Lock()
		lm.locMap[name] = loc
		lm.Unlock()
		return loc, nil
	}

	return nil, fmt.Errorf("invalid name for timezone %s", name)
}
1144922
func (r *bucketLocationCache) Get(bucketName string) (location string, ok bool) {
	r.RLock()
	defer r.RUnlock()
	location, ok = r.items[bucketName]
	return
}
1009859
func (s *CreateVaultOutput) SetLocation(v string) *CreateVaultOutput {
	s.Location = &v
	return s
}
334665
func (s *CreateConnectionInput) SetLocation(v string) *CreateConnectionInput {
	s.Location = &v
	return s
}
658865
func (_m *Protocol) GetLocations() ([]common.Location, error) {
	ret := _m.Called()

	var r0 []common.Location
	if rf, ok := ret.Get(0).(func() []common.Location); ok {
		r0 = rf()
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]common.Location)
		}
	}

	var r1 error
	if rf, ok := ret.Get(1).(func() error); ok {
		r1 = rf()
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}
1365161
func (s *PostCommentForComparedCommitInput) SetLocation(v *Location) *PostCommentForComparedCommitInput {
	s.Location = v
	return s
}
526516
func (s *CreateInterconnectInput) SetLocation(v string) *CreateInterconnectInput {
	s.Location = &v
	return s
}
938662
func (h *HereError) Location() string {
	lastSlash := strings.LastIndex(h.loc, "/")
	secondLastSlash := strings.LastIndex(h.loc[:lastSlash], "/")

	return h.loc[secondLastSlash+1:]
}
1058171
func (gi *GeoIP) GetLocationByIPNum(ipNum uint32) *Location {
	// Perform the lookup on the database to see if the record is found
	offset := gi.lookupByIPNum(ipNum)

	// Check if the country was found
	if gi.dbType == dbCountryEdition && offset-countryBegin == 0 ||
		gi.dbType != dbCountryEdition && gi.databaseSegment == offset {
		return nil
	}

	// Create a generic location structure
	location := new(Location)

	// If the database is country
	if gi.dbType == dbCountryEdition {
		location.CountryCode = countryCode[offset-countryBegin]
		location.CountryName = countryName[offset-countryBegin]

		return location
	}

	// Find the max record length
	recPointer := offset + (2*gi.recordLength-1)*gi.databaseSegment
	recordEnd := recPointer + fullRecordLength
	if len(gi.data)-recPointer < fullRecordLength {
		recordEnd = len(gi.data)
	}

	// Read the country code/name first
	location.CountryCode = countryCode[gi.data[recPointer]]
	location.CountryName = countryName[gi.data[recPointer]]
	readLen := 1
	recPointer += 1

	// Get the region
	for readLen = 0; gi.data[recPointer+readLen] != '\000' &&
		recPointer+readLen < recordEnd; readLen++ {
	}
	if readLen != 0 {
		location.Region = string(gi.data[recPointer : recPointer+readLen])
	}
	recPointer += readLen + 1

	// Get the city
	for readLen = 0; gi.data[recPointer+readLen] != '\000' &&
		recPointer+readLen < recordEnd; readLen++ {
	}
	if readLen != 0 {
		location.City = string(gi.data[recPointer : recPointer+readLen])
	}
	recPointer += readLen + 1

	// Get the postal code
	for readLen = 0; gi.data[recPointer+readLen] != '\000' &&
		recPointer+readLen < recordEnd; readLen++ {
	}
	if readLen != 0 {
		location.PostalCode = string(gi.data[recPointer : recPointer+readLen])
	}
	recPointer += readLen + 1

	// Get the latitude
	coordinate := float32(0)
	for j := 0; j < 3; j++ {
		coordinate += float32(int32(gi.data[recPointer+j]) << uint8(j*8))
	}
	location.Latitude = float32(coordinate/10000 - 180)
	recPointer += 3

	// Get the longitude
	coordinate = 0
	for j := 0; j < 3; j++ {
		coordinate += float32(int32(gi.data[recPointer+j]) << uint8(j*8))
	}
	location.Longitude = float32(coordinate/10000 - 180)

	return location
}
84376
func (s *GetIPSetOutput) SetLocation(v string) *GetIPSetOutput {
	s.Location = &v
	return s
}
96170
func (t *Tab) GetElementByLocation(x, y int) (*Element, error) {
	_, nodeId, err := t.DOM.GetNodeForLocation(x, y, false)
	if err != nil {
		return nil, err
	}
	ele, _ := t.GetElementByNodeId(nodeId)
	return ele, nil
}
346090
func (s *BuildArtifacts) SetLocation(v string) *BuildArtifacts {
	s.Location = &v
	return s
}
548446
func (s *CreateInvalidationOutput) SetLocation(v string) *CreateInvalidationOutput {
	s.Location = &v
	return s
}