Class: Google::Apis::JobsV2::JobLocation
- Inherits:
-
Object
- Object
- Google::Apis::JobsV2::JobLocation
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/jobs_v2/classes.rb,
generated/google/apis/jobs_v2/representations.rb,
generated/google/apis/jobs_v2/representations.rb
Overview
Output only. A resource that represents a location with full geographic information.
Instance Attribute Summary collapse
-
#lat_lng ⇒ Google::Apis::JobsV2::LatLng
An object representing a latitude/longitude pair.
-
#location_type ⇒ String
The type of a location, which corresponds to the address lines field of PostalAddress.
-
#postal_address ⇒ Google::Apis::JobsV2::PostalAddress
Represents a postal address, e.g.
-
#radius_meters ⇒ Float
Radius in meters of the job location.
Instance Method Summary collapse
-
#initialize(**args) ⇒ JobLocation
constructor
A new instance of JobLocation.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ JobLocation
Returns a new instance of JobLocation
2239 2240 2241 |
# File 'generated/google/apis/jobs_v2/classes.rb', line 2239 def initialize(**args) update!(**args) end |
Instance Attribute Details
#lat_lng ⇒ Google::Apis::JobsV2::LatLng
An object representing a latitude/longitude pair. This is expressed as a pair
of doubles representing degrees latitude and degrees longitude. Unless
specified otherwise, this must conform to the
WGS84
standard. Values must be within normalized ranges.
Corresponds to the JSON property latLng
2202 2203 2204 |
# File 'generated/google/apis/jobs_v2/classes.rb', line 2202 def lat_lng @lat_lng end |
#location_type ⇒ String
The type of a location, which corresponds to the address lines field of
PostalAddress. For example, "Downtown, Atlanta, GA, USA" has a type of
LocationType#NEIGHBORHOOD, and "Kansas City, KS, USA" has a type of
LocationType#LOCALITY.
Corresponds to the JSON property locationType
2210 2211 2212 |
# File 'generated/google/apis/jobs_v2/classes.rb', line 2210 def location_type @location_type end |
#postal_address ⇒ Google::Apis::JobsV2::PostalAddress
Represents a postal address, e.g. for postal delivery or payments addresses. Given a postal address, a postal service can deliver items to a premise, P.O. Box or similar. It is not intended to model geographical locations (roads, towns, mountains). In typical usage an address would be created via user input or from importing existing data, depending on the type of process. Advice on address input / editing:
- Use an i18n-ready address widget such as https://github.com/googlei18n/libaddressinput)
- Users should not be presented with UI elements for input or editing of
fields outside countries where that field is used.
For more guidance on how to use this schema, please see:
https://support.google.com/business/answer/6397478
Corresponds to the JSON property
postalAddress
2228 2229 2230 |
# File 'generated/google/apis/jobs_v2/classes.rb', line 2228 def postal_address @postal_address end |
#radius_meters ⇒ Float
Radius in meters of the job location. This value is derived from the
location bounding box in which a circle with the specified radius
centered from LatLng coves the area associated with the job location.
For example, currently, "Mountain View, CA, USA" has a radius of
7885.79 meters.
Corresponds to the JSON property radiusMeters
2237 2238 2239 |
# File 'generated/google/apis/jobs_v2/classes.rb', line 2237 def radius_meters @radius_meters end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
2244 2245 2246 2247 2248 2249 |
# File 'generated/google/apis/jobs_v2/classes.rb', line 2244 def update!(**args) @lat_lng = args[:lat_lng] if args.key?(:lat_lng) @location_type = args[:location_type] if args.key?(:location_type) @postal_address = args[:postal_address] if args.key?(:postal_address) @radius_meters = args[:radius_meters] if args.key?(:radius_meters) end |