// GetRegion リージョン 取得
187135
func (p *propZone) GetRegion() *Region {
	if p.Zone == nil {
		return nil
	}
	return p.Zone.GetRegion()
}
1221735
func (s *StackInstance) SetRegion(v string) *StackInstance {
	s.Region = &v
	return s
}
465629
func (c *Config) determineRegion(region string) string {
	// If a resource-level region was not specified, and a provider-level region was set,
	// use the provider-level region.
	if region == "" && c.Region != "" {
		region = c.Region
	}

	log.Printf("[DEBUG] OpenStack Region is: %s", region)
	return region
}
786359
func getRegionForBucket(name string) (string, error) {
	// Any region will work for the region lookup, but the request MUST use
	// PathStyle
	config := aws.NewConfig().WithRegion("us-west-1").WithS3ForcePathStyle(true)
	session := session.New()
	client := s3.New(session, config)
	params := s3.GetBucketLocationInput{
		Bucket: aws.String(name),
	}
	resp, err := client.GetBucketLocation(&params)
	if err != nil {
		return "", fmt.Errorf("failed to get location for bucket '%s', %s", name, err)
	}
	if resp.LocationConstraint == nil {
		// "US Standard", returns an empty region. So return any region in the US
		return "us-east-1", nil
	}
	return *resp.LocationConstraint, nil
}
705121
func (s *EndpointLocation) SetRegion(v string) *EndpointLocation {
	s.Region = &v
	return s
}
1030664
func (s *RdsDbInstance) SetRegion(v string) *RdsDbInstance {
	s.Region = &v
	return s
}
482378
func (s *DescribeReservationOutput) SetRegion(v string) *DescribeReservationOutput {
	s.Region = &v
	return s
}
1225318
func (env *joyentEnviron) Region() (simplestreams.CloudSpec, error) {
	return simplestreams.CloudSpec{
		Region:   env.cloud.Region,
		Endpoint: env.cloud.Endpoint,
	}, nil
}
915790
func (c *RegionCache) getRegionByIDFromCache(regionID uint64) *Region {
	for v, r := range c.mu.regions {
		if v.id == regionID {
			return r.region
		}
	}
	return nil
}
1327698
func (s *Event) SetRegion(v string) *Event {
	s.Region = &v
	return s
}
1260369
func (s *ResourceDataSyncS3Destination) SetRegion(v string) *ResourceDataSyncS3Destination {
	s.Region = &v
	return s
}
717619
func (v *View) GetRegions(key string) (ret []text.Region) {
	v.lock.Lock()
	defer v.lock.Unlock()
	vr := v.regions[key]
	rs := vr.Regions.Regions()
	ret = make([]text.Region, len(rs))
	copy(ret, rs)
	return
}
667603
func (s *ElastiCacheInstanceDetails) SetRegion(v string) *ElastiCacheInstanceDetails {
	s.Region = &v
	return s
}
6938
func (p *propZone) GetRegionID() int64 {
	if p.Zone == nil {
		return -1
	}
	return p.Zone.GetRegionID()
}
1094176
func (s *Service) RegionInfo(ctx context.Context, regionIdentity string) (*Region, error) {
	var region Region
	return &region, s.Get(ctx, &region, fmt.Sprintf("/regions/%v", regionIdentity), nil, nil)
}
1206667
func (e *Environ) Region() (simplestreams.CloudSpec, error) {
	return e.cloudSpec(e.cloud().Region)
}
1247178
func (c *Client) RegionInfo(regionIdentity string) (*Region, error) {
	var region Region
	return &region, c.Get(&region, "/regions/"+regionIdentity)
}