问题
I was trying to make an instance of SKViaPoint with
SKViaPoint *point = [SKViaPoint viaPoint:1 withCoordinate:coordinate];
But I am getting a following error:
So "No known class method for selector".
I checked and I do have the latest version of Skobbler SDK, but I also checked and there is no actual ViaPoint.h. Not in mine neither in the Demo project.
So Im wondering is there anything else I should import in order to be able to make SKViaPoint instance?
回答1:
Ok, what solved it was importing the actual class, from SKMaps framework. Importing framework only didn't do the trick
#import <SKMaps/SKViaPoint.h>
回答2:
Unfortunately, in the 2.5 Swift build, SKMaps.h in SKMaps.framework/Headers is missing some imports: SKViaPoint, SKViaPointState and SKSearch. You can add them manually or use the header found here.
In the next update we'll fix this issue.
来源:https://stackoverflow.com/questions/31910149/reciever-skviapoint-for-class-message-is-a-forward-declaration