Skip to content
This repository was archived by the owner on Sep 19, 2024. It is now read-only.

Commit 0ab9e81

Browse files
committed
SwiftDoc for UIStoryboardSegue
1 parent 5363ac5 commit 0ab9e81

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

Library/UIKit/UIStoryboardSegue+StoryboardSegueIdentifierProtocol.swift

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,13 @@ import Foundation
1010
import UIKit
1111

1212
public extension UIStoryboardSegue {
13+
/**
14+
Get typed info about this segue for the given identifier (R.segue.*)
15+
16+
- parameter identifier: The identifier this segue should be an instance of.
17+
18+
- returns: Types information such as the destinationViewController cast to the correct type or nil if the segue doesn't match the given identifier (R.segue.*)
19+
*/
1320
public func typedInfoWithIdentifier<Identifier: StoryboardSegueIdentifierProtocol, Segue, Source, Destination where Segue == Identifier.SegueType, Source == Identifier.SourceType, Destination == Identifier.DestinationType>(identifier: Identifier) -> TypedStoryboardSegueInfo<Segue, Source, Destination>? {
1421
guard self.identifier == identifier.identifier else { return nil }
1522
return TypedStoryboardSegueInfo(segue: self)

0 commit comments

Comments
 (0)