Class SHMediaItem

  • All Implemented Interfaces:
    NSCoding, NSCopying, NSSecureCoding, NSObject
    Direct Known Subclasses:
    SHMatchedMediaItem

    public class SHMediaItem
    extends NSObject
    implements NSSecureCoding, NSCopying
    [@c] SHMediaItem represents metadata associated with a @c SHSignature A @c SHMediaItem is used in two distinct ways 1. As the base class of a @c SHMatchedMediaItem, and therefore as the result of a match 2. As a way of associating metadata with reference signatures in a @c SHCustomCatalog A SHMediaItem contains no required fields and may be entirely blank, they can also contain custom data set with custom keys when making a @c SHCustomCatalog. [@note] @c SHMediaItem is not intended to be subclassed further. API-Since: 15.0
    • Constructor Detail

      • SHMediaItem

        protected SHMediaItem​(org.moe.natj.general.Pointer peer)
    • Method Detail

      • accessInstanceVariablesDirectly

        public static boolean accessInstanceVariablesDirectly()
      • allocWithZone

        public static SHMediaItem allocWithZone​(org.moe.natj.general.ptr.VoidPtr zone)
      • appleMusicID

        @Nullable
        public @Nullable java.lang.String appleMusicID()
        The Apple Music ID [@note] This may be fetched using the key @c SHMediaItemAppleMusicID
      • appleMusicURL

        @Nullable
        public @Nullable NSURL appleMusicURL()
        The Apple Music URL [@note] This may be fetched using the key @c SHMediaItemAppleMusicURL
      • artist

        @Nullable
        public @Nullable java.lang.String artist()
        The Artist [@note] This may be fetched using the key @c SHMediaItemArtist
      • artworkURL

        @Nullable
        public @Nullable NSURL artworkURL()
        The Artwork URL [@note] This may be fetched using the key @c SHMediaItemArtworkURL
      • automaticallyNotifiesObserversForKey

        public static boolean automaticallyNotifiesObserversForKey​(@NotNull
                                                                   @NotNull java.lang.String key)
      • cancelPreviousPerformRequestsWithTarget

        public static void cancelPreviousPerformRequestsWithTarget​(@NotNull
                                                                   @NotNull java.lang.Object aTarget)
      • cancelPreviousPerformRequestsWithTargetSelectorObject

        public static void cancelPreviousPerformRequestsWithTargetSelectorObject​(@NotNull
                                                                                 @NotNull java.lang.Object aTarget,
                                                                                 @NotNull
                                                                                 @NotNull org.moe.natj.objc.SEL aSelector,
                                                                                 @Nullable
                                                                                 @Nullable java.lang.Object anArgument)
      • classFallbacksForKeyedArchiver

        @NotNull
        public static @NotNull NSArray<java.lang.String> classFallbacksForKeyedArchiver()
      • classForKeyedUnarchiver

        @NotNull
        public static @NotNull org.moe.natj.objc.Class classForKeyedUnarchiver()
      • copyWithZone

        @NotNull
        public @NotNull java.lang.Object copyWithZone​(@Nullable
                                                      @Nullable org.moe.natj.general.ptr.VoidPtr zone)
        Specified by:
        copyWithZone in interface NSCopying
      • debugDescription_static

        public static java.lang.String debugDescription_static()
      • description_static

        public static java.lang.String description_static()
      • explicitContent

        public boolean explicitContent()
        Whether this object represents explicit material [@note] This may be fetched using the key @c SHMediaItemExplicitContent
      • fetchMediaItemWithShazamIDCompletionHandler

        public static void fetchMediaItemWithShazamIDCompletionHandler​(@NotNull
                                                                       @NotNull java.lang.String shazamID,
                                                                       @NotNull
                                                                       @NotNull SHMediaItem.Block_fetchMediaItemWithShazamIDCompletionHandler completionHandler)
        Fetch a @c SHMediaItem by Shazam ID The completionHandler will contain a @c SHMediaItem if the ShazamID is valid, otherwise nil and an error
      • genres

        @NotNull
        public @NotNull NSArray<java.lang.String> genres()
        The Genre Names [@note] This may be fetched using the key @c SHMediaItemGenres An array of strings representing the genres of the media item. Will return an empty array if there are no genres.
      • hash_static

        public static long hash_static()
      • instanceMethodSignatureForSelector

        public static NSMethodSignature instanceMethodSignatureForSelector​(org.moe.natj.objc.SEL aSelector)
      • instancesRespondToSelector

        public static boolean instancesRespondToSelector​(org.moe.natj.objc.SEL aSelector)
      • isSubclassOfClass

        public static boolean isSubclassOfClass​(org.moe.natj.objc.Class aClass)
      • isrc

        @Nullable
        public @Nullable java.lang.String isrc()
        The International Standard Recording Code [@note] This may be fetched using the key @c SHMediaItemISRC
      • keyPathsForValuesAffectingValueForKey

        @NotNull
        public static @NotNull NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey​(@NotNull
                                                                                             @NotNull java.lang.String key)
      • mediaItemWithProperties

        public static SHMediaItem mediaItemWithProperties​(@NotNull
                                                          @NotNull NSDictionary<java.lang.String,​?> properties)
        Construct a new instance with the provided dictionary You may add your own keys here to return custom data, custom data should conform to NSCoding
        Parameters:
        properties - A dictionary of @c SHMediaItemProperty and their values
      • objectForKeyedSubscript

        @NotNull
        public @NotNull java.lang.Object objectForKeyedSubscript​(@NotNull
                                                                 @NotNull java.lang.String key)
        Use subscripting to retrieve values
        Parameters:
        key - The `SHMediaItemProperty` or custom key for a value
      • resolveClassMethod

        public static boolean resolveClassMethod​(org.moe.natj.objc.SEL sel)
      • resolveInstanceMethod

        public static boolean resolveInstanceMethod​(org.moe.natj.objc.SEL sel)
      • setVersion_static

        public static void setVersion_static​(long aVersion)
      • shazamID

        @Nullable
        public @Nullable java.lang.String shazamID()
        The Shazam Media ID [@note] This may be fetched using the key @c SHMediaItemShazamID
      • subtitle

        @Nullable
        public @Nullable java.lang.String subtitle()
        The Subtitle [@note] This may be fetched using the key @c SHMediaItemSubtitle
      • superclass_static

        public static org.moe.natj.objc.Class superclass_static()
      • supportsSecureCoding

        public static boolean supportsSecureCoding()
      • _supportsSecureCoding

        public boolean _supportsSecureCoding()
        Description copied from interface: NSSecureCoding
        This property must return YES on all classes that allow secure coding. Subclasses of classes that adopt NSSecureCoding and override initWithCoder: must also override this method and return YES. The Secure Coding Guide should be consulted when writing methods that decode data.
        Specified by:
        _supportsSecureCoding in interface NSSecureCoding
      • title

        @Nullable
        public @Nullable java.lang.String title()
        The Title [@note] This may be fetched using the key @c SHMediaItemTitle
      • valueForProperty

        @NotNull
        public @NotNull java.lang.Object valueForProperty​(@NotNull
                                                          @NotNull java.lang.String property)
        Retrieve a value using a known key
        Parameters:
        property - The `SHMediaItemProperty` for a value
      • version_static

        public static long version_static()
      • videoURL

        @Nullable
        public @Nullable NSURL videoURL()
        The VideoURL [@note] This may be fetched using the key @c SHMediaItemVideoURL
      • webURL

        @Nullable
        public @Nullable NSURL webURL()
        The Web URL The URL will point to a page that displays the current object in its entirety [@note] This may be fetched using the key @c SHMediaItemWebURL
      • frequencySkewRanges

        @NotNull
        public @NotNull NSArray<? extends SHRange> frequencySkewRanges()
        An array of @c SHRange that indicate the frequency skews in the reference signature that this media item describes API-Since: 16.0
      • timeRanges

        @NotNull
        public @NotNull NSArray<? extends SHRange> timeRanges()
        An array of @c SHRange that indicate the offsets within the reference signature that this media item describes API-Since: 16.0
      • creationDate

        @Nullable
        public @Nullable NSDate creationDate()
        The date when the @c SHMediaItem was created [@note] This may be fetched using the key @c SHMediaItemCreationDate API-Since: 17.0
      • useStoredAccessor

        @Deprecated
        public static boolean useStoredAccessor()
        Deprecated.