Files
weatherapi/internal/adapters/outbound/postgres/forecast_rows.go
Eric Rakestraw 78dc7817e9
All checks were successful
ci/woodpecker/push/build-image Pipeline was successful
Simplified the forecast schema and removed fields deprecated upstream in weatherfeeder
2026-03-26 21:35:39 -05:00

47 lines
1.6 KiB
Go

// forecast_rows.go defines row DTOs for forecast reads.
// Layer: adapters/outbound/postgres forecast feature.
package postgres
import (
"database/sql"
"time"
)
type forecastParentRow struct {
EventID string
LocationID sql.NullString
LocationName sql.NullString
IssuedAt time.Time
UpdatedAt sql.NullTime
Product string
Latitude sql.NullFloat64
Longitude sql.NullFloat64
ElevationMeters sql.NullFloat64
}
type forecastPeriodRow struct {
PeriodIndex int
StartTime time.Time
EndTime time.Time
Name sql.NullString
IsDay sql.NullBool
ConditionCode int
TextDescription sql.NullString
TemperatureC sql.NullFloat64
TemperatureCMin sql.NullFloat64
TemperatureCMax sql.NullFloat64
DewpointC sql.NullFloat64
RelativeHumidityPercent sql.NullFloat64
WindDirectionDegrees sql.NullFloat64
WindSpeedKmh sql.NullFloat64
WindGustKmh sql.NullFloat64
BarometricPressurePa sql.NullFloat64
VisibilityMeters sql.NullFloat64
ApparentTemperatureC sql.NullFloat64
CloudCoverPercent sql.NullFloat64
ProbabilityOfPrecipitationPercent sql.NullFloat64
PrecipitationAmountMM sql.NullFloat64
SnowfallDepthMM sql.NullFloat64
UVIndex sql.NullFloat64
}