// GetLocation returns the path and hash of the browsers location api else panics if not in a browser
5055
func GetLocation() (string, string) {
	panicBrowserDetect()
	loc := js.Global.Get("location")
	path := loc.Get("pathname").String()
	hash := loc.Get("hash").String()
	return path, hash
}
1186638
func (p *V2) GetLocations() ([]common.Location, error) {
	p.RLock()
	defer p.RUnlock()
	if len(p.locations) == 0 {
		return nil, common.ErrNotFound
	}
	locations := make([]common.Location, len(p.locations))
	i := 0
	for _, location := range p.locations {
		locations[i] = location
		i++
	}

	return locations, nil
}
293992
func (s *CommentsForPullRequest) SetLocation(v *Location) *CommentsForPullRequest {
	s.Location = v
	return s
}
1224206
func (s *CreateFieldLevelEncryptionProfileOutput) SetLocation(v string) *CreateFieldLevelEncryptionProfileOutput {
	s.Location = &v
	return s
}
31295
func GetLocationByName(sess *session.Session, name string, args ...interface{}) (datatypes.Location, error) {
	var mask string
	if len(args) > 0 {
		mask = args[0].(string)
	}

	locs, err := services.GetLocationService(sess).
		Mask(mask).
		Filter(filter.New(filter.Path("name").Eq(name)).Build()).
		GetDatacenters()

	if err != nil {
		return datatypes.Location{}, err
	}

	// An empty filtered result set does not raise an error
	if len(locs) == 0 {
		return datatypes.Location{}, fmt.Errorf("No locations found with name of %s", name)
	}

	return locs[0], nil
}
404584
func (c *Context) GetUniformLocation(program *js.Object, name string) *js.Object {
	return c.Call("getUniformLocation", program, name)
}
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
}
407143
func (o *LocationOptions) getParameters() (params map[string]string, err error) {
	params = make(map[string]string)

	// location is a required field
	if o.Location == "" {
		return params, errors.New("to perform a location based search, the location property must contain an area within to search.  For coordinate based searches, use the CoordinateOption class")
	}
	params["location"] = o.Location

	// if coordinates are specified add those to the parameters hash
	if o.CoordinateOptions != nil &&
		o.CoordinateOptions.Latitude.Valid &&
		o.CoordinateOptions.Longitude.Valid {
		params["cll"] = fmt.Sprintf("%v,%v", o.CoordinateOptions.Latitude.Float64, o.CoordinateOptions.Longitude.Float64)
	}

	return params, nil
}
1054035
func GetLocation(n ast.Node, ctx *Context) (string, int) {
	fobj := ctx.FileSet.File(n.Pos())
	return fobj.Name(), fobj.Line(n.Pos())
}
812275
func (bam BlockAddressMap) Get(loc BlockLocation) string {
	if bam[loc.FileIndex] == nil {
		return ""
	}
	return bam[loc.FileIndex][loc.BlockIndex]
}
976842
func (e *Error) Location() (file string, line int) {
	return e.file, e.line
}
274419
func (_m *Protocol) GetLocation(id string) (common.Location, error) {
	ret := _m.Called(id)

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

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

	return r0, r1
}
27341
func (bi *BinaryInfo) Location(entry reader.Entry, attr dwarf.Attr, pc uint64, regs op.DwarfRegisters) (int64, []op.Piece, string, error) {
	instr, descr, err := bi.locationExpr(entry, attr, pc)
	if err != nil {
		return 0, nil, "", err
	}
	addr, pieces, err := op.ExecuteStackProgram(regs, instr)
	return addr, pieces, descr, err
}
151441
func (c Client) GetBucketLocation(bucketName string) (string, error) {
	if err := s3utils.CheckValidBucketName(bucketName); err != nil {
		return "", err
	}
	return c.getBucketLocation(bucketName)
}
1182183
func (d *failureDetail) Location() (string, int, string) {
	return d.fileName, d.lineNumber, d.funcName
}
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
}
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
}