Commit 64065d75 by Demid Merzlyakov

IOS-75: Merge branch 'modules' into develop

# Conflicts:
#	DelayedSaveStorage/DelayedSaveStorage/DelayedSaveStorage.swift
parents e0ecac46 d1a4e63c
This source diff could not be displayed because it is too large. You can view the blob instead.
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<Scheme <Scheme
LastUpgradeVersion = "1240" LastUpgradeVersion = "1250"
version = "1.3"> version = "1.3">
<BuildAction <BuildAction
parallelizeBuildables = "YES" parallelizeBuildables = "YES"
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
<key>OneWeatherNotificationServiceExtension.xcscheme_^#shared#^_</key> <key>OneWeatherNotificationServiceExtension.xcscheme_^#shared#^_</key>
<dict> <dict>
<key>orderHint</key> <key>orderHint</key>
<integer>41</integer> <integer>55</integer>
</dict> </dict>
<key>PG (Playground) 1.xcscheme</key> <key>PG (Playground) 1.xcscheme</key>
<dict> <dict>
......
...@@ -2,6 +2,24 @@ ...@@ -2,6 +2,24 @@
<Workspace <Workspace
version = "1.0"> version = "1.0">
<FileRef <FileRef
location = "group:DelayedSaveStorage/DelayedSaveStorage.xcodeproj">
</FileRef>
<FileRef
location = "group:CoreDataStorage/CoreDataStorage.xcodeproj">
</FileRef>
<FileRef
location = "group:BlendFIPS/BlendFIPSSource.xcodeproj">
</FileRef>
<FileRef
location = "group:BlendHealthSource/BlendHealthSource.xcodeproj">
</FileRef>
<FileRef
location = "group:WDTWeatherSource/WDTWeatherSource.xcodeproj">
</FileRef>
<FileRef
location = "group:OneWeatherCore/OneWeatherCore.xcodeproj">
</FileRef>
<FileRef
location = "group:1Weather.xcodeproj"> location = "group:1Weather.xcodeproj">
</FileRef> </FileRef>
<FileRef <FileRef
......
...@@ -9,49 +9,49 @@ ...@@ -9,49 +9,49 @@
<key>isShown</key> <key>isShown</key>
<false/> <false/>
<key>orderHint</key> <key>orderHint</key>
<integer>4</integer> <integer>56</integer>
</dict> </dict>
<key>PG (Playground) 2.xcscheme</key> <key>PG (Playground) 2.xcscheme</key>
<dict> <dict>
<key>isShown</key> <key>isShown</key>
<false/> <false/>
<key>orderHint</key> <key>orderHint</key>
<integer>6</integer> <integer>57</integer>
</dict> </dict>
<key>PG (Playground) 3.xcscheme</key> <key>PG (Playground) 3.xcscheme</key>
<dict> <dict>
<key>isShown</key> <key>isShown</key>
<false/> <false/>
<key>orderHint</key> <key>orderHint</key>
<integer>7</integer> <integer>58</integer>
</dict> </dict>
<key>PG (Playground) 4.xcscheme</key> <key>PG (Playground) 4.xcscheme</key>
<dict> <dict>
<key>isShown</key> <key>isShown</key>
<false/> <false/>
<key>orderHint</key> <key>orderHint</key>
<integer>10</integer> <integer>46</integer>
</dict> </dict>
<key>PG (Playground) 5.xcscheme</key> <key>PG (Playground) 5.xcscheme</key>
<dict> <dict>
<key>isShown</key> <key>isShown</key>
<false/> <false/>
<key>orderHint</key> <key>orderHint</key>
<integer>11</integer> <integer>47</integer>
</dict> </dict>
<key>PG (Playground) 6.xcscheme</key> <key>PG (Playground) 6.xcscheme</key>
<dict> <dict>
<key>isShown</key> <key>isShown</key>
<false/> <false/>
<key>orderHint</key> <key>orderHint</key>
<integer>12</integer> <integer>48</integer>
</dict> </dict>
<key>PG (Playground).xcscheme</key> <key>PG (Playground).xcscheme</key>
<dict> <dict>
<key>isShown</key> <key>isShown</key>
<false/> <false/>
<key>orderHint</key> <key>orderHint</key>
<integer>1</integer> <integer>54</integer>
</dict> </dict>
</dict> </dict>
</dict> </dict>
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
import UIKit import UIKit
import FBAudienceNetwork import FBAudienceNetwork
import OneWeatherCore
class AdCacheManager: NSObject { class AdCacheManager: NSObject {
......
...@@ -13,6 +13,7 @@ import FBAudienceNetwork ...@@ -13,6 +13,7 @@ import FBAudienceNetwork
import GoogleMobileAds import GoogleMobileAds
import IASDKCore import IASDKCore
import Flurry_iOS_SDK import Flurry_iOS_SDK
import OneWeatherCore
public class AdManager { public class AdManager {
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import Foundation import Foundation
import OneWeatherCore
public class AppAnalytics { public class AppAnalytics {
private let services: [AnalyticsService] private let services: [AnalyticsService]
......
...@@ -13,6 +13,7 @@ import MoEngage ...@@ -13,6 +13,7 @@ import MoEngage
import GoogleMobileAds import GoogleMobileAds
import Swarm import Swarm
import DTBiOSSDK import DTBiOSSDK
import OneWeatherCore
import AppsFlyerLib import AppsFlyerLib
@main @main
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class AppCoordinator: Coordinator { class AppCoordinator: Coordinator {
//Private //Private
......
...@@ -8,6 +8,8 @@ ...@@ -8,6 +8,8 @@
import UIKit import UIKit
import AppsFlyerLib import AppsFlyerLib
import Foundation
import OneWeatherCore
class DeeplinksRouter { class DeeplinksRouter {
static let urlScheme = "oneweather" static let urlScheme = "oneweather"
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class NWSAlertCoordinator: Coordinator { class NWSAlertCoordinator: Coordinator {
private let parentViewController:UIViewController private let parentViewController:UIViewController
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class NotificationsCoordinator: Coordinator { class NotificationsCoordinator: Coordinator {
private let parentViewController:UIViewController private let parentViewController:UIViewController
......
...@@ -9,9 +9,9 @@ ...@@ -9,9 +9,9 @@
import UIKit import UIKit
import StoreKit import StoreKit
import AppsFlyerLib import AppsFlyerLib
import OneWeatherCore
// Ported from ObjC // Ported from ObjC
protocol OLInAppStoreManagerUIDelegate: AnyObject { protocol OLInAppStoreManagerUIDelegate: AnyObject {
func viewControllerForPresentation() -> UIViewController func viewControllerForPresentation() -> UIViewController
} }
......
...@@ -20,6 +20,7 @@ import FBAudienceNetwork ...@@ -20,6 +20,7 @@ import FBAudienceNetwork
import PSMLocationSDK import PSMLocationSDK
import DTBiOSSDK import DTBiOSSDK
import AppsFlyerLib import AppsFlyerLib
import OneWeatherCore
fileprivate let APP_NAME = "ONE_WEATHER" fileprivate let APP_NAME = "ONE_WEATHER"
fileprivate let DEVICE_TYPE = "IOS" fileprivate let DEVICE_TYPE = "IOS"
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import Foundation import Foundation
import CoreLocation import CoreLocation
import UIKit import UIKit
import OneWeatherCore
internal protocol DeviceLocationMonitorDelegate: AnyObject { internal protocol DeviceLocationMonitorDelegate: AnyObject {
func deviceLocationMonitor(_ monitor: DeviceLocationMonitor, didUpdateLocation newLocation: PartialLocation) func deviceLocationMonitor(_ monitor: DeviceLocationMonitor, didUpdateLocation newLocation: PartialLocation)
......
...@@ -9,6 +9,12 @@ import Foundation ...@@ -9,6 +9,12 @@ import Foundation
import CoreLocation import CoreLocation
import UIKit import UIKit
import MoEngage import MoEngage
import OneWeatherCore
import WDTWeatherSource
import BlendHealthSource
import BlendFIPSSource
import CoreDataStorage
import DelayedSaveStorage
public protocol LocationManagerDelegate: AnyObject { public protocol LocationManagerDelegate: AnyObject {
func locationManager(_ locationManager: LocationManager, changedSelectedLocation newLocation: Location?) func locationManager(_ locationManager: LocationManager, changedSelectedLocation newLocation: Location?)
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import Foundation import Foundation
import OneWeatherCore
private enum Macro: String { private enum Macro: String {
case feelsLikeTemp = "#FEELS_LIKE_TEMP#" case feelsLikeTemp = "#FEELS_LIKE_TEMP#"
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class WeatherImageProvider { class WeatherImageProvider {
private enum DefaultImage: String { private enum DefaultImage: String {
......
...@@ -9,6 +9,7 @@ ...@@ -9,6 +9,7 @@
import Foundation import Foundation
import Firebase import Firebase
import FirebaseRemoteConfig import FirebaseRemoteConfig
import OneWeatherCore
public struct AppConfig: Codable { public struct AppConfig: Codable {
let popularCities: [GeoNamesPlace]? let popularCities: [GeoNamesPlace]?
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import Foundation import Foundation
import OneWeatherCore
struct NWSCurrentEventsReponse: Codable { struct NWSCurrentEventsReponse: Codable {
struct Wrapper: Codable { struct Wrapper: Codable {
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import Foundation import Foundation
import OneWeatherCore
class NWSAlertInfoParser { class NWSAlertInfoParser {
private var strongSelfReference: NWSAlertInfoParser? private var strongSelfReference: NWSAlertInfoParser?
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import Foundation import Foundation
import OneWeatherCore
public enum NWSError: Error { public enum NWSError: Error {
case insufficientLocationInfo case insufficientLocationInfo
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
import UIKit import UIKit
import Firebase import Firebase
import FirebaseRemoteConfig import FirebaseRemoteConfig
import OneWeatherCore
class PopularCitiesManager { class PopularCitiesManager {
public static let shared = PopularCitiesManager() public static let shared = PopularCitiesManager()
......
...@@ -9,6 +9,7 @@ ...@@ -9,6 +9,7 @@
import Foundation import Foundation
import MoEngage import MoEngage
import AppsFlyerLib import AppsFlyerLib
import OneWeatherCore
public class PushNotificationsManager: NSObject { public class PushNotificationsManager: NSObject {
// MARK: - Private // MARK: - Private
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
import Foundation import Foundation
import CoreLocation import CoreLocation
import XMLCoder import XMLCoder
import OneWeatherCore
public enum WdtWeatherSourceError: Error { public enum WdtWeatherSourceError: Error {
case insufficientLocationInfo case insufficientLocationInfo
......
...@@ -6,10 +6,9 @@ ...@@ -6,10 +6,9 @@
// //
import Foundation import Foundation
import OneWeatherCore
class LegacyMigrationManager { class LegacyMigrationManager {
typealias Completion = ([PartialLocation]?, MigrationError?) -> () typealias Completion = ([PartialLocation]?, MigrationError?) -> ()
private enum MigrationResult: String { private enum MigrationResult: String {
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import Foundation import Foundation
import OneWeatherCore
// Used in Settings and Widget // Used in Settings and Widget
enum LegacyTempUnits: Int { enum LegacyTempUnits: Int {
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import Foundation import Foundation
import OneWeatherCore
/// locations list, selectedIndex, error /// locations list, selectedIndex, error
public typealias StorageCompletion = ([Location]?, Int?, Error?) -> () public typealias StorageCompletion = ([Location]?, Int?, Error?) -> ()
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class NavigationCityButton: UIControl { class NavigationCityButton: UIControl {
//Private //Private
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import SnapKit import SnapKit
import OneWeatherCore
class ForecastDetailPeriodButton: UIControl, PeriodButtonProtocol { class ForecastDetailPeriodButton: UIControl, PeriodButtonProtocol {
private let kGraphInset:CGFloat = 10 private let kGraphInset:CGFloat = 10
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class ForecastPeriodButton: UIControl, PeriodButtonProtocol { class ForecastPeriodButton: UIControl, PeriodButtonProtocol {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class ForecastWindButton: UIControl, PeriodButtonProtocol { class ForecastWindButton: UIControl, PeriodButtonProtocol {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
public protocol PeriodButtonProtocol: UIControl { public protocol PeriodButtonProtocol: UIControl {
init() init()
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
private struct DailyGraphPoints { private struct DailyGraphPoints {
let maxTempPoints: [CGPoint] let maxTempPoints: [CGPoint]
......
...@@ -6,23 +6,7 @@ ...@@ -6,23 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
public enum AppTheme: Int {
case light = 0
case dark
case system
var nameForEvent: String {
switch self {
case .light:
return "light"
case .dark:
return "dark"
case .system:
return "system"
}
}
}
public struct ThemeManager { public struct ThemeManager {
public struct Colors { public struct Colors {
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class MoonPhaseCell: UITableViewCell { class MoonPhaseCell: UITableViewCell {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class PrecipButton: UIControl { class PrecipButton: UIControl {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class PrecipitationCell: UITableViewCell { class PrecipitationCell: UITableViewCell {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
private struct CircleSegment { private struct CircleSegment {
let chord:CGFloat let chord:CGFloat
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
protocol ForecastDailyCellDelegate: AnyObject { protocol ForecastDailyCellDelegate: AnyObject {
func timePeriodCell(cell:ForecastDailyCell, didSelectButtonAt index:Int) func timePeriodCell(cell:ForecastDailyCell, didSelectButtonAt index:Int)
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class ForecastDayCell: UITableViewCell { class ForecastDayCell: UITableViewCell {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class ForecastHourlyCell: UITableViewCell { class ForecastHourlyCell: UITableViewCell {
//Private //Private
......
...@@ -6,6 +6,8 @@ ...@@ -6,6 +6,8 @@
// //
import UIKit import UIKit
import OneWeatherCore
import Localize_Swift
class ForecastConditionView: UIView { class ForecastConditionView: UIView {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class ForecastInfoCell: UITableViewCell { class ForecastInfoCell: UITableViewCell {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class ForecastWindSpeedCell: UITableViewCell { class ForecastWindSpeedCell: UITableViewCell {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
protocol DaysControlViewDelegate: AnyObject { protocol DaysControlViewDelegate: AnyObject {
func didSelectButtonAt(index:Int) func didSelectButtonAt(index:Int)
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import SnapKit import SnapKit
import OneWeatherCore
protocol CityCellDelegate: AnyObject { protocol CityCellDelegate: AnyObject {
func didSelect(location:PartialLocation) func didSelect(location:PartialLocation)
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class LocationCellFactory: CellFactoryProtocol { class LocationCellFactory: CellFactoryProtocol {
//Private //Private
......
...@@ -6,6 +6,8 @@ ...@@ -6,6 +6,8 @@
// //
import UIKit import UIKit
import OneWeatherCore
//MARK:- Cities View Controller //MARK:- Cities View Controller
class LocationViewController:UIViewController { class LocationViewController:UIViewController {
//Private //Private
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import AlgoliaSearchClient import AlgoliaSearchClient
import OneWeatherCore
public protocol LocationsViewModelDelegate: AnyObject { public protocol LocationsViewModelDelegate: AnyObject {
func viewModelDidChange(model:LocationsViewModel) func viewModelDidChange(model:LocationsViewModel)
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import SafariServices import SafariServices
import OneWeatherCore
class MenuViewController: UIViewController { class MenuViewController: UIViewController {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
fileprivate enum NWSAlertCellType: Int { fileprivate enum NWSAlertCellType: Int {
case header = 0 case header = 0
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class NWSAlertInfoBlockTableViewCell: UITableViewCell { class NWSAlertInfoBlockTableViewCell: UITableViewCell {
let titleLabel = UILabel() let titleLabel = UILabel()
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import SnapKit import SnapKit
import OneWeatherCore
class NWSForecastOfficeTableViewCell: UITableViewCell { class NWSForecastOfficeTableViewCell: UITableViewCell {
var alert: NWSAlert? var alert: NWSAlert?
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class NWSAlertCell: UITableViewCell { class NWSAlertCell: UITableViewCell {
// TODO: we don't have an image for this one? // TODO: we don't have an image for this one?
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class NotificationsViewController: UIViewController { class NotificationsViewController: UIViewController {
private let coordinator: NotificationsCoordinator private let coordinator: NotificationsCoordinator
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class OnboardingViewController: UIViewController { class OnboardingViewController: UIViewController {
private let coordinator: OnboardingCoordinator private let coordinator: OnboardingCoordinator
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
protocol RadarLayerCellDelegate: AnyObject { protocol RadarLayerCellDelegate: AnyObject {
func cellPinButtonTouched(atLayer:RadarLayer) func cellPinButtonTouched(atLayer:RadarLayer)
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
private enum Section { private enum Section {
case weather case weather
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class MapLegendSevereView: UIView { class MapLegendSevereView: UIView {
//Private //Private
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import SnapKit import SnapKit
import OneWeatherCore
private enum LegendType { private enum LegendType {
case weather case weather
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class MapLegendWeatherView: UIView { class MapLegendWeatherView: UIView {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
protocol MapPinnedLayersViewDelegate: AnyObject { protocol MapPinnedLayersViewDelegate: AnyObject {
func didSelectLayer(layerId:String) func didSelectLayer(layerId:String)
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
import UIKit import UIKit
import MapKit import MapKit
import Swarm import Swarm
import OneWeatherCore
class RadarViewController: UIViewController { class RadarViewController: UIViewController {
//Private //Private
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
import UIKit import UIKit
import Localize_Swift import Localize_Swift
import CoreLocation import CoreLocation
import OneWeatherCore
public enum SettingsRow { public enum SettingsRow {
case theme case theme
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class SettingsDetailsCell: UITableViewCell { class SettingsDetailsCell: UITableViewCell {
//Private //Private
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import Localize_Swift import Localize_Swift
import OneWeatherCore
class SettingsDetailsCellFactory: CellFactoryProtocol { class SettingsDetailsCellFactory: CellFactoryProtocol {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class SettingsThemeCell: UITableViewCell { class SettingsThemeCell: UITableViewCell {
//Private //Private
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import Lottie import Lottie
import OneWeatherCore
class SplashAnimationViewController: UIViewController { class SplashAnimationViewController: UIViewController {
private let appCoordinator:AppCoordinator private let appCoordinator:AppCoordinator
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class PollutantView: UIView { class PollutantView: UIView {
//Private //Private
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import Cirque import Cirque
import OneWeatherCore
private struct AirQualityDataType: CirqueDataType { private struct AirQualityDataType: CirqueDataType {
var color: UIColor var color: UIColor
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class TodayAlertCell: UITableViewCell { class TodayAlertCell: UITableViewCell {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
public enum TodayCellType:Int { public enum TodayCellType:Int {
case alert = 0 case alert = 0
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class TodayConditionButton: UIControl { class TodayConditionButton: UIControl {
//Private //Private
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import SnapKit import SnapKit
import OneWeatherCore
class TodayConditionsCell: UITableViewCell { class TodayConditionsCell: UITableViewCell {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class DayTimeView: UIView { class DayTimeView: UIView {
private let dayTimeLabel = UILabel() private let dayTimeLabel = UILabel()
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class TodayDayTimesCell: UITableViewCell { class TodayDayTimesCell: UITableViewCell {
//Private //Private
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import SnapKit import SnapKit
import OneWeatherCore
class TodayForecastCell: UITableViewCell { class TodayForecastCell: UITableViewCell {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class TodayForecastTimePeriodCell: UITableViewCell { class TodayForecastTimePeriodCell: UITableViewCell {
//Private //Private
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
protocol ForecastViewModelDelegate:ViewModelDelegate { protocol ForecastViewModelDelegate:ViewModelDelegate {
func selectedWeatherDidChange() func selectedWeatherDidChange()
......
...@@ -9,6 +9,8 @@ import UIKit ...@@ -9,6 +9,8 @@ import UIKit
import StoreKit import StoreKit
import MessageUI import MessageUI
import PKHUD import PKHUD
import OneWeatherCore
import BlendHealthSource
protocol MenuViewModelDelegate: ViewModelDelegate { protocol MenuViewModelDelegate: ViewModelDelegate {
func viewControllerForPresentation() -> UIViewController func viewControllerForPresentation() -> UIViewController
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import Foundation import Foundation
import OneWeatherCore
class NWSAlertViewModel: ViewModelProtocol { class NWSAlertViewModel: ViewModelProtocol {
public weak var delegate: ViewModelDelegate? public weak var delegate: ViewModelDelegate?
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
// //
import Foundation import Foundation
import OneWeatherCore
protocol NotificationsViewModelDelegate: ViewModelDelegate { protocol NotificationsViewModelDelegate: ViewModelDelegate {
func viewModel(_ viewModel: NotificationsViewModel, didSelect alert: NWSAlert) func viewModel(_ viewModel: NotificationsViewModel, didSelect alert: NWSAlert)
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
import UIKit import UIKit
import Swarm import Swarm
import CoreLocation import CoreLocation
import OneWeatherCore
protocol RadarViewModelDelegate: ViewModelDelegate { protocol RadarViewModelDelegate: ViewModelDelegate {
func viewModel(model:RadarViewModel, didSelectLayer layer:RadarLayer) func viewModel(model:RadarViewModel, didSelectLayer layer:RadarLayer)
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import Localize_Swift import Localize_Swift
import OneWeatherCore
class SettingsDetailsViewModel: ViewModelProtocol { class SettingsDetailsViewModel: ViewModelProtocol {
//Public //Public
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
// //
import UIKit import UIKit
import OneWeatherCore
class SettingsViewModel: ViewModelProtocol { class SettingsViewModel: ViewModelProtocol {
let settings = Settings.shared let settings = Settings.shared
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import UIKit import UIKit
import PSMLocationSDK import PSMLocationSDK
import OneWeatherCore
protocol TodayViewModelDelegate: ViewModelDelegate { protocol TodayViewModelDelegate: ViewModelDelegate {
func showOnboarding(viewModel: TodayViewModel) func showOnboarding(viewModel: TodayViewModel)
......
//
// BlendFIPS.h
// BlendFIPS
//
// Created by Dmitry Stepanets on 21.05.2021.
//
#import <Foundation/Foundation.h>
//! Project version number for BlendFIPS.
FOUNDATION_EXPORT double BlendFIPSVersionNumber;
//! Project version string for BlendFIPS.
FOUNDATION_EXPORT const unsigned char BlendFIPSVersionString[];
// In this header, you should import all the public headers of your framework using statements like #import <BlendFIPS/PublicHeader.h>
...@@ -4,10 +4,10 @@ ...@@ -4,10 +4,10 @@
// //
// Created by Demid Merzlyakov on 28.04.2021. // Created by Demid Merzlyakov on 28.04.2021.
// //
import Foundation import Foundation
import OneWeatherCore
class BlendFIPSSource: FIPSSource { public class BlendFIPSSource: FIPSSource {
private let log = Logger(componentName: "BlendFIPSSource") private let log = Logger(componentName: "BlendFIPSSource")
private let baseUrlProduction = "https://nwsalert.onelouder.com" private let baseUrlProduction = "https://nwsalert.onelouder.com"
...@@ -34,6 +34,8 @@ class BlendFIPSSource: FIPSSource { ...@@ -34,6 +34,8 @@ class BlendFIPSSource: FIPSSource {
private var locationsBeingUpdated = Set<Location>() private var locationsBeingUpdated = Set<Location>()
public init() {}
public func getFipsCode(for location: Location, completion: @escaping FIPSSourceeCompletion) { public func getFipsCode(for location: Location, completion: @escaping FIPSSourceeCompletion) {
internalQueue.addOperation { [weak self] in internalQueue.addOperation { [weak self] in
let extendedCompletion: FIPSSourceeCompletion = { [weak self] (fipsCode) in let extendedCompletion: FIPSSourceeCompletion = { [weak self] (fipsCode) in
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
</dict>
</plist>
//
// BlendFIPSTests.swift
// BlendFIPSTests
//
// Created by Dmitry Stepanets on 21.05.2021.
//
import XCTest
@testable import BlendFIPS
class BlendFIPSTests: XCTestCase {
override func setUpWithError() throws {
// Put setup code here. This method is called before the invocation of each test method in the class.
}
override func tearDownWithError() throws {
// Put teardown code here. This method is called after the invocation of each test method in the class.
}
func testExample() throws {
// This is an example of a functional test case.
// Use XCTAssert and related functions to verify your tests produce the correct results.
}
func testPerformanceExample() throws {
// This is an example of a performance test case.
self.measure {
// Put the code you want to measure the time of here.
}
}
}
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
</dict>
</plist>
//
// BlendHealthSource.h
// BlendHealthSource
//
// Created by Dmitry Stepanets on 21.05.2021.
//
#import <Foundation/Foundation.h>
//! Project version number for BlendHealthSource.
FOUNDATION_EXPORT double BlendHealthSourceVersionNumber;
//! Project version string for BlendHealthSource.
FOUNDATION_EXPORT const unsigned char BlendHealthSourceVersionString[];
// In this header, you should import all the public headers of your framework using statements like #import <BlendHealthSource/PublicHeader.h>
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
// //
import Foundation import Foundation
import OneWeatherCore
public enum BlendHealthSourceError: Error { public enum BlendHealthSourceError: Error {
case insufficientLocationInfo case insufficientLocationInfo
...@@ -43,6 +43,8 @@ public class BlendHealthSource: HealthSource { ...@@ -43,6 +43,8 @@ public class BlendHealthSource: HealthSource {
private var locationsBeingUpdated = Set<Location>() private var locationsBeingUpdated = Set<Location>()
public init() {}
public func updateHelath(for location: Location, completion: @escaping HealthSourceCompletion) { public func updateHelath(for location: Location, completion: @escaping HealthSourceCompletion) {
internalQueue.addOperation { [weak self] in internalQueue.addOperation { [weak self] in
let extendedCompletion: HealthSourceCompletion = { [weak self] (health, error) in let extendedCompletion: HealthSourceCompletion = { [weak self] (health, error) in
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
</dict>
</plist>
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
import Foundation import Foundation
import UIKit import UIKit
import OneWeatherCore
// MARK: - HealthCenter // MARK: - HealthCenter
struct BlendHealthCenter: Codable { struct BlendHealthCenter: Codable {
......
//
// BlendHealthSourceTests.swift
// BlendHealthSourceTests
//
// Created by Dmitry Stepanets on 21.05.2021.
//
import XCTest
@testable import BlendHealthSource
class BlendHealthSourceTests: XCTestCase {
override func setUpWithError() throws {
// Put setup code here. This method is called before the invocation of each test method in the class.
}
override func tearDownWithError() throws {
// Put teardown code here. This method is called after the invocation of each test method in the class.
}
func testExample() throws {
// This is an example of a functional test case.
// Use XCTAssert and related functions to verify your tests produce the correct results.
}
func testPerformanceExample() throws {
// This is an example of a performance test case.
self.measure {
// Put the code you want to measure the time of here.
}
}
}
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment