One Logo Pool Ball
_MusicKit_SwiftUI · IOS API REFERENCE

MusicSubscriptionOffer.MessageIdentifier

struct · iOS 15.0+ · SDK 27.1

struct MessageIdentifier

An identifier for the main message that the subscription offer sheet presents to the user.

Members (7)

get · iOS 15.0+

addMusic

TypeScript
get addMusic(): MusicSubscriptionOffer_MessageIdentifier
Swift declaration
static let addMusic: MusicSubscriptionOffer.MessageIdentifier

An identifier for the message that invites the user to add music to their library by subscribing to Apple Music.

get · iOS 15.0+

playMusic

TypeScript
get playMusic(): MusicSubscriptionOffer_MessageIdentifier
Swift declaration
static let playMusic: MusicSubscriptionOffer.MessageIdentifier

An identifier for the message that invites the user to play music by subscribing to Apple Music.

get · iOS 15.0+

description

TypeScript
getDescription($self: MusicSubscriptionOffer_MessageIdentifier): string
Swift declaration
var description: String { get }

A textual representation of this instance. Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the `String(describing:)` initializer. This initializer works with any type, and uses the custom `description` property for types that conform to `CustomStringConvertible`: struct Point: CustomStringConvertible { let x: Int, y: Int var description: String { return "(\(x), \(y))" } } let p = Point(x: 21, y: 30) let s = String(describing: p) print(s) // Prints "(21, 30)" The conversion of `p` to a string in the assignment to `s` uses the `Point` type's `description` property.

get · iOS 15.0+

join

TypeScript
get join(): MusicSubscriptionOffer_MessageIdentifier
Swift declaration
static let join: MusicSubscriptionOffer.MessageIdentifier

An identifier for the message that invites the user to join Apple Music.

init · iOS 15.0+

init

TypeScript
initRawValue(rawValue: string): MusicSubscriptionOffer_MessageIdentifier
Swift declaration
init(rawValue: String)

Creates a message identifier with the specified raw value.

get · iOS 15.0+

rawValue

TypeScript
getRawValue($self: MusicSubscriptionOffer_MessageIdentifier): string
Swift declaration
let rawValue: String

The corresponding value of the raw type. A new instance initialized with `rawValue` will be equivalent to this instance. For example: enum PaperSize: String { case A4, A5, Letter, Legal } let selectedSize = PaperSize.Letter print(selectedSize.rawValue) // Prints "Letter" print(selectedSize == PaperSize(rawValue: selectedSize.rawValue)!) // Prints "true"

init · iOS 15.0+

init

TypeScript
init(rawValue: string): MusicSubscriptionOffer_MessageIdentifier
Swift declaration
init(_ rawValue: String)

Creates a message identifier with the specified raw value.

Skipped declarations

No declarations were skipped in this snapshot.

All _MusicKit_SwiftUI types →