objective c - Why do we still use NSDictionary and NSArrays in swift ios applications? -
i see lot of code swift ios tutorials on net still using old objective-c info types nsdictionary , nsarrays instead of using modern array , dictionary info types come swift.
most see lot of type casting going on using as? etc. have seen in examples involving json parsing webservice.
so why this? because swift isn't compatible withe cocoa touch apis yet? or there reason performance?
even though used nsarray , nsdictionary, swift automatically bridges native swift equivalent array , dictionary.
by using swift native, performance great.
please refer documentation
ios objective-c swift
No comments:
Post a Comment