Created
August 15, 2018 17:14
-
-
Save serhatsezer/4abe382229b001b37b1ee2f46e62b90f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| private var associateKey: Void? | |
| extension ProductDetail { | |
| var totalSumOfBasket: String? { | |
| get { | |
| return objc_getAssociatedObject(self, &associateKey) as? String | |
| } | |
| set { | |
| objc_setAssociatedObject(self, &associateKey, newValue, .OBJC_ASSOCIATION_RETAIN) | |
| } | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment