Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleanup of Deprecated / Obsoleted Symbols #2297

Merged
merged 12 commits into from
Jan 11, 2020
2 changes: 1 addition & 1 deletion MapboxCoreNavigation/LegacyRouteController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -549,7 +549,7 @@ open class LegacyRouteController: NSObject, Router, InternalRouter, CLLocationMa
fatalError()
}
}
@available(*, deprecated, renamed: "NavigationService.locationManager", message: "NavigationViewController no longer directly manages an NavigationLocationManager. See MapboxNavigationService, which contains a reference to the locationManager, for more information.")
@available(*, deprecated, message: "NavigationViewController no longer directly manages a TunnelIntersectionManager. See MapboxNavigationService, which contains a reference to the locationManager, for more information.")
/// :nodoc: obsoleted
public final var tunnelIntersectionManager: Any! {
get {
Expand Down
7 changes: 3 additions & 4 deletions MapboxCoreNavigation/NavigationEventsManager.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ public protocol EventsManagerDataSource: class {
var locationProvider: NavigationLocationManager.Type { get }
}

@available(*, deprecated, renamed: "NavigationEventsManager")
public typealias EventsManager = NavigationEventsManager
@available(swift, obsoleted: 0.1, renamed: "NavigationEventsManager")
public typealias EventsManager = NSObject

/**
The `NavigationEventsManager` is responsible for being the liaison between MapboxCoreNavigation and the Mapbox telemetry framework.
*/
open class NavigationEventsManager: NSObject {
open class NavigationEventsManager {
var sessionState: SessionState?

var outstandingFeedbackEvents = [CoreFeedbackEvent]()
Expand Down Expand Up @@ -52,7 +52,6 @@ open class NavigationEventsManager: NSObject {

public required init(dataSource source: EventsManagerDataSource?, accessToken possibleToken: String? = nil, mobileEventsManager: MMEEventsManager = .shared()) {
dataSource = source
super.init()
if let tokenOverride = possibleToken {
accessToken = tokenOverride
}
Expand Down
4 changes: 0 additions & 4 deletions MapboxCoreNavigation/OfflineDirections.swift
Original file line number Diff line number Diff line change
Expand Up @@ -127,10 +127,6 @@ public class NavigationDirections: Directions {
}
}

@available(*, deprecated, renamed: "NavigationDirections.configureRouter(tilesURL:completionHandler:)")
public func configureRouter(tilesURL: URL, translationsURL: URL? = nil, completionHandler: @escaping NavigationDirectionsCompletionHandler) {
configureRouter(tilesURL: tilesURL, completionHandler: completionHandler)
}

/**
Unpacks a .tar-file at the given filePathURL to a writeable output directory.
Expand Down
4 changes: 2 additions & 2 deletions MapboxCoreNavigation/RouteProgress.swift
Original file line number Diff line number Diff line change
Expand Up @@ -375,9 +375,9 @@ open class RouteLegProgress: NSObject {

If there is no `upcomingStep`, nil is returned.
*/
@available(*, deprecated, renamed: "upcomingStep")
@available(swift, obsoleted: 0.1, renamed: "upcomingStep")
public var upComingStep: RouteStep? {
return upcomingStep
fatalError()
}

public var upcomingStep: RouteStep? {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -233,10 +233,10 @@
"${PODS_ROOT}/Target Support Files/Pods-PodInstall/Pods-PodInstall-frameworks.sh",
"${PODS_ROOT}/Mapbox-iOS-SDK/dynamic/Mapbox.framework",
"${PODS_ROOT}/Mapbox-iOS-SDK/dynamic/Mapbox.framework.dSYM",
"${PODS_ROOT}/Mapbox-iOS-SDK/dynamic/F207D6B5-A5AF-3799-A665-6016E3A8EA01.bcsymbolmap",
"${PODS_ROOT}/Mapbox-iOS-SDK/dynamic/8F504B7B-C196-3FBC-B345-1F70257D3AEC.bcsymbolmap",
"${PODS_ROOT}/Mapbox-iOS-SDK/dynamic/2020F3C8-7482-398F-94F5-08E6FADF2B47.bcsymbolmap",
"${PODS_ROOT}/Mapbox-iOS-SDK/dynamic/B2BBCEBE-D9C9-3E98-A63B-0BD273A7B14A.bcsymbolmap",
"${PODS_ROOT}/Mapbox-iOS-SDK/dynamic/4794199C-B164-3A2D-A3B4-553B7D49EDD5.bcsymbolmap",
"${PODS_ROOT}/Mapbox-iOS-SDK/dynamic/097AD13C-9FDA-310F-8B76-64CB67B06A27.bcsymbolmap",
"${PODS_ROOT}/Mapbox-iOS-SDK/dynamic/491A77E9-7DBC-3309-A93C-BADAE0DDBC6E.bcsymbolmap",
"${PODS_ROOT}/Mapbox-iOS-SDK/dynamic/3F114CA8-302D-327F-87C3-670E0EC63C9A.bcsymbolmap",
"${BUILT_PRODUCTS_DIR}/MapboxCoreNavigation/MapboxCoreNavigation.framework",
"${BUILT_PRODUCTS_DIR}/MapboxDirections.swift/MapboxDirections.framework",
"${BUILT_PRODUCTS_DIR}/MapboxMobileEvents/MapboxMobileEvents.framework",
Expand All @@ -252,10 +252,10 @@
outputPaths = (
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/Mapbox.framework",
"${DWARF_DSYM_FOLDER_PATH}/Mapbox.framework.dSYM",
"${BUILT_PRODUCTS_DIR}/F207D6B5-A5AF-3799-A665-6016E3A8EA01.bcsymbolmap",
"${BUILT_PRODUCTS_DIR}/8F504B7B-C196-3FBC-B345-1F70257D3AEC.bcsymbolmap",
"${BUILT_PRODUCTS_DIR}/2020F3C8-7482-398F-94F5-08E6FADF2B47.bcsymbolmap",
"${BUILT_PRODUCTS_DIR}/B2BBCEBE-D9C9-3E98-A63B-0BD273A7B14A.bcsymbolmap",
"${BUILT_PRODUCTS_DIR}/4794199C-B164-3A2D-A3B4-553B7D49EDD5.bcsymbolmap",
"${BUILT_PRODUCTS_DIR}/097AD13C-9FDA-310F-8B76-64CB67B06A27.bcsymbolmap",
"${BUILT_PRODUCTS_DIR}/491A77E9-7DBC-3309-A93C-BADAE0DDBC6E.bcsymbolmap",
"${BUILT_PRODUCTS_DIR}/3F114CA8-302D-327F-87C3-670E0EC63C9A.bcsymbolmap",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/MapboxCoreNavigation.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/MapboxDirections.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/MapboxMobileEvents.framework",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
PODS:
- Mapbox-iOS-SDK (5.6.0):
- Mapbox-iOS-SDK (5.6.1):
- MapboxMobileEvents (= 0.10.2)
- MapboxCoreNavigation (0.38.1):
- MapboxDirections.swift (~> 0.30.0)
Expand Down Expand Up @@ -27,7 +27,7 @@ DEPENDENCIES:
- MapboxNavigation (from `../../../`)

SPEC REPOS:
trunk:
https://github.com/cocoapods/specs.git:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This fixes failures in the CocoaPods installation tests that I inadvertently introduced in 8fa1138 for #2275, which I overlooked due to expected failures in the lint step.

- Mapbox-iOS-SDK
- MapboxMobileEvents
- MapboxNavigationNative
Expand All @@ -51,7 +51,7 @@ CHECKOUT OPTIONS:
:git: https://github.com/mapbox/MapboxDirections.swift.git

SPEC CHECKSUMS:
Mapbox-iOS-SDK: 913c4655bd72a200f84996caf7a755b377abc77f
Mapbox-iOS-SDK: b31bd62a5dd5b7e688eab787acd3d093a122f4d6
MapboxCoreNavigation: edf9a698fcd51b23956e3f5282cc1dae9bc271e4
MapboxDirections.swift: f92188002af2401e2ab97b1e74bf302243d00e43
MapboxMobileEvents: 2bc0ca2eedb627b73cf403258dce2b2fa98074a6
Expand All @@ -64,4 +64,4 @@ SPEC CHECKSUMS:

PODFILE CHECKSUM: 93f8b73ee661779638fb731cc44d6a0abf1b3acd

COCOAPODS: 1.8.4
COCOAPODS: 1.7.5
4 changes: 0 additions & 4 deletions MapboxNavigation.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,6 @@
8D24A2F820409A890098CBF8 /* CGSize.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8D24A2F720409A890098CBF8 /* CGSize.swift */; };
8D24A2FA20449B430098CBF8 /* Dictionary.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8D24A2F920449B430098CBF8 /* Dictionary.swift */; };
8D2AA745211CDD4000EB7F72 /* NavigationService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8D2AA744211CDD4000EB7F72 /* NavigationService.swift */; };
8D3322252200E149001D44AA /* NavigationViewController+Obsolete.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8D3322242200E149001D44AA /* NavigationViewController+Obsolete.swift */; };
8D3322272200E4CA001D44AA /* NavigationOptions.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8D3322262200E4CA001D44AA /* NavigationOptions.swift */; };
8D424F28215ECAF200432491 /* CoreLocation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8D424F26215ECA5D00432491 /* CoreLocation.framework */; };
8D4B60E7219CBEB300C41906 /* CarPlayManagerDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8D4B60E6219CBEB300C41906 /* CarPlayManagerDelegate.swift */; };
Expand Down Expand Up @@ -821,7 +820,6 @@
8D24A2F720409A890098CBF8 /* CGSize.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CGSize.swift; sourceTree = "<group>"; };
8D24A2F920449B430098CBF8 /* Dictionary.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Dictionary.swift; sourceTree = "<group>"; };
8D2AA744211CDD4000EB7F72 /* NavigationService.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NavigationService.swift; sourceTree = "<group>"; };
8D3322242200E149001D44AA /* NavigationViewController+Obsolete.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "NavigationViewController+Obsolete.swift"; sourceTree = "<group>"; };
8D3322262200E4CA001D44AA /* NavigationOptions.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NavigationOptions.swift; sourceTree = "<group>"; };
8D424F26215ECA5D00432491 /* CoreLocation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreLocation.framework; path = System/Library/Frameworks/CoreLocation.framework; sourceTree = SDKROOT; };
8D4B60E6219CBEB300C41906 /* CarPlayManagerDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CarPlayManagerDelegate.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -1284,7 +1282,6 @@
359D1B271FFE70D30052FA42 /* NavigationView.swift */,
351BEBEA1E5BCC63006FE110 /* NavigationViewController.swift */,
8D3322262200E4CA001D44AA /* NavigationOptions.swift */,
8D3322242200E149001D44AA /* NavigationViewController+Obsolete.swift */,
8DEDEF3321E3FBE80049E114 /* NavigationViewControllerDelegate.swift */,
351BEBE41E5BCC63006FE110 /* RouteMapViewController.swift */,
35C9973E1E732C1B00544D1C /* RouteVoiceController.swift */,
Expand Down Expand Up @@ -2372,7 +2369,6 @@
DA443DDE2278C90E00ED1307 /* CPTrip.swift in Sources */,
35D825FC1E6A2DBE0088F83B /* MGLMapView+MGLNavigationAdditions.m in Sources */,
8D63A7D0227A580A00520167 /* TopBannerViewController.swift in Sources */,
8D3322252200E149001D44AA /* NavigationViewController+Obsolete.swift in Sources */,
C51511D120EAC89D00372A91 /* CPMapTemplate.swift in Sources */,
353280A11FA72871005175F3 /* InstructionLabel.swift in Sources */,
351BEBFF1E5BCC63006FE110 /* ManeuversStyleKit.swift in Sources */,
Expand Down
5 changes: 2 additions & 3 deletions MapboxNavigation/BottomBannerViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -95,10 +95,9 @@ open class BottomBannerViewController: UIViewController, NavigationComponent {

- parameter delegate: A delegate to recieve BottomBannerViewControllerDelegate messages.
*/
@available(*, deprecated, message: "Set the delegate property separately after initializing this object.")
@available(swift, obsoleted: 0.1, message: "Set the delegate property separately after initializing this object.")
public convenience init(delegate: BottomBannerViewControllerDelegate?) {
self.init(nibName: nil, bundle: nil)
self.delegate = delegate
fatalError()
}

/**
Expand Down
7 changes: 0 additions & 7 deletions MapboxNavigation/InstructionsBannerView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,6 @@ public protocol InstructionsBannerViewDelegate: class, UnimplementedLogging {
*/
func didTapInstructionsBanner(_ sender: BaseInstructionsBannerView)

/**
Called when the user drags either up or down on the `InstructionsBannerView`.
- note: This delegate method includes a default implementation that prints a warning to the console when this method is called. See `UnimplementedLogging` for details.
*/
@available(*, deprecated, message: "Please use didSwipeInstructionsBanner instead.")

func didDragInstructionsBanner(_ sender: BaseInstructionsBannerView)

/**
Called when the user swipes either left, right, or down on the `InstructionsBannerView`
Expand Down
2 changes: 1 addition & 1 deletion MapboxNavigation/MapboxVoiceController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ open class MapboxVoiceController: RouteVoiceController, AVAudioPlayerDelegate {

//MARK: - Obsolete
extension MapboxVoiceController {
@available(*, deprecated, renamed: "MapboxVoiceController.play(instruction:data:)")
@available(*, deprecated, message: "It is now required that the maneuver's `SpokenInstruction` is passed into `play` when calling. Please use MapboxVoiceController.play(instruction:data:).")
open func play(_ data: Data) {
guard let instruction = routeProgress?.currentLegProgress.currentStepProgress.currentSpokenInstruction else {
return
Expand Down
5 changes: 2 additions & 3 deletions MapboxNavigation/NavigationMapView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,9 @@ open class NavigationMapView: MGLMapView, UIGestureRecognizerDelegate {
The object that acts as the navigation delegate of the map view.
*/
public weak var navigationMapViewDelegate: NavigationMapViewDelegate?
@available(*, deprecated, renamed: "navigationMapViewDelegate")
@available(swift, obsoleted: 0.1, renamed: "navigationMapViewDelegate")
public weak var navigationMapDelegate: NavigationMapViewDelegate? {
get { return navigationMapViewDelegate }
set { navigationMapViewDelegate = newValue}
fatalError()
}

/**
Expand Down
19 changes: 0 additions & 19 deletions MapboxNavigation/NavigationMapViewDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -105,15 +105,6 @@ public protocol NavigationMapViewDelegate: class, UnimplementedLogging {
*/
func navigationMapViewUserAnchorPoint(_ mapView: NavigationMapView) -> CGPoint

//MARK: Obsolete

@available(*, deprecated, message: "The NavigationMapView no longer forwards MGLMapViewDelegate messages. Use MGLMapViewDelegate.mapView(_:imageFor:) instead.")

func navigationMapView(_ mapView: MGLMapView, imageFor annotation: MGLAnnotation) -> MGLAnnotationImage?

@available(*, deprecated, message: "The NavigationMapView no longer forwards MGLMapViewDelegate messages. Use MGLMapViewDelegate.mapView(_:viewFor:) instead.")

func navigationMapView(_ mapView: MGLMapView, viewFor annotation: MGLAnnotation) -> MGLAnnotationView?
}

public extension NavigationMapViewDelegate {
Expand Down Expand Up @@ -164,16 +155,6 @@ public extension NavigationMapViewDelegate {
logUnimplemented(protocolType: NavigationMapViewDelegate.self, level: .debug)
return .zero
}

func navigationMapView(_ mapView: MGLMapView, imageFor annotation: MGLAnnotation) -> MGLAnnotationImage? {
//no-op, deprecated
return nil
}

func navigationMapView(_ mapView: MGLMapView, viewFor annotation: MGLAnnotation) -> MGLAnnotationView? {
//no-op, deprecated
return nil
}
}

// MARK: NavigationMapViewCourseTrackingDelegate
Expand Down
77 changes: 0 additions & 77 deletions MapboxNavigation/NavigationViewController+Obsolete.swift

This file was deleted.

9 changes: 2 additions & 7 deletions MapboxNavigation/StatusView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,9 @@ public class StatusView: UIControl {

var isCurrentlyVisible: Bool = false

@available(*, deprecated, renamed: "isEnabled")
@available(swift, obsoleted: 0.1, renamed: "isEnabled")
public var canChangeValue: Bool {
get {
return isEnabled
}
set {
isEnabled = newValue
}
fatalError()
}

var value: Double = 0 {
Expand Down