AVPlayer forward class declaration
I figured it out. I thought #import <AVKit/AVKit.h>
was enough for AVPlayerViewController but if you want to manage the AVPlayer
you also need #import <AVFoundation/AVFoundation.h>
.
Have you imported AVPlayerViewController.h
i.e. #import "AVPlayerViewController.h"
?
A forward declaration is where the you are trying to send messages to a class that the compiler doesn't know about.