City
Represents a city with geographic and administrative details.
Attributes:
Name | Type | Description |
---|---|---|
id |
str
|
The unique identifier for the city. |
name |
str
|
The name of the city. |
ibge_code |
str
|
The IBGE code associated with the city. |
isopleth |
int
|
The isopleth value indicating a specific attribute of the city. |
latitude |
float
|
The latitude coordinate of the city. |
longitude |
float
|
The longitude coordinate of the city. |
from_dict(data)
classmethod
Creates a City instance from a dictionary.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
data |
dict
|
A dictionary containing city details. |
required |
Returns:
Name | Type | Description |
---|---|---|
City |
City
|
A new City instance with attributes populated from the dictionary. |