package rasel.lunar.launcher.model

import android.app.appsearch.StorageInfo
import com.google.gson.annotations.SerializedName
import io.realm.kotlin.ext.realmListOf
import io.realm.kotlin.types.RealmList
import io.realm.kotlin.types.RealmObject
import io.realm.kotlin.types.annotations.Ignore

//class WeatherInfo : RealmObject {
//     constructor()
////     constructor(coord: Loc?, weather: Array<Weather>?, main: Main?) {
////         this.coord = coord
////         weather?.let {
////             this.weather?.addAll(it)
////         }
////
////         this.main = main
////     }
//
//     @SerializedName("coord")
//     var coord: Loc? = null
//
//     @Ignore
//     @SerializedName("weather")
//     var weather: ArrayList<Weather>? = arrayListOf()
//
//     var weathers: RealmList<Weather> = realmListOf()
//
//     @SerializedName("base")
//     var base: String? = null
//
//     @SerializedName("main")
//     var main: Main? = null
//fun filled() {
//    weather?.let {
//        weathers.addAll(it)
//    }
//
//}
//
//     @SerializedName("visibility")
//     var visibility: String? = null
//
//     @SerializedName("wind")
//     var wind: Wind? = null
//
//     @SerializedName("clouds")
//     var clouds: Clouds? = null
//
//     @SerializedName("dt")
//     var dt: String? = null
//
//     @SerializedName("sys")
//     var sys: Sys? = null
//
//     @SerializedName("timezone")
//     var timezone: String? = null
//
//     @SerializedName("id")
//     var id: String? = null
//
//     @SerializedName("name")
//     var name: String? = null
//
//     @SerializedName("cod")
//     var cod: String? = null
// }

class Loc : RealmObject {
    var lon: String? = null
    var lat: String? = null
}

class Weather : RealmObject {
    var id: String? = null
    var main: String? = null
    var description: String? = null
    var icon: String? = null
}

class Main : RealmObject {
    var temp: String? = null
    var feels_like: String? = null
    var temp_min: String? = null
    var temp_max: String? = null
    var pressure: String? = null
    var humidity: String? = null
    var sea_level: String? = null
    var grnd_level: String? = null
}

class Wind: RealmObject {
    var speed: String? = null
    var deg: String? = null
    var gust: String? = null
}

class Clouds: RealmObject {
    var all: String? = null
}

class Sys: RealmObject {
    var type: String? = null
    var id: String? = null
    var country: String? = null
    var sunrise: String? = null
    var sunset: String? = null
}