use objc2::__framework_prelude::*;
use objc2_foundation::*;
use crate::*;
extern_class!(
#[derive(Debug, PartialEq, Eq, Hash)]
pub struct MPContentItem;
unsafe impl ClassType for MPContentItem {
type Super = NSObject;
type Mutability = InteriorMutable;
}
);
unsafe impl NSObjectProtocol for MPContentItem {}
extern_methods!(
unsafe impl MPContentItem {
#[method_id(@__retain_semantics Init initWithIdentifier:)]
pub unsafe fn initWithIdentifier(this: Allocated<Self>, identifier: &NSString) -> Id<Self>;
#[method_id(@__retain_semantics Other identifier)]
pub unsafe fn identifier(&self) -> Id<NSString>;
#[method_id(@__retain_semantics Other title)]
pub unsafe fn title(&self) -> Option<Id<NSString>>;
#[method(setTitle:)]
pub unsafe fn setTitle(&self, title: Option<&NSString>);
#[method_id(@__retain_semantics Other subtitle)]
pub unsafe fn subtitle(&self) -> Option<Id<NSString>>;
#[method(setSubtitle:)]
pub unsafe fn setSubtitle(&self, subtitle: Option<&NSString>);
#[cfg(feature = "MPMediaItem")]
#[method_id(@__retain_semantics Other artwork)]
pub unsafe fn artwork(&self) -> Option<Id<MPMediaItemArtwork>>;
#[cfg(feature = "MPMediaItem")]
#[method(setArtwork:)]
pub unsafe fn setArtwork(&self, artwork: Option<&MPMediaItemArtwork>);
#[method(playbackProgress)]
pub unsafe fn playbackProgress(&self) -> c_float;
#[method(setPlaybackProgress:)]
pub unsafe fn setPlaybackProgress(&self, playback_progress: c_float);
#[method(isStreamingContent)]
pub unsafe fn isStreamingContent(&self) -> bool;
#[method(setStreamingContent:)]
pub unsafe fn setStreamingContent(&self, streaming_content: bool);
#[method(isExplicitContent)]
pub unsafe fn isExplicitContent(&self) -> bool;
#[method(setExplicitContent:)]
pub unsafe fn setExplicitContent(&self, explicit_content: bool);
#[method(isContainer)]
pub unsafe fn isContainer(&self) -> bool;
#[method(setContainer:)]
pub unsafe fn setContainer(&self, container: bool);
#[method(isPlayable)]
pub unsafe fn isPlayable(&self) -> bool;
#[method(setPlayable:)]
pub unsafe fn setPlayable(&self, playable: bool);
}
);
extern_methods!(
unsafe impl MPContentItem {
#[method_id(@__retain_semantics Init init)]
pub unsafe fn init(this: Allocated<Self>) -> Id<Self>;
#[method_id(@__retain_semantics New new)]
pub unsafe fn new() -> Id<Self>;
}
);