Skip to content

Commit 22d22d5

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 3211ca1b of spec repo
1 parent f09b11b commit 22d22d5

File tree

3 files changed

+47
-16
lines changed

3 files changed

+47
-16
lines changed

.apigentools-info

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"spec_versions": {
55
"v1": {
66
"apigentools_version": "1.6.6",
7-
"regenerated": "2025-06-26 17:56:17.204143",
8-
"spec_repo_commit": "76086f13"
7+
"regenerated": "2025-06-26 21:05:34.194849",
8+
"spec_repo_commit": "3211ca1b"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2025-06-26 17:56:17.219918",
13-
"spec_repo_commit": "76086f13"
12+
"regenerated": "2025-06-26 21:05:34.211477",
13+
"spec_repo_commit": "3211ca1b"
1414
}
1515
}
1616
}

.generator/schemas/v1/openapi.yaml

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3439,13 +3439,28 @@ components:
34393439
example:
34403440
focus: WORLD
34413441
properties:
3442+
custom_extent:
3443+
description: A custom extent of the map defined by an array of four numbers
3444+
in the order `[minLongitude, minLatitude, maxLongitude, maxLatitude]`.
3445+
Mutually exclusive with `focus`.
3446+
example:
3447+
- -30
3448+
- -40
3449+
- 40
3450+
- 30
3451+
items:
3452+
description: The longitudinal or latitudinal coordinates of the bounding
3453+
box.
3454+
format: double
3455+
type: number
3456+
maxItems: 4
3457+
minItems: 4
3458+
type: array
34423459
focus:
34433460
description: The 2-letter ISO code of a country to focus the map on. Or
3444-
`WORLD`.
3461+
`WORLD`. Mutually exclusive with `custom_extent`.
34453462
example: WORLD
34463463
type: string
3447-
required:
3448-
- focus
34493464
type: object
34503465
GeomapWidgetRequest:
34513466
description: An updated geomap widget.

lib/datadog_api_client/v1/models/geomap_widget_definition_view.rb

Lines changed: 25 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,19 @@ module DatadogAPIClient::V1
2121
class GeomapWidgetDefinitionView
2222
include BaseGenericModel
2323

24-
# The 2-letter ISO code of a country to focus the map on. Or `WORLD`.
25-
attr_reader :focus
24+
# A custom extent of the map defined by an array of four numbers in the order `[minLongitude, minLatitude, maxLongitude, maxLatitude]`. Mutually exclusive with `focus`.
25+
attr_reader :custom_extent
26+
27+
# The 2-letter ISO code of a country to focus the map on. Or `WORLD`. Mutually exclusive with `custom_extent`.
28+
attr_accessor :focus
2629

2730
attr_accessor :additional_properties
2831

2932
# Attribute mapping from ruby-style variable name to JSON key.
3033
# @!visibility private
3134
def self.attribute_map
3235
{
36+
:'custom_extent' => :'custom_extent',
3337
:'focus' => :'focus'
3438
}
3539
end
@@ -38,6 +42,7 @@ def self.attribute_map
3842
# @!visibility private
3943
def self.openapi_types
4044
{
45+
:'custom_extent' => :'Array<Float>',
4146
:'focus' => :'String'
4247
}
4348
end
@@ -60,6 +65,12 @@ def initialize(attributes = {})
6065
end
6166
}
6267

68+
if attributes.key?(:'custom_extent')
69+
if (value = attributes[:'custom_extent']).is_a?(Array)
70+
self.custom_extent = value
71+
end
72+
end
73+
6374
if attributes.key?(:'focus')
6475
self.focus = attributes[:'focus']
6576
end
@@ -69,18 +80,22 @@ def initialize(attributes = {})
6980
# @return true if the model is valid
7081
# @!visibility private
7182
def valid?
72-
return false if @focus.nil?
83+
return false if !@custom_extent.nil? && @custom_extent.length > 4
84+
return false if !@custom_extent.nil? && @custom_extent.length < 4
7385
true
7486
end
7587

7688
# Custom attribute writer method with validation
77-
# @param focus [Object] Object to be assigned
89+
# @param custom_extent [Object] Object to be assigned
7890
# @!visibility private
79-
def focus=(focus)
80-
if focus.nil?
81-
fail ArgumentError, 'invalid value for "focus", focus cannot be nil.'
91+
def custom_extent=(custom_extent)
92+
if !custom_extent.nil? && custom_extent.length > 4
93+
fail ArgumentError, 'invalid value for "custom_extent", number of items must be less than or equal to 4.'
94+
end
95+
if !custom_extent.nil? && custom_extent.length < 4
96+
fail ArgumentError, 'invalid value for "custom_extent", number of items must be greater than or equal to 4.'
8297
end
83-
@focus = focus
98+
@custom_extent = custom_extent
8499
end
85100

86101
# Returns the object in the form of hash, with additionalProperties support.
@@ -109,6 +124,7 @@ def to_hash
109124
def ==(o)
110125
return true if self.equal?(o)
111126
self.class == o.class &&
127+
custom_extent == o.custom_extent &&
112128
focus == o.focus &&
113129
additional_properties == o.additional_properties
114130
end
@@ -117,7 +133,7 @@ def ==(o)
117133
# @return [Integer] Hash code
118134
# @!visibility private
119135
def hash
120-
[focus, additional_properties].hash
136+
[custom_extent, focus, additional_properties].hash
121137
end
122138
end
123139
end

0 commit comments

Comments
 (0)