storekit

package
v0.17.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 21, 2026 License: MIT Imports: 16 Imported by: 0

Documentation

Rendered for darwin/amd64

Overview

Package storekit provides a fluent Go API over the macOS StoreKit framework.

Construction

New… functions create objects; each With… method sets one property and returns its receiver, so configuration calls chain. A <Type>FromID constructor adopts an Objective-C object obtained elsewhere.

Lifecycle

A wrapper releases its Objective-C object automatically once the garbage collector finds it unreachable. Call Release to relinquish the reference deterministically (for objects holding scarce resources); Release is idempotent, and afterwards the wrapper's methods are no-ops returning zero values.

Errors

Failing calls return errors carrying the Objective-C error domain and code. Match them against this package's Err… sentinel values with errors.Is, or inspect domain, code, and Apple's prose via errors.As with *errkit.Error.

Main-thread requirements

Methods, setters, and constructors of classes Apple isolates to the main thread run there automatically; callers never need to arrange main-thread dispatch for the generated API.

Delegates

A …Delegate interface is implemented by a plain Go value and installed with the matching With… setter; the package builds the Objective-C delegate object behind the scenes. Optional protocol methods are separate one-method …Handler interfaces — implement the ones you need on the same value and the framework calls them too.

Types

Each base type below lists the concrete types you construct and pass where the base is accepted:

Index

Constants

This section is empty.

Variables

View Source
var ErrClientInvalid = errkit.New("SKErrorDomain", 1)

ErrClientInvalid matches the StoreKit error SKErrorClientInvalid.

View Source
var ErrCloudServiceNetworkConnectionFailed = errkit.New("SKErrorDomain", 7)

ErrCloudServiceNetworkConnectionFailed matches the StoreKit error SKErrorCloudServiceNetworkConnectionFailed.

View Source
var ErrCloudServicePermissionDenied = errkit.New("SKErrorDomain", 6)

ErrCloudServicePermissionDenied matches the StoreKit error SKErrorCloudServicePermissionDenied.

View Source
var ErrCloudServiceRevoked = errkit.New("SKErrorDomain", 8)

ErrCloudServiceRevoked matches the StoreKit error SKErrorCloudServiceRevoked.

View Source
var ErrIneligibleForOffer = errkit.New("SKErrorDomain", 18)

ErrIneligibleForOffer matches the StoreKit error SKErrorIneligibleForOffer.

View Source
var ErrInvalidOfferIdentifier = errkit.New("SKErrorDomain", 11)

ErrInvalidOfferIdentifier matches the StoreKit error SKErrorInvalidOfferIdentifier.

View Source
var ErrInvalidOfferPrice = errkit.New("SKErrorDomain", 14)

ErrInvalidOfferPrice matches the StoreKit error SKErrorInvalidOfferPrice.

View Source
var ErrInvalidSignature = errkit.New("SKErrorDomain", 12)

ErrInvalidSignature matches the StoreKit error SKErrorInvalidSignature.

View Source
var ErrMissingOfferParams = errkit.New("SKErrorDomain", 13)

ErrMissingOfferParams matches the StoreKit error SKErrorMissingOfferParams.

View Source
var ErrOverlayCancelled = errkit.New("SKErrorDomain", 15)

ErrOverlayCancelled matches the StoreKit error SKErrorOverlayCancelled.

View Source
var ErrPaymentCancelled = errkit.New("SKErrorDomain", 2)

ErrPaymentCancelled matches the StoreKit error SKErrorPaymentCancelled.

View Source
var ErrPaymentInvalid = errkit.New("SKErrorDomain", 3)

ErrPaymentInvalid matches the StoreKit error SKErrorPaymentInvalid.

View Source
var ErrPaymentMethodBindingConfigurationRequired = errkit.New("SKErrorDomain", 21)

ErrPaymentMethodBindingConfigurationRequired matches the StoreKit error SKErrorPaymentMethodBindingConfigurationRequired.

View Source
var ErrPaymentNotAllowed = errkit.New("SKErrorDomain", 4)

ErrPaymentNotAllowed matches the StoreKit error SKErrorPaymentNotAllowed.

View Source
var ErrPrivacyAcknowledgementRequired = errkit.New("SKErrorDomain", 9)

ErrPrivacyAcknowledgementRequired matches the StoreKit error SKErrorPrivacyAcknowledgementRequired.

View Source
var ErrStoreProductNotAvailable = errkit.New("SKErrorDomain", 5)

ErrStoreProductNotAvailable matches the StoreKit error SKErrorStoreProductNotAvailable.

View Source
var ErrUnauthorizedRequestData = errkit.New("SKErrorDomain", 10)

ErrUnauthorizedRequestData matches the StoreKit error SKErrorUnauthorizedRequestData.

View Source
var ErrUnknown = errkit.New("SKErrorDomain", 0)

ErrUnknown matches the StoreKit error SKErrorUnknown.

View Source
var ErrUnsupportedPlatform = errkit.New("SKErrorDomain", 19)

ErrUnsupportedPlatform matches the StoreKit error SKErrorUnsupportedPlatform.

Functions

func CanMakePayments added in v0.17.0

func CanMakePayments() bool

CanMakePayments reports whether a method that indicates whether the person can make purchases.

func ContentURLForProductID added in v0.17.0

func ContentURLForProductID(productID string) string

ContentURLForProductID returns the local location for the previously downloaded flie.

func DeleteContentForProductID added in v0.17.0

func DeleteContentForProductID(productID string)

DeleteContentForProductID deletes the previously downloaded file.

func RepairArcadeApp added in v0.17.0

func RepairArcadeApp()

RepairArcadeApp wraps the corresponding Objective-C method.

func RequestReview added in v0.17.0

func RequestReview()

RequestReview tells StoreKit to ask the customer to rate or review your app, if appropriate.

func SKCloudServiceCapabilitiesDidChangeNotification

func SKCloudServiceCapabilitiesDidChangeNotification() uintptr

SKCloudServiceCapabilitiesDidChangeNotification returns the address of the symbol SKCloudServiceCapabilitiesDidChangeNotification.

func SKDownloadTimeRemainingUnknown

func SKDownloadTimeRemainingUnknown() float64

SKDownloadTimeRemainingUnknown returns the value of the constant SKDownloadTimeRemainingUnknown.

func SKErrorDomain

func SKErrorDomain() obj.Object

SKErrorDomain returns the string constant SKErrorDomain, for use as a dictionary key or argument.

func SKReceiptPropertyIsExpired

func SKReceiptPropertyIsExpired() obj.Object

SKReceiptPropertyIsExpired returns the string constant SKReceiptPropertyIsExpired, for use as a dictionary key or argument.

func SKReceiptPropertyIsRevoked

func SKReceiptPropertyIsRevoked() obj.Object

SKReceiptPropertyIsRevoked returns the string constant SKReceiptPropertyIsRevoked, for use as a dictionary key or argument.

func SKReceiptPropertyIsVolumePurchase

func SKReceiptPropertyIsVolumePurchase() obj.Object

SKReceiptPropertyIsVolumePurchase returns the string constant SKReceiptPropertyIsVolumePurchase, for use as a dictionary key or argument.

func SKStoreProductParameterAdvertisingPartnerToken

func SKStoreProductParameterAdvertisingPartnerToken() obj.Object

SKStoreProductParameterAdvertisingPartnerToken returns the string constant SKStoreProductParameterAdvertisingPartnerToken, for use as a dictionary key or argument.

func SKStoreProductParameterAffiliateToken

func SKStoreProductParameterAffiliateToken() obj.Object

SKStoreProductParameterAffiliateToken returns the string constant SKStoreProductParameterAffiliateToken, for use as a dictionary key or argument.

func SKStoreProductParameterCampaignToken

func SKStoreProductParameterCampaignToken() obj.Object

SKStoreProductParameterCampaignToken returns the string constant SKStoreProductParameterCampaignToken, for use as a dictionary key or argument.

func SKStoreProductParameterCustomProductPageIdentifier

func SKStoreProductParameterCustomProductPageIdentifier() obj.Object

SKStoreProductParameterCustomProductPageIdentifier returns the string constant SKStoreProductParameterCustomProductPageIdentifier, for use as a dictionary key or argument.

func SKStoreProductParameterITunesItemIdentifier

func SKStoreProductParameterITunesItemIdentifier() obj.Object

SKStoreProductParameterITunesItemIdentifier returns the string constant SKStoreProductParameterITunesItemIdentifier, for use as a dictionary key or argument.

func SKStoreProductParameterProductIdentifier

func SKStoreProductParameterProductIdentifier() obj.Object

SKStoreProductParameterProductIdentifier returns the string constant SKStoreProductParameterProductIdentifier, for use as a dictionary key or argument.

func SKStoreProductParameterProviderToken

func SKStoreProductParameterProviderToken() obj.Object

SKStoreProductParameterProviderToken returns the string constant SKStoreProductParameterProviderToken, for use as a dictionary key or argument.

func SKStorefrontCountryCodeDidChangeNotification

func SKStorefrontCountryCodeDidChangeNotification() uintptr

SKStorefrontCountryCodeDidChangeNotification returns the address of the symbol SKStorefrontCountryCodeDidChangeNotification.

func SKStorefrontIdentifierDidChangeNotification

func SKStorefrontIdentifierDidChangeNotification() uintptr

SKStorefrontIdentifierDidChangeNotification returns the address of the symbol SKStorefrontIdentifierDidChangeNotification.

func SKTerminateForInvalidReceipt

func SKTerminateForInvalidReceipt()

SKTerminateForInvalidReceipt calls the StoreKit framework function SKTerminateForInvalidReceipt.

Types

type ArcadeService added in v0.17.0

type ArcadeService struct {
	objref.Handle
}

ArcadeService is an idiomatic wrapper over the Objective-C class SKArcadeService.

func ArcadeServiceFromID added in v0.17.0

func ArcadeServiceFromID(id objc.ID) *ArcadeService

ArcadeServiceFromID adopts an existing Objective-C object as a ArcadeService (nil for 0), retaining it and registering a release finalizer.

func NewArcadeService added in v0.17.0

func NewArcadeService() *ArcadeService

NewArcadeService creates a new ArcadeService.

func (*ArcadeService) Description added in v0.17.0

func (as *ArcadeService) Description() string

Description returns the object's -description text.

func (*ArcadeService) IsEqual added in v0.17.0

func (as *ArcadeService) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*ArcadeService) IsKind added in v0.17.0

func (as *ArcadeService) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*ArcadeService) String added in v0.17.0

func (as *ArcadeService) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

type CGLCPContextPriorityRequest

type CGLCPContextPriorityRequest int64
const (
	KCGLCPContextPriorityRequestHigh   CGLCPContextPriorityRequest = 0
	KCGLCPContextPriorityRequestNormal CGLCPContextPriorityRequest = 1
	KCGLCPContextPriorityRequestLow    CGLCPContextPriorityRequest = 2
)

func (CGLCPContextPriorityRequest) String

String returns the CGLCPContextPriorityRequest constant's name, or its numeric form when the value is not a known constant.

type Clockid added in v0.17.0

type Clockid int64
const (
	ClockidRealtime           Clockid = 0
	ClockidMonotonic          Clockid = 6
	ClockidMonotonicRaw       Clockid = 4
	ClockidMonotonicRawApprox Clockid = 5
	ClockidUptimeRaw          Clockid = 8
	ClockidUptimeRawApprox    Clockid = 9
	ClockidProcessCputimeID   Clockid = 12
	ClockidThreadCputimeID    Clockid = 16
)

func (Clockid) String added in v0.17.0

func (e Clockid) String() string

String returns the Clockid constant's name, or its numeric form when the value is not a known constant.

type CloudServiceAuthorizationStatus deprecated added in v0.17.0

type CloudServiceAuthorizationStatus int64

Constants that indicate the type of authorization the customer has for accessing the Music library.

Deprecated: Use MusicAuthorization.Status from MusicKit.

const (
	// The authorization type cannot be determined.
	CloudServiceAuthorizationStatusNotDetermined CloudServiceAuthorizationStatus = 0
	// The user does not authorize any access to their music library.
	CloudServiceAuthorizationStatusDenied CloudServiceAuthorizationStatus = 1
	// Access to the music library is restricted in a way that the user cannot change, so your app should not prompt for authorization. An example of this situation is if the device is in an education mode.
	CloudServiceAuthorizationStatusRestricted CloudServiceAuthorizationStatus = 2
	// The user authorizes playback of Apple Music tracks and the addition of tracks to their music library.
	CloudServiceAuthorizationStatusAuthorized CloudServiceAuthorizationStatus = 3
)

func AuthorizationStatus added in v0.17.0

func AuthorizationStatus() CloudServiceAuthorizationStatus

AuthorizationStatus returns the type of authorization the customer has for accessing the Music library on the device.

func (CloudServiceAuthorizationStatus) String added in v0.17.0

String returns the CloudServiceAuthorizationStatus constant's name, or its numeric form when the value is not a known constant.

type CloudServiceCapability deprecated added in v0.17.0

type CloudServiceCapability uint64

Constants that specify the current capabilities of the customer’s Music library on the device.

Deprecated: Use MusicSubscription from MusicKit. Bitmask — values may be combined with |.

const (
	// The device does not allow playback of Apple Music content or the addition of tracks to the music library.
	//
	// Deprecated: Use MusicAuthorization.Status from MusicKit.
	CloudServiceCapabilityNone CloudServiceCapability = 0
	// The device allows playback of Apple Music catalog tracks.
	CloudServiceCapabilityMusicCatalogPlayback CloudServiceCapability = 1
	// The device allows subscription to the Apple Music catalog.
	//
	// Deprecated: Use the canBecomeSubscriber property of MusicSubscription from MusicKit.
	CloudServiceCapabilityMusicCatalogSubscriptionEligible CloudServiceCapability = 2
	// The device allows tracks to be added to the user’s music library.
	//
	// Deprecated: Use the canBecomeSubscriber property of MusicSubscription from MusicKit.
	CloudServiceCapabilityAddToCloudMusicLibrary CloudServiceCapability = 256
)

func (CloudServiceCapability) String added in v0.17.0

func (e CloudServiceCapability) String() string

String returns the CloudServiceCapability constant's name, or its numeric form when the value is not a known constant.

type CloudServiceController added in v0.17.0

type CloudServiceController struct {
	objref.Handle
}

CloudServiceController is an idiomatic wrapper over the Objective-C class SKCloudServiceController.

An object that determines the current capabilities of a person’s Music library.

func CloudServiceControllerFromID added in v0.17.0

func CloudServiceControllerFromID(id objc.ID) *CloudServiceController

CloudServiceControllerFromID adopts an existing Objective-C object as a CloudServiceController (nil for 0), retaining it and registering a release finalizer.

func NewCloudServiceController added in v0.17.0

func NewCloudServiceController() *CloudServiceController

NewCloudServiceController creates a new CloudServiceController.

func (*CloudServiceController) Description added in v0.17.0

func (csc *CloudServiceController) Description() string

Description returns the object's -description text.

func (*CloudServiceController) IsEqual added in v0.17.0

func (csc *CloudServiceController) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*CloudServiceController) IsKind added in v0.17.0

func (csc *CloudServiceController) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*CloudServiceController) RequestStorefrontCountryCode added in v0.17.0

func (csc *CloudServiceController) RequestStorefrontCountryCode(ctx context.Context) (result string, err error)

RequestStorefrontCountryCode gets the country code for the storefront associated with a customer’s iTunes account.

RequestStorefrontCountryCode blocks until the operation completes or ctx is cancelled.

func (*CloudServiceController) RequestStorefrontIdentifier added in v0.17.0

func (csc *CloudServiceController) RequestStorefrontIdentifier(ctx context.Context) (result string, err error)

RequestStorefrontIdentifier gets the device’s storefront identifier.

RequestStorefrontIdentifier blocks until the operation completes or ctx is cancelled.

func (*CloudServiceController) RequestUserTokenForDeveloperToken added in v0.17.0

func (csc *CloudServiceController) RequestUserTokenForDeveloperToken(ctx context.Context, developerToken string) (result string, err error)

RequestUserTokenForDeveloperToken returns a user token that you use to access personalized Apple Music content.

RequestUserTokenForDeveloperToken blocks until the operation completes or ctx is cancelled.

func (*CloudServiceController) String added in v0.17.0

func (csc *CloudServiceController) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

type DispatchAutoreleaseFrequency added in v0.17.0

type DispatchAutoreleaseFrequency uint64
const (
	DispatchAutoreleaseFrequencyInherit  DispatchAutoreleaseFrequency = 0
	DispatchAutoreleaseFrequencyWorkItem DispatchAutoreleaseFrequency = 1
	DispatchAutoreleaseFrequencyNever    DispatchAutoreleaseFrequency = 2
)

func (DispatchAutoreleaseFrequency) String added in v0.17.0

String returns the DispatchAutoreleaseFrequency constant's name, or its numeric form when the value is not a known constant.

type DispatchBlockFlags added in v0.17.0

type DispatchBlockFlags uint64

Bitmask — values may be combined with |.

const (
	DispatchBlockFlagsBarrier         DispatchBlockFlags = 1
	DispatchBlockFlagsDetached        DispatchBlockFlags = 2
	DispatchBlockFlagsAssignCurrent   DispatchBlockFlags = 4
	DispatchBlockFlagsNoQosClass      DispatchBlockFlags = 8
	DispatchBlockFlagsInheritQosClass DispatchBlockFlags = 16
	DispatchBlockFlagsEnforceQosClass DispatchBlockFlags = 32
)

func (DispatchBlockFlags) String added in v0.17.0

func (e DispatchBlockFlags) String() string

String returns the DispatchBlockFlags constant's name, or its numeric form when the value is not a known constant.

type Download added in v0.17.0

type Download struct {
	objref.Handle
}

Download is an idiomatic wrapper over the Objective-C class SKDownload.

Downloadable content associated with a product.

func DownloadFromID added in v0.17.0

func DownloadFromID(id objc.ID) *Download

DownloadFromID adopts an existing Objective-C object as a Download (nil for 0), retaining it and registering a release finalizer.

func NewDownload added in v0.17.0

func NewDownload() *Download

NewDownload creates a new Download.

func (*Download) ContentIdentifier added in v0.17.0

func (d *Download) ContentIdentifier() string

ContentIdentifier returns the content identifier.

func (*Download) ContentURL added in v0.17.0

func (d *Download) ContentURL() string

ContentURL returns the content URL.

func (*Download) ContentVersion added in v0.17.0

func (d *Download) ContentVersion() string

ContentVersion returns the content version.

func (*Download) Description added in v0.17.0

func (d *Download) Description() string

Description returns the object's -description text.

func (*Download) ExpectedContentLength added in v0.17.0

func (d *Download) ExpectedContentLength() int64

ExpectedContentLength returns the expected content length.

func (*Download) IsEqual added in v0.17.0

func (d *Download) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*Download) IsKind added in v0.17.0

func (d *Download) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*Download) Progress added in v0.17.0

func (d *Download) Progress() float32

Progress returns the progress.

func (*Download) State added in v0.17.0

func (d *Download) State() DownloadState

State returns the state.

func (*Download) String added in v0.17.0

func (d *Download) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

func (*Download) TimeRemaining added in v0.17.0

func (d *Download) TimeRemaining() float64

TimeRemaining returns the time remaining.

func (*Download) Transaction added in v0.17.0

func (d *Download) Transaction() *PaymentTransaction

Transaction returns the transaction.

type DownloadState deprecated added in v0.17.0

type DownloadState int64

The states that a download operation can be in.

Deprecated: Hosted content is no longer supported.

const (
	// Indicates that the download has not started yet.
	DownloadStateWaiting DownloadState = 0
	// Indicates that the content is currently being downloaded.
	DownloadStateActive DownloadState = 1
	// Indicates that your app paused the download.
	DownloadStatePaused DownloadState = 2
	// Indicates that the content was successfully downloaded.
	DownloadStateFinished DownloadState = 3
	// Indicates that an error occurred while the file was being downloaded.
	DownloadStateFailed DownloadState = 4
	// Indicates that your app canceled the download.
	DownloadStateCancelled DownloadState = 5
)

func (DownloadState) String added in v0.17.0

func (e DownloadState) String() string

String returns the DownloadState constant's name, or its numeric form when the value is not a known constant.

type DownloaderExtension added in v0.17.0

type DownloaderExtension interface {
}

DownloaderExtension is the Go form of the Objective-C protocol SKDownloaderExtension.

type EntryID added in v0.17.0

type EntryID int64
const (
	EntryIDFirstEntry EntryID = 0
	EntryIDNextEntry  EntryID = -1
	EntryIDLastEntry  EntryID = -2
)

func (EntryID) String added in v0.17.0

func (e EntryID) String() string

String returns the EntryID constant's name, or its numeric form when the value is not a known constant.

type ErrorCode added in v0.17.0

type ErrorCode int64

Error codes for StoreKit errors.

const (
	ErrorUnknown                                   ErrorCode = 0
	ErrorClientInvalid                             ErrorCode = 1
	ErrorPaymentCancelled                          ErrorCode = 2
	ErrorPaymentInvalid                            ErrorCode = 3
	ErrorPaymentNotAllowed                         ErrorCode = 4
	ErrorStoreProductNotAvailable                  ErrorCode = 5
	ErrorCloudServicePermissionDenied              ErrorCode = 6
	ErrorCloudServiceNetworkConnectionFailed       ErrorCode = 7
	ErrorCloudServiceRevoked                       ErrorCode = 8
	ErrorPrivacyAcknowledgementRequired            ErrorCode = 9
	ErrorUnauthorizedRequestData                   ErrorCode = 10
	ErrorInvalidOfferIdentifier                    ErrorCode = 11
	ErrorInvalidSignature                          ErrorCode = 12
	ErrorMissingOfferParams                        ErrorCode = 13
	ErrorInvalidOfferPrice                         ErrorCode = 14
	ErrorOverlayCancelled                          ErrorCode = 15
	ErrorIneligibleForOffer                        ErrorCode = 18
	ErrorUnsupportedPlatform                       ErrorCode = 19
	ErrorPaymentMethodBindingConfigurationRequired ErrorCode = 21
)

func (ErrorCode) String added in v0.17.0

func (e ErrorCode) String() string

String returns the ErrorCode constant's name, or its numeric form when the value is not a known constant.

type EvCmd

type EvCmd int64
const (
	EVNOP   EvCmd = 0
	EVHIDE  EvCmd = 1
	EVSHOW  EvCmd = 2
	EVMOVE  EvCmd = 3
	EVLEVEL EvCmd = 4
)

func (EvCmd) String

func (e EvCmd) String() string

String returns the EvCmd constant's name, or its numeric form when the value is not a known constant.

type FilesecProperty added in v0.17.0

type FilesecProperty int64
const (
	FilesecPropertyOwner        FilesecProperty = 1
	FilesecPropertyGroup        FilesecProperty = 2
	FilesecPropertyUUID         FilesecProperty = 3
	FilesecPropertyMode         FilesecProperty = 4
	FilesecPropertyACL          FilesecProperty = 5
	FilesecPropertyGrpuuid      FilesecProperty = 6
	FilesecPropertyACLRaw       FilesecProperty = 100
	FilesecPropertyACLAllocsize FilesecProperty = 101
)

func (FilesecProperty) String added in v0.17.0

func (e FilesecProperty) String() string

String returns the FilesecProperty constant's name, or its numeric form when the value is not a known constant.

type Flag added in v0.17.0

type Flag int64
const (
	FlagFlagDeferInherit      Flag = 1
	FlagFlagNoInherit         Flag = 131072
	FlagEntryInherited        Flag = 16
	FlagEntryFileInherit      Flag = 32
	FlagEntryDirectoryInherit Flag = 64
	FlagEntryLimitInherit     Flag = 128
	FlagEntryOnlyInherit      Flag = 256
)

func (Flag) String added in v0.17.0

func (e Flag) String() string

String returns the Flag constant's name, or its numeric form when the value is not a known constant.

type Idtype added in v0.17.0

type Idtype int64
const (
	IdtypeAll  Idtype = 0
	IdtypePid  Idtype = 1
	IdtypePgid Idtype = 2
)

func (Idtype) String added in v0.17.0

func (e Idtype) String() string

String returns the Idtype constant's name, or its numeric form when the value is not a known constant.

type IpcInfoObjectType added in v0.17.0

type IpcInfoObjectType int64
const (
	IpcInfoObjectTypeNone               IpcInfoObjectType = 0
	IpcInfoObjectTypeThreadControl      IpcInfoObjectType = 1
	IpcInfoObjectTypeTaskControl        IpcInfoObjectType = 2
	IpcInfoObjectTypeHost               IpcInfoObjectType = 3
	IpcInfoObjectTypeHostPriv           IpcInfoObjectType = 4
	IpcInfoObjectTypeProcessor          IpcInfoObjectType = 5
	IpcInfoObjectTypeProcessorSet       IpcInfoObjectType = 6
	IpcInfoObjectTypeProcessorSetName   IpcInfoObjectType = 7
	IpcInfoObjectTypeTimer              IpcInfoObjectType = 8
	IpcInfoObjectTypePortSubstOnce      IpcInfoObjectType = 9
	IpcInfoObjectTypeMig                IpcInfoObjectType = 10
	IpcInfoObjectTypeMemoryObject       IpcInfoObjectType = 11
	IpcInfoObjectTypeXmmPager           IpcInfoObjectType = 12
	IpcInfoObjectTypeXmmKernel          IpcInfoObjectType = 13
	IpcInfoObjectTypeXmmReply           IpcInfoObjectType = 14
	IpcInfoObjectTypeUndReply           IpcInfoObjectType = 15
	IpcInfoObjectTypeHostNotify         IpcInfoObjectType = 16
	IpcInfoObjectTypeHostSecurity       IpcInfoObjectType = 17
	IpcInfoObjectTypeLedger             IpcInfoObjectType = 18
	IpcInfoObjectTypeMainDevice         IpcInfoObjectType = 19
	IpcInfoObjectTypeTaskName           IpcInfoObjectType = 20
	IpcInfoObjectTypeSubsystem          IpcInfoObjectType = 21
	IpcInfoObjectTypeIODoneQueue        IpcInfoObjectType = 22
	IpcInfoObjectTypeSemaphore          IpcInfoObjectType = 23
	IpcInfoObjectTypeLockSet            IpcInfoObjectType = 24
	IpcInfoObjectTypeClock              IpcInfoObjectType = 25
	IpcInfoObjectTypeClockCtrl          IpcInfoObjectType = 26
	IpcInfoObjectTypeIokitIdent         IpcInfoObjectType = 27
	IpcInfoObjectTypeNamedEntry         IpcInfoObjectType = 28
	IpcInfoObjectTypeIokitConnect       IpcInfoObjectType = 29
	IpcInfoObjectTypeIokitObject        IpcInfoObjectType = 30
	IpcInfoObjectTypeUpl                IpcInfoObjectType = 31
	IpcInfoObjectTypeMemObjControl      IpcInfoObjectType = 32
	IpcInfoObjectTypeAuSessionport      IpcInfoObjectType = 33
	IpcInfoObjectTypeFileport           IpcInfoObjectType = 34
	IpcInfoObjectTypeLabelh             IpcInfoObjectType = 35
	IpcInfoObjectTypeTaskResume         IpcInfoObjectType = 36
	IpcInfoObjectTypeVoucher            IpcInfoObjectType = 37
	IpcInfoObjectTypeVoucherAttrControl IpcInfoObjectType = 38
	IpcInfoObjectTypeWorkInterval       IpcInfoObjectType = 39
	IpcInfoObjectTypeUxHandler          IpcInfoObjectType = 40
	IpcInfoObjectTypeUextObject         IpcInfoObjectType = 41
	IpcInfoObjectTypeArcadeReg          IpcInfoObjectType = 42
	IpcInfoObjectTypeEventlink          IpcInfoObjectType = 43
	IpcInfoObjectTypeTaskInspect        IpcInfoObjectType = 44
	IpcInfoObjectTypeTaskRead           IpcInfoObjectType = 45
	IpcInfoObjectTypeThreadInspect      IpcInfoObjectType = 46
	IpcInfoObjectTypeThreadRead         IpcInfoObjectType = 47
	IpcInfoObjectTypeSuidCred           IpcInfoObjectType = 48
	IpcInfoObjectTypeHypervisor         IpcInfoObjectType = 49
	IpcInfoObjectTypeTaskIDToken        IpcInfoObjectType = 50
	IpcInfoObjectTypeTaskFatal          IpcInfoObjectType = 51
	IpcInfoObjectTypeKcdata             IpcInfoObjectType = 52
	IpcInfoObjectTypeExclavesResource   IpcInfoObjectType = 53
	IpcInfoObjectTypeThreadResume       IpcInfoObjectType = 54
	IpcInfoObjectTypeUnknown            IpcInfoObjectType = 4294967295
)

func (IpcInfoObjectType) String added in v0.17.0

func (e IpcInfoObjectType) String() string

String returns the IpcInfoObjectType constant's name, or its numeric form when the value is not a known constant.

type LaunchDataType added in v0.17.0

type LaunchDataType int64
const (
	LaunchDataTypeDictionary LaunchDataType = 1
	LaunchDataTypeArray      LaunchDataType = 2
	LaunchDataTypeFd         LaunchDataType = 3
	LaunchDataTypeInteger    LaunchDataType = 4
	LaunchDataTypeReal       LaunchDataType = 5
	LaunchDataTypeBool       LaunchDataType = 6
	LaunchDataTypeString     LaunchDataType = 7
	LaunchDataTypeOpaque     LaunchDataType = 8
	LaunchDataTypeErrno      LaunchDataType = 9
	LaunchDataTypeMachport   LaunchDataType = 10
)

func (LaunchDataType) String added in v0.17.0

func (e LaunchDataType) String() string

String returns the LaunchDataType constant's name, or its numeric form when the value is not a known constant.

type MDLabelDomain

type MDLabelDomain int64

These constants are used to specify a domain to MDLabelCreate().

const (
	KMDLabelUserDomain  MDLabelDomain = 0
	KMDLabelLocalDomain MDLabelDomain = 1
)

func (MDLabelDomain) String

func (e MDLabelDomain) String() string

String returns the MDLabelDomain constant's name, or its numeric form when the value is not a known constant.

type MDQueryOptionFlags

type MDQueryOptionFlags int64
const (
	KMDQuerySynchronous        MDQueryOptionFlags = 1
	KMDQueryWantsUpdates       MDQueryOptionFlags = 4
	KMDQueryAllowFSTranslation MDQueryOptionFlags = 8
)

func (MDQueryOptionFlags) String

func (e MDQueryOptionFlags) String() string

String returns the MDQueryOptionFlags constant's name, or its numeric form when the value is not a known constant.

type MDQuerySortOptionFlags

type MDQuerySortOptionFlags int64
const (
	KMDQueryReverseSortOrderFlag MDQuerySortOptionFlags = 1
)

func (MDQuerySortOptionFlags) String

func (e MDQuerySortOptionFlags) String() string

String returns the MDQuerySortOptionFlags constant's name, or its numeric form when the value is not a known constant.

type MachVMRangeFlags added in v0.17.0

type MachVMRangeFlags int64

Bitmask — values may be combined with |.

const (
	MachVMRangeFlagsNone MachVMRangeFlags = 0
)

func (MachVMRangeFlags) String added in v0.17.0

func (e MachVMRangeFlags) String() string

String returns the MachVMRangeFlags constant's name, or its numeric form when the value is not a known constant.

type MachVMRangeFlavor added in v0.17.0

type MachVMRangeFlavor int64
const (
	MachVMRangeFlavorInvalid MachVMRangeFlavor = 0
	MachVMRangeFlavorV1      MachVMRangeFlavor = 1
)

func (MachVMRangeFlavor) String added in v0.17.0

func (e MachVMRangeFlavor) String() string

String returns the MachVMRangeFlavor constant's name, or its numeric form when the value is not a known constant.

type MachVMRangeTag added in v0.17.0

type MachVMRangeTag int64
const (
	MachVMRangeTagDefault MachVMRangeTag = 0
	MachVMRangeTagData    MachVMRangeTag = 1
	MachVMRangeTagFixed   MachVMRangeTag = 2
)

func (MachVMRangeTag) String added in v0.17.0

func (e MachVMRangeTag) String() string

String returns the MachVMRangeTag constant's name, or its numeric form when the value is not a known constant.

type MpoFlags added in v0.17.0

type MpoFlags int64

Bitmask — values may be combined with |.

const (
	MpoFlagsPort                        MpoFlags = 0
	MpoFlagsServicePort                 MpoFlags = 1024
	MpoFlagsConnectionPort              MpoFlags = 2048
	MpoFlagsReplyPort                   MpoFlags = 4096
	MpoFlagsWeakReplyPort               MpoFlags = 16384
	MpoFlagsNotificationPort            MpoFlags = 17408
	MpoFlagsExceptionPort               MpoFlags = 32768
	MpoFlagsConnectionPortWithPortArray MpoFlags = 65536
)

func (MpoFlags) String added in v0.17.0

func (e MpoFlags) String() string

String returns the MpoFlags constant's name, or its numeric form when the value is not a known constant.

type MutablePayment added in v0.17.0

type MutablePayment struct {
	Payment
}

MutablePayment is an idiomatic wrapper over the Objective-C class SKMutablePayment.

It embeds Payment, promoting that type's methods.

A mutable request to the App Store to process payment for additional functionality that your app offers.

func MutablePaymentFromID added in v0.17.0

func MutablePaymentFromID(id objc.ID) *MutablePayment

MutablePaymentFromID adopts an existing Objective-C object as a MutablePayment (nil for 0), retaining it and registering a release finalizer.

func NewMutablePayment added in v0.17.0

func NewMutablePayment() *MutablePayment

NewMutablePayment creates a new MutablePayment.

func (*MutablePayment) ProductIdentifier added in v0.17.0

func (mp *MutablePayment) ProductIdentifier() string

ProductIdentifier returns the product identifier.

func (*MutablePayment) WithApplicationUsername added in v0.17.0

func (mp *MutablePayment) WithApplicationUsername(applicationUsername string) *MutablePayment

WithApplicationUsername sets a string that associates the transaction with a user account on your service.

func (*MutablePayment) WithPaymentDiscount added in v0.17.0

func (mp *MutablePayment) WithPaymentDiscount(paymentDiscount *PaymentDiscount) *MutablePayment

WithPaymentDiscount sets the details of the discount offer to apply to the payment.

func (*MutablePayment) WithProductIdentifier added in v0.17.0

func (mp *MutablePayment) WithProductIdentifier(productIdentifier string) *MutablePayment

WithProductIdentifier sets a string that identifies a product that can be purchased from within your app.

func (*MutablePayment) WithQuantity added in v0.17.0

func (mp *MutablePayment) WithQuantity(quantity int) *MutablePayment

WithQuantity sets the number of items the user wants to purchase.

func (*MutablePayment) WithRequestData added in v0.17.0

func (mp *MutablePayment) WithRequestData(requestData []byte) *MutablePayment

WithRequestData sets reserved for future use.

func (*MutablePayment) WithSimulatesAskToBuyInSandbox added in v0.17.0

func (mp *MutablePayment) WithSimulatesAskToBuyInSandbox(simulatesAskToBuyInSandbox bool) *MutablePayment

WithSimulatesAskToBuyInSandbox sets a Boolean value that produces an “ask to buy” flow for this payment in the sandbox.

type NXMouseButton

type NXMouseButton int64
const (
	NX_OneButton   NXMouseButton = 0
	NX_LeftButton  NXMouseButton = 1
	NX_RightButton NXMouseButton = 2
)

func (NXMouseButton) String

func (e NXMouseButton) String() string

String returns the NXMouseButton constant's name, or its numeric form when the value is not a known constant.

type OSClockid added in v0.17.0

type OSClockid int64
const (
	OSClockidTime OSClockid = 32
)

func (OSClockid) String added in v0.17.0

func (e OSClockid) String() string

String returns the OSClockid constant's name, or its numeric form when the value is not a known constant.

type OSUnfairLockFlags added in v0.17.0

type OSUnfairLockFlags int64

Bitmask — values may be combined with |.

const (
	OSUnfairLockFlagsNone         OSUnfairLockFlags = 0
	OSUnfairLockFlagsAdaptiveSpin OSUnfairLockFlags = 262144
)

func (OSUnfairLockFlags) String added in v0.17.0

func (e OSUnfairLockFlags) String() string

String returns the OSUnfairLockFlags constant's name, or its numeric form when the value is not a known constant.

type PMPageToPaperMappingType

type PMPageToPaperMappingType int64
const (
	KPMPageToPaperMappingNone       PMPageToPaperMappingType = 1
	KPMPageToPaperMappingScaleToFit PMPageToPaperMappingType = 2
)

func (PMPageToPaperMappingType) String

func (e PMPageToPaperMappingType) String() string

String returns the PMPageToPaperMappingType constant's name, or its numeric form when the value is not a known constant.

type Payment added in v0.17.0

type Payment struct {
	objref.Handle
}

Payment is an idiomatic wrapper over the Objective-C class SKPayment.

Payment is an abstract base — you do not construct it directly. Construct one of MutablePayment and pass it where a Payment is accepted.

A request to the App Store to process payment for additional functionality that your app offers.

func PaymentFromID added in v0.17.0

func PaymentFromID(id objc.ID) *Payment

PaymentFromID adopts an existing Objective-C object as a Payment (nil for 0), retaining it and registering a release finalizer.

func PaymentWithProduct added in v0.17.0

func PaymentWithProduct(product *Product) *Payment

PaymentWithProduct returns a new payment for the specified product.

func (*Payment) ApplicationUsername added in v0.17.0

func (p *Payment) ApplicationUsername() string

ApplicationUsername returns the application username.

func (*Payment) Description added in v0.17.0

func (p *Payment) Description() string

Description returns the object's -description text.

func (*Payment) IsEqual added in v0.17.0

func (p *Payment) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*Payment) IsKind added in v0.17.0

func (p *Payment) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*Payment) PaymentDiscount added in v0.17.0

func (p *Payment) PaymentDiscount() *PaymentDiscount

PaymentDiscount returns the payment discount.

func (*Payment) Quantity added in v0.17.0

func (p *Payment) Quantity() int

Quantity returns the quantity.

func (*Payment) RequestData added in v0.17.0

func (p *Payment) RequestData() []byte

RequestData returns the request data.

func (*Payment) SimulatesAskToBuyInSandbox added in v0.17.0

func (p *Payment) SimulatesAskToBuyInSandbox() bool

SimulatesAskToBuyInSandbox wraps the corresponding Objective-C method.

func (*Payment) String added in v0.17.0

func (p *Payment) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

type PaymentDiscount added in v0.17.0

type PaymentDiscount struct {
	objref.Handle
}

PaymentDiscount is an idiomatic wrapper over the Objective-C class SKPaymentDiscount.

The signed discount to apply to a payment.

func NewPaymentDiscountWithIdentifierKeyIdentifierNonceSignatureTimestamp added in v0.17.0

func NewPaymentDiscountWithIdentifierKeyIdentifierNonceSignatureTimestamp(identifier string, keyIdentifier string, nonce obj.Object, signature string, timestamp obj.Object) *PaymentDiscount

NewPaymentDiscountWithIdentifierKeyIdentifierNonceSignatureTimestamp initializes the payment discount with a signature and the parameters used by the signature.

func PaymentDiscountFromID added in v0.17.0

func PaymentDiscountFromID(id objc.ID) *PaymentDiscount

PaymentDiscountFromID adopts an existing Objective-C object as a PaymentDiscount (nil for 0), retaining it and registering a release finalizer.

func (*PaymentDiscount) Description added in v0.17.0

func (pd *PaymentDiscount) Description() string

Description returns the object's -description text.

func (*PaymentDiscount) Identifier added in v0.17.0

func (pd *PaymentDiscount) Identifier() string

Identifier returns the identifier.

func (*PaymentDiscount) IsEqual added in v0.17.0

func (pd *PaymentDiscount) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*PaymentDiscount) IsKind added in v0.17.0

func (pd *PaymentDiscount) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*PaymentDiscount) KeyIdentifier added in v0.17.0

func (pd *PaymentDiscount) KeyIdentifier() string

KeyIdentifier returns the key identifier.

func (*PaymentDiscount) Nonce added in v0.17.0

func (pd *PaymentDiscount) Nonce() *foundation.UUID

Nonce returns the nonce.

func (*PaymentDiscount) Signature added in v0.17.0

func (pd *PaymentDiscount) Signature() string

Signature returns the signature.

func (*PaymentDiscount) String added in v0.17.0

func (pd *PaymentDiscount) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

func (*PaymentDiscount) Timestamp added in v0.17.0

func (pd *PaymentDiscount) Timestamp() *foundation.Number

Timestamp returns the timestamp.

type PaymentProvider added in v0.17.0

type PaymentProvider interface {
	objref.Object
	// contains filtered or unexported methods
}

PaymentProvider is accepted wherever a SKPayment (or one of its subclasses) is expected.

type PaymentQueue added in v0.17.0

type PaymentQueue struct {
	objref.Handle
}

PaymentQueue is an idiomatic wrapper over the Objective-C class SKPaymentQueue.

A queue of payment transactions for the App Store to process.

func DefaultQueue added in v0.17.0

func DefaultQueue() *PaymentQueue

DefaultQueue returns the default payment queue instance.

func NewPaymentQueue added in v0.17.0

func NewPaymentQueue() *PaymentQueue

NewPaymentQueue creates a new PaymentQueue.

func PaymentQueueFromID added in v0.17.0

func PaymentQueueFromID(id objc.ID) *PaymentQueue

PaymentQueueFromID adopts an existing Objective-C object as a PaymentQueue (nil for 0), retaining it and registering a release finalizer.

func (*PaymentQueue) AddPayment added in v0.17.0

func (pq *PaymentQueue) AddPayment(payment *Payment)

AddPayment adds a payment request to the queue.

func (*PaymentQueue) CancelDownloads added in v0.17.0

func (pq *PaymentQueue) CancelDownloads(downloads []*Download)

CancelDownloads removes a set of downloads from the download list.

func (*PaymentQueue) Description added in v0.17.0

func (pq *PaymentQueue) Description() string

Description returns the object's -description text.

func (*PaymentQueue) FinishTransaction added in v0.17.0

func (pq *PaymentQueue) FinishTransaction(transaction *PaymentTransaction)

FinishTransaction notifies the App Store that the app finished processing the transaction.

func (*PaymentQueue) IsEqual added in v0.17.0

func (pq *PaymentQueue) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*PaymentQueue) IsKind added in v0.17.0

func (pq *PaymentQueue) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*PaymentQueue) PauseDownloads added in v0.17.0

func (pq *PaymentQueue) PauseDownloads(downloads []*Download)

PauseDownloads pauses a set of downloads.

func (*PaymentQueue) RestoreCompletedTransactions added in v0.17.0

func (pq *PaymentQueue) RestoreCompletedTransactions()

RestoreCompletedTransactions asks the payment queue to restore previously completed purchases.

func (*PaymentQueue) RestoreCompletedTransactionsWithApplicationUsername added in v0.17.0

func (pq *PaymentQueue) RestoreCompletedTransactionsWithApplicationUsername(username string)

RestoreCompletedTransactionsWithApplicationUsername asks the payment queue to restore previously completed purchases, providing an opaque identifier for the user’s account.

func (*PaymentQueue) ResumeDownloads added in v0.17.0

func (pq *PaymentQueue) ResumeDownloads(downloads []*Download)

ResumeDownloads resumes a set of downloads.

func (*PaymentQueue) StartDownloads added in v0.17.0

func (pq *PaymentQueue) StartDownloads(downloads []*Download)

StartDownloads adds a set of downloads to the download list.

func (*PaymentQueue) Storefront added in v0.17.0

func (pq *PaymentQueue) Storefront() *Storefront

Storefront returns the storefront.

func (*PaymentQueue) String added in v0.17.0

func (pq *PaymentQueue) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

func (*PaymentQueue) TransactionObservers added in v0.17.0

func (pq *PaymentQueue) TransactionObservers() []obj.Object

TransactionObservers returns the transaction observers.

func (*PaymentQueue) Transactions added in v0.17.0

func (pq *PaymentQueue) Transactions() []*PaymentTransaction

Transactions returns the transactions.

Transactions returns the collection as a Go slice.

func (*PaymentQueue) WithDelegate added in v0.17.0

func (pq *PaymentQueue) WithDelegate(delegate PaymentQueueDelegate) *PaymentQueue

WithDelegate sets a delegate that provides information needed to complete transactions.

type PaymentQueueDelegate added in v0.17.0

type PaymentQueueDelegate interface {
}

PaymentQueueDelegate receives the callbacks of the Objective-C protocol SKPaymentQueueDelegate. Pass an implementation to the matching With… setter; the wrapper builds the Objective-C delegate object for you. Every method listed here is required. The protocol's optional methods are separate one-method interfaces (PaymentQueueDelegate…Handler): implement the ones you need on the same value and the framework will call them too.

type PaymentQueueDelegatePaymentQueueShouldContinueTransactionInStorefrontHandler added in v0.17.0

type PaymentQueueDelegatePaymentQueueShouldContinueTransactionInStorefrontHandler interface {
	PaymentQueueShouldContinueTransactionInStorefront(paymentQueue *PaymentQueue, transaction *PaymentTransaction, newStorefront *Storefront) bool
}

PaymentQueueDelegatePaymentQueueShouldContinueTransactionInStorefrontHandler is the optional SKPaymentQueueDelegate method paymentQueue:shouldContinueTransaction:inStorefront:. Implement it on a PaymentQueueDelegate value to receive that callback; a value without it is simply never sent one.

type PaymentTransaction added in v0.17.0

type PaymentTransaction struct {
	objref.Handle
}

PaymentTransaction is an idiomatic wrapper over the Objective-C class SKPaymentTransaction.

An object in the payment queue.

func NewPaymentTransaction added in v0.17.0

func NewPaymentTransaction() *PaymentTransaction

NewPaymentTransaction creates a new PaymentTransaction.

func PaymentTransactionFromID added in v0.17.0

func PaymentTransactionFromID(id objc.ID) *PaymentTransaction

PaymentTransactionFromID adopts an existing Objective-C object as a PaymentTransaction (nil for 0), retaining it and registering a release finalizer.

func (*PaymentTransaction) Description added in v0.17.0

func (pt *PaymentTransaction) Description() string

Description returns the object's -description text.

func (*PaymentTransaction) Downloads added in v0.17.0

func (pt *PaymentTransaction) Downloads() []*Download

Downloads returns the downloads.

Downloads returns the collection as a Go slice.

func (*PaymentTransaction) IsEqual added in v0.17.0

func (pt *PaymentTransaction) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*PaymentTransaction) IsKind added in v0.17.0

func (pt *PaymentTransaction) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*PaymentTransaction) OriginalTransaction added in v0.17.0

func (pt *PaymentTransaction) OriginalTransaction() *PaymentTransaction

OriginalTransaction returns the original transaction.

func (*PaymentTransaction) Payment added in v0.17.0

func (pt *PaymentTransaction) Payment() *Payment

Payment returns the payment.

func (*PaymentTransaction) String added in v0.17.0

func (pt *PaymentTransaction) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

func (*PaymentTransaction) TransactionDate added in v0.17.0

func (pt *PaymentTransaction) TransactionDate() time.Time

TransactionDate returns the transaction date.

func (*PaymentTransaction) TransactionIdentifier added in v0.17.0

func (pt *PaymentTransaction) TransactionIdentifier() string

TransactionIdentifier returns the transaction identifier.

type PaymentTransactionObserver added in v0.17.0

type PaymentTransactionObserver interface {
	// PaymentQueueUpdatedTransactions wraps the corresponding Objective-C method.
	PaymentQueueUpdatedTransactions(queue *PaymentQueue, transactions obj.Object)
}

PaymentTransactionObserver receives the callbacks of the Objective-C protocol SKPaymentTransactionObserver. Pass an implementation to the matching With… setter; the wrapper builds the Objective-C delegate object for you. Every method listed here is required. The protocol's optional methods are separate one-method interfaces (PaymentTransactionObserver…Handler): implement the ones you need on the same value and the framework will call them too.

type PaymentTransactionObserverPaymentQueueDidChangeStorefrontHandler added in v0.17.0

type PaymentTransactionObserverPaymentQueueDidChangeStorefrontHandler interface {
	PaymentQueueDidChangeStorefront(queue *PaymentQueue)
}

PaymentTransactionObserverPaymentQueueDidChangeStorefrontHandler is the optional SKPaymentTransactionObserver method paymentQueueDidChangeStorefront:. Implement it on a PaymentTransactionObserver value to receive that callback; a value without it is simply never sent one.

type PaymentTransactionObserverPaymentQueueDidRevokeEntitlementsForProductIdentifiersHandler added in v0.17.0

type PaymentTransactionObserverPaymentQueueDidRevokeEntitlementsForProductIdentifiersHandler interface {
	PaymentQueueDidRevokeEntitlementsForProductIdentifiers(queue *PaymentQueue, productIdentifiers obj.Object)
}

PaymentTransactionObserverPaymentQueueDidRevokeEntitlementsForProductIdentifiersHandler is the optional SKPaymentTransactionObserver method paymentQueue:didRevokeEntitlementsForProductIdentifiers:. Implement it on a PaymentTransactionObserver value to receive that callback; a value without it is simply never sent one.

type PaymentTransactionObserverPaymentQueueRemovedTransactionsHandler added in v0.17.0

type PaymentTransactionObserverPaymentQueueRemovedTransactionsHandler interface {
	PaymentQueueRemovedTransactions(queue *PaymentQueue, transactions obj.Object)
}

PaymentTransactionObserverPaymentQueueRemovedTransactionsHandler is the optional SKPaymentTransactionObserver method paymentQueue:removedTransactions:. Implement it on a PaymentTransactionObserver value to receive that callback; a value without it is simply never sent one.

type PaymentTransactionObserverPaymentQueueRestoreCompletedTransactionsFailedWithErrorHandler added in v0.17.0

type PaymentTransactionObserverPaymentQueueRestoreCompletedTransactionsFailedWithErrorHandler interface {
	PaymentQueueRestoreCompletedTransactionsFailedWithError(queue *PaymentQueue, err error)
}

PaymentTransactionObserverPaymentQueueRestoreCompletedTransactionsFailedWithErrorHandler is the optional SKPaymentTransactionObserver method paymentQueue:restoreCompletedTransactionsFailedWithError:. Implement it on a PaymentTransactionObserver value to receive that callback; a value without it is simply never sent one.

type PaymentTransactionObserverPaymentQueueRestoreCompletedTransactionsFinishedHandler added in v0.17.0

type PaymentTransactionObserverPaymentQueueRestoreCompletedTransactionsFinishedHandler interface {
	PaymentQueueRestoreCompletedTransactionsFinished(queue *PaymentQueue)
}

PaymentTransactionObserverPaymentQueueRestoreCompletedTransactionsFinishedHandler is the optional SKPaymentTransactionObserver method paymentQueueRestoreCompletedTransactionsFinished:. Implement it on a PaymentTransactionObserver value to receive that callback; a value without it is simply never sent one.

type PaymentTransactionObserverPaymentQueueShouldAddStorePaymentForProductHandler added in v0.17.0

type PaymentTransactionObserverPaymentQueueShouldAddStorePaymentForProductHandler interface {
	PaymentQueueShouldAddStorePaymentForProduct(queue *PaymentQueue, payment *Payment, product *Product) bool
}

PaymentTransactionObserverPaymentQueueShouldAddStorePaymentForProductHandler is the optional SKPaymentTransactionObserver method paymentQueue:shouldAddStorePayment:forProduct:. Implement it on a PaymentTransactionObserver value to receive that callback; a value without it is simply never sent one.

type PaymentTransactionObserverPaymentQueueUpdatedDownloadsHandler added in v0.17.0

type PaymentTransactionObserverPaymentQueueUpdatedDownloadsHandler interface {
	PaymentQueueUpdatedDownloads(queue *PaymentQueue, downloads obj.Object)
}

PaymentTransactionObserverPaymentQueueUpdatedDownloadsHandler is the optional SKPaymentTransactionObserver method paymentQueue:updatedDownloads:. Implement it on a PaymentTransactionObserver value to receive that callback; a value without it is simply never sent one.

type PaymentTransactionState deprecated added in v0.17.0

type PaymentTransactionState int64

Values representing the state of a transaction.

Deprecated: Use PurchaseResult from Product.purchase(confirmIn:options:).

const (
	// A transaction that is being processed by the App Store.
	PaymentTransactionStatePurchasing PaymentTransactionState = 0
	// A successfully processed transaction.
	PaymentTransactionStatePurchased PaymentTransactionState = 1
	// A failed transaction.
	PaymentTransactionStateFailed PaymentTransactionState = 2
	// A transaction that restores content previously purchased by the user.
	PaymentTransactionStateRestored PaymentTransactionState = 3
	// A transaction that is in the queue, but its final status is pending external action such as Ask to Buy.
	//
	// Deprecated: Use PurchaseResult.pending from Product.purchase(confirmIn:options:).
	PaymentTransactionStateDeferred PaymentTransactionState = 4
)

func (PaymentTransactionState) String added in v0.17.0

func (e PaymentTransactionState) String() string

String returns the PaymentTransactionState constant's name, or its numeric form when the value is not a known constant.

type Perm added in v0.17.0

type Perm int64
const (
	PermReadData           Perm = 2
	PermListDirectory      Perm = 2
	PermWriteData          Perm = 4
	PermAddFile            Perm = 4
	PermExecute            Perm = 8
	PermSearch             Perm = 8
	PermDelete             Perm = 16
	PermAppendData         Perm = 32
	PermAddSubdirectory    Perm = 32
	PermDeleteChild        Perm = 64
	PermReadAttributes     Perm = 128
	PermWriteAttributes    Perm = 256
	PermReadExtattributes  Perm = 512
	PermWriteExtattributes Perm = 1024
	PermReadSecurity       Perm = 2048
	PermWriteSecurity      Perm = 4096
	PermChangeOwner        Perm = 8192
	PermSynchronize        Perm = 1048576
)

func (Perm) String added in v0.17.0

func (e Perm) String() string

String returns the Perm constant's name, or its numeric form when the value is not a known constant.

type Product added in v0.17.0

type Product struct {
	objref.Handle
}

Product is an idiomatic wrapper over the Objective-C class SKProduct.

Information about a registered product in App Store Connect.

func NewProduct added in v0.17.0

func NewProduct() *Product

NewProduct creates a new Product.

func ProductFromID added in v0.17.0

func ProductFromID(id objc.ID) *Product

ProductFromID adopts an existing Objective-C object as a Product (nil for 0), retaining it and registering a release finalizer.

func (*Product) Description added in v0.17.0

func (p *Product) Description() string

Description returns the object's -description text.

func (*Product) Discounts added in v0.17.0

func (p *Product) Discounts() []*ProductDiscount

Discounts returns the discounts.

Discounts returns the collection as a Go slice.

func (*Product) DownloadContentLengths added in v0.17.0

func (p *Product) DownloadContentLengths() []obj.Object

DownloadContentLengths returns the download content lengths.

DownloadContentLengths returns the collection as a Go slice.

func (*Product) DownloadContentVersion added in v0.17.0

func (p *Product) DownloadContentVersion() string

DownloadContentVersion returns the download content version.

func (*Product) Downloadable added in v0.17.0

func (p *Product) Downloadable() bool

Downloadable wraps the corresponding Objective-C method.

func (*Product) IntroductoryPrice added in v0.17.0

func (p *Product) IntroductoryPrice() *ProductDiscount

IntroductoryPrice returns the introductory price.

func (*Product) IsDownloadable added in v0.17.0

func (p *Product) IsDownloadable() bool

IsDownloadable reports whether the object is downloadable.

func (*Product) IsEqual added in v0.17.0

func (p *Product) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*Product) IsFamilyShareable added in v0.17.0

func (p *Product) IsFamilyShareable() bool

IsFamilyShareable reports whether the object is family shareable.

func (*Product) IsKind added in v0.17.0

func (p *Product) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*Product) LocalizedDescription added in v0.17.0

func (p *Product) LocalizedDescription() string

LocalizedDescription returns the localized description.

func (*Product) LocalizedTitle added in v0.17.0

func (p *Product) LocalizedTitle() string

LocalizedTitle returns the localized title.

func (*Product) Price added in v0.17.0

func (p *Product) Price() *foundation.DecimalNumber

Price returns the price.

func (*Product) PriceLocale added in v0.17.0

func (p *Product) PriceLocale() *foundation.Locale

PriceLocale returns the price locale.

func (*Product) ProductIdentifier added in v0.17.0

func (p *Product) ProductIdentifier() string

ProductIdentifier returns the product identifier.

func (*Product) String added in v0.17.0

func (p *Product) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

func (*Product) SubscriptionGroupIdentifier added in v0.17.0

func (p *Product) SubscriptionGroupIdentifier() string

SubscriptionGroupIdentifier returns the subscription group identifier.

func (*Product) SubscriptionPeriod added in v0.17.0

func (p *Product) SubscriptionPeriod() *ProductSubscriptionPeriod

SubscriptionPeriod returns the subscription period.

type ProductDiscount added in v0.17.0

type ProductDiscount struct {
	objref.Handle
}

ProductDiscount is an idiomatic wrapper over the Objective-C class SKProductDiscount.

The details of an introductory offer or a promotional offer for an auto-renewable subscription.

func NewProductDiscount added in v0.17.0

func NewProductDiscount() *ProductDiscount

NewProductDiscount creates a new ProductDiscount.

func ProductDiscountFromID added in v0.17.0

func ProductDiscountFromID(id objc.ID) *ProductDiscount

ProductDiscountFromID adopts an existing Objective-C object as a ProductDiscount (nil for 0), retaining it and registering a release finalizer.

func (*ProductDiscount) Description added in v0.17.0

func (pd *ProductDiscount) Description() string

Description returns the object's -description text.

func (*ProductDiscount) Identifier added in v0.17.0

func (pd *ProductDiscount) Identifier() string

Identifier returns the identifier.

func (*ProductDiscount) IsEqual added in v0.17.0

func (pd *ProductDiscount) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*ProductDiscount) IsKind added in v0.17.0

func (pd *ProductDiscount) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*ProductDiscount) NumberOfPeriods added in v0.17.0

func (pd *ProductDiscount) NumberOfPeriods() int

NumberOfPeriods returns the number of periods.

func (*ProductDiscount) PaymentMode added in v0.17.0

func (pd *ProductDiscount) PaymentMode() ProductDiscountPaymentMode

PaymentMode returns the payment mode.

func (*ProductDiscount) Price added in v0.17.0

Price returns the price.

func (*ProductDiscount) PriceLocale added in v0.17.0

func (pd *ProductDiscount) PriceLocale() *foundation.Locale

PriceLocale returns the price locale.

func (*ProductDiscount) String added in v0.17.0

func (pd *ProductDiscount) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

func (*ProductDiscount) SubscriptionPeriod added in v0.17.0

func (pd *ProductDiscount) SubscriptionPeriod() *ProductSubscriptionPeriod

SubscriptionPeriod returns the subscription period.

func (*ProductDiscount) Type added in v0.17.0

Type returns the type.

type ProductDiscountPaymentMode deprecated added in v0.17.0

type ProductDiscountPaymentMode uint64

Values representing the payment modes for a product discount.

Deprecated: Use Product.SubscriptionOffer.PaymentMode.

const (
	ProductDiscountPaymentModePayAsYouGo ProductDiscountPaymentMode = 0
	ProductDiscountPaymentModePayUpFront ProductDiscountPaymentMode = 1
	ProductDiscountPaymentModeFreeTrial  ProductDiscountPaymentMode = 2
)

func (ProductDiscountPaymentMode) String added in v0.17.0

String returns the ProductDiscountPaymentMode constant's name, or its numeric form when the value is not a known constant.

type ProductDiscountType deprecated added in v0.17.0

type ProductDiscountType uint64

Values representing the types of discount offers an app can present.

Deprecated: Use Product.SubscriptionOffer.OfferType.

const (
	// Deprecated: Use Product.SubscriptionOffer.PaymentMode.
	ProductDiscountTypeIntroductory ProductDiscountType = 0
	// Deprecated: Use Product.SubscriptionOffer.PaymentMode.
	ProductDiscountTypeSubscription ProductDiscountType = 1
)

func (ProductDiscountType) String added in v0.17.0

func (e ProductDiscountType) String() string

String returns the ProductDiscountType constant's name, or its numeric form when the value is not a known constant.

type ProductPeriodUnit deprecated added in v0.17.0

type ProductPeriodUnit uint64

Values representing the duration of an interval, from a day up to a year.

Deprecated: Use Product.SubscriptionPeriod.Unit.

const (
	ProductPeriodUnitDay   ProductPeriodUnit = 0
	ProductPeriodUnitWeek  ProductPeriodUnit = 1
	ProductPeriodUnitMonth ProductPeriodUnit = 2
	ProductPeriodUnitYear  ProductPeriodUnit = 3
)

func (ProductPeriodUnit) String added in v0.17.0

func (e ProductPeriodUnit) String() string

String returns the ProductPeriodUnit constant's name, or its numeric form when the value is not a known constant.

type ProductStorePromotionController added in v0.17.0

type ProductStorePromotionController struct {
	objref.Handle
}

ProductStorePromotionController is an idiomatic wrapper over the Objective-C class SKProductStorePromotionController.

A product promotion controller for customizing the order and visibility of In-App Purchases per device.

func DefaultController added in v0.17.0

func DefaultController() *ProductStorePromotionController

DefaultController returns the default product store promotion controller.

func NewProductStorePromotionController added in v0.17.0

func NewProductStorePromotionController() *ProductStorePromotionController

NewProductStorePromotionController creates a new ProductStorePromotionController.

func ProductStorePromotionControllerFromID added in v0.17.0

func ProductStorePromotionControllerFromID(id objc.ID) *ProductStorePromotionController

ProductStorePromotionControllerFromID adopts an existing Objective-C object as a ProductStorePromotionController (nil for 0), retaining it and registering a release finalizer.

func (*ProductStorePromotionController) Description added in v0.17.0

func (pspc *ProductStorePromotionController) Description() string

Description returns the object's -description text.

func (*ProductStorePromotionController) FetchStorePromotionOrder added in v0.17.0

func (pspc *ProductStorePromotionController) FetchStorePromotionOrder(ctx context.Context) (result obj.Object, err error)

FetchStorePromotionOrder reads the product order override that determines the promoted product order on this device.

FetchStorePromotionOrder blocks until the operation completes or ctx is cancelled.

func (*ProductStorePromotionController) IsEqual added in v0.17.0

func (pspc *ProductStorePromotionController) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*ProductStorePromotionController) IsKind added in v0.17.0

func (pspc *ProductStorePromotionController) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*ProductStorePromotionController) String added in v0.17.0

func (pspc *ProductStorePromotionController) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

func (*ProductStorePromotionController) UpdateStorePromotionOrder added in v0.17.0

func (pspc *ProductStorePromotionController) UpdateStorePromotionOrder(ctx context.Context, promotionOrder []*Product) error

UpdateStorePromotionOrder overrides the promoted product order on this device.

UpdateStorePromotionOrder blocks until the operation completes or ctx is cancelled.

func (*ProductStorePromotionController) UpdateStorePromotionVisibilityForProduct added in v0.17.0

func (pspc *ProductStorePromotionController) UpdateStorePromotionVisibilityForProduct(ctx context.Context, promotionVisibility ProductStorePromotionVisibility, product *Product) error

UpdateStorePromotionVisibilityForProduct updates the visibility of the product on the App Store, per device.

UpdateStorePromotionVisibilityForProduct blocks until the operation completes or ctx is cancelled.

type ProductStorePromotionVisibility deprecated added in v0.17.0

type ProductStorePromotionVisibility int64

The visibility settings that determine if an in-app purchase is visible on a device.

Deprecated: Use Product.PromotionInfo.Visibility.

const (
	// Indicates product visibility is the same as the default value set in App Store Connect.
	ProductStorePromotionVisibilityDefault ProductStorePromotionVisibility = 0
	// Indicates product is shown.
	ProductStorePromotionVisibilityShow ProductStorePromotionVisibility = 1
	// Indicates product is hidden.
	ProductStorePromotionVisibilityHide ProductStorePromotionVisibility = 2
)

func (ProductStorePromotionVisibility) String added in v0.17.0

String returns the ProductStorePromotionVisibility constant's name, or its numeric form when the value is not a known constant.

type ProductSubscriptionPeriod added in v0.17.0

type ProductSubscriptionPeriod struct {
	objref.Handle
}

ProductSubscriptionPeriod is an idiomatic wrapper over the Objective-C class SKProductSubscriptionPeriod.

An object containing the subscription period duration information.

func NewProductSubscriptionPeriod added in v0.17.0

func NewProductSubscriptionPeriod() *ProductSubscriptionPeriod

NewProductSubscriptionPeriod creates a new ProductSubscriptionPeriod.

func ProductSubscriptionPeriodFromID added in v0.17.0

func ProductSubscriptionPeriodFromID(id objc.ID) *ProductSubscriptionPeriod

ProductSubscriptionPeriodFromID adopts an existing Objective-C object as a ProductSubscriptionPeriod (nil for 0), retaining it and registering a release finalizer.

func (*ProductSubscriptionPeriod) Description added in v0.17.0

func (psp *ProductSubscriptionPeriod) Description() string

Description returns the object's -description text.

func (*ProductSubscriptionPeriod) IsEqual added in v0.17.0

func (psp *ProductSubscriptionPeriod) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*ProductSubscriptionPeriod) IsKind added in v0.17.0

func (psp *ProductSubscriptionPeriod) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*ProductSubscriptionPeriod) NumberOfUnits added in v0.17.0

func (psp *ProductSubscriptionPeriod) NumberOfUnits() int

NumberOfUnits returns the number of units.

func (*ProductSubscriptionPeriod) String added in v0.17.0

func (psp *ProductSubscriptionPeriod) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

func (*ProductSubscriptionPeriod) Unit added in v0.17.0

Unit returns the unit.

type ProductsRequest added in v0.17.0

type ProductsRequest struct {
	Request
}

ProductsRequest is an idiomatic wrapper over the Objective-C class SKProductsRequest.

It embeds Request, promoting that type's methods.

An object that can retrieve localized information from the App Store about a specified list of products.

func NewProductsRequestWithProductIdentifiers added in v0.17.0

func NewProductsRequestWithProductIdentifiers(productIdentifiers []string) *ProductsRequest

NewProductsRequestWithProductIdentifiers initializes the request with the set of product identifiers.

func ProductsRequestFromID added in v0.17.0

func ProductsRequestFromID(id objc.ID) *ProductsRequest

ProductsRequestFromID adopts an existing Objective-C object as a ProductsRequest (nil for 0), retaining it and registering a release finalizer.

func (*ProductsRequest) WithDelegate added in v0.17.0

func (pr *ProductsRequest) WithDelegate(delegate RequestDelegate) *ProductsRequest

WithDelegate sets the delegate of the request object.

type ProductsRequestDelegate added in v0.17.0

type ProductsRequestDelegate interface {
	// ProductsRequestDidReceiveResponse wraps the corresponding Objective-C method.
	ProductsRequestDidReceiveResponse(request *ProductsRequest, response *ProductsResponse)
}

ProductsRequestDelegate receives the callbacks of the Objective-C protocol SKProductsRequestDelegate. Pass an implementation to the matching With… setter; the wrapper builds the Objective-C delegate object for you. Every method listed here is required. The protocol's optional methods are separate one-method interfaces (ProductsRequestDelegate…Handler): implement the ones you need on the same value and the framework will call them too.

type ProductsResponse added in v0.17.0

type ProductsResponse struct {
	objref.Handle
}

ProductsResponse is an idiomatic wrapper over the Objective-C class SKProductsResponse.

An App Store response to a request for information about a list of products.

func NewProductsResponse added in v0.17.0

func NewProductsResponse() *ProductsResponse

NewProductsResponse creates a new ProductsResponse.

func ProductsResponseFromID added in v0.17.0

func ProductsResponseFromID(id objc.ID) *ProductsResponse

ProductsResponseFromID adopts an existing Objective-C object as a ProductsResponse (nil for 0), retaining it and registering a release finalizer.

func (*ProductsResponse) Description added in v0.17.0

func (pr *ProductsResponse) Description() string

Description returns the object's -description text.

func (*ProductsResponse) InvalidProductIdentifiers added in v0.17.0

func (pr *ProductsResponse) InvalidProductIdentifiers() []string

InvalidProductIdentifiers returns the invalid product identifiers.

InvalidProductIdentifiers returns the collection as a Go slice.

func (*ProductsResponse) IsEqual added in v0.17.0

func (pr *ProductsResponse) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*ProductsResponse) IsKind added in v0.17.0

func (pr *ProductsResponse) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*ProductsResponse) Products added in v0.17.0

func (pr *ProductsResponse) Products() []*Product

Products returns the products.

Products returns the collection as a Go slice.

func (*ProductsResponse) String added in v0.17.0

func (pr *ProductsResponse) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

type PtrauthKey added in v0.17.0

type PtrauthKey int64
const (
	Ptrauth_key_none                     PtrauthKey = -1
	Ptrauth_key_asia                     PtrauthKey = 0
	Ptrauth_key_asib                     PtrauthKey = 1
	Ptrauth_key_asda                     PtrauthKey = 2
	Ptrauth_key_asdb                     PtrauthKey = 3
	Ptrauth_key_process_independent_code PtrauthKey = 0
	Ptrauth_key_process_dependent_code   PtrauthKey = 1
	Ptrauth_key_process_independent_data PtrauthKey = 2
	Ptrauth_key_process_dependent_data   PtrauthKey = 3
	Ptrauth_key_return_address           PtrauthKey = 1
	Ptrauth_key_frame_pointer            PtrauthKey = 3
	Ptrauth_key_function_pointer         PtrauthKey = 0
	Ptrauth_key_block_function           PtrauthKey = 0
	Ptrauth_key_cxx_vtable_pointer       PtrauthKey = 2
	Ptrauth_key_method_list_pointer      PtrauthKey = 2
	Ptrauth_key_objc_isa_pointer         PtrauthKey = 2
	Ptrauth_key_objc_super_pointer       PtrauthKey = 2
	Ptrauth_key_objc_sel_pointer         PtrauthKey = 3
	Ptrauth_key_objc_class_ro_pointer    PtrauthKey = 2
	Ptrauth_key_block_descriptor_pointer PtrauthKey = 2
	Ptrauth_key_init_fini_pointer        PtrauthKey = 0
)

func (PtrauthKey) String added in v0.17.0

func (e PtrauthKey) String() string

String returns the PtrauthKey constant's name, or its numeric form when the value is not a known constant.

type QosClass added in v0.17.0

type QosClass uint32
const (
	QosClassUserInteractive QosClass = 33
	QosClassUserInitiated   QosClass = 25
	QosClassDefault         QosClass = 21
	QosClassUtility         QosClass = 17
	QosClassBackground      QosClass = 9
	QosClassUnspecified     QosClass = 0
)

func (QosClass) String added in v0.17.0

func (e QosClass) String() string

String returns the QosClass constant's name, or its numeric form when the value is not a known constant.

type ReceiptRefreshRequest added in v0.17.0

type ReceiptRefreshRequest struct {
	Request
}

ReceiptRefreshRequest is an idiomatic wrapper over the Objective-C class SKReceiptRefreshRequest.

It embeds Request, promoting that type's methods.

A request to the App Store to get the app receipt, which represents the customer’s transactions with your app.

func NewReceiptRefreshRequestWithReceiptProperties added in v0.17.0

func NewReceiptRefreshRequestWithReceiptProperties(properties map[string]obj.Object) *ReceiptRefreshRequest

NewReceiptRefreshRequestWithReceiptProperties creates a receipt refresh request with optional properties.

func ReceiptRefreshRequestFromID added in v0.17.0

func ReceiptRefreshRequestFromID(id objc.ID) *ReceiptRefreshRequest

ReceiptRefreshRequestFromID adopts an existing Objective-C object as a ReceiptRefreshRequest (nil for 0), retaining it and registering a release finalizer.

func (*ReceiptRefreshRequest) ReceiptProperties added in v0.17.0

func (rrr *ReceiptRefreshRequest) ReceiptProperties() map[string]obj.Object

ReceiptProperties returns the receipt properties.

func (*ReceiptRefreshRequest) WithDelegate added in v0.17.0

func (rrr *ReceiptRefreshRequest) WithDelegate(delegate RequestDelegate) *ReceiptRefreshRequest

WithDelegate sets the delegate of the request object.

type Request added in v0.17.0

type Request struct {
	objref.Handle
}

Request is an idiomatic wrapper over the Objective-C class SKRequest.

Request is an abstract base — you do not construct it directly. Construct one of ProductsRequest, ReceiptRefreshRequest and pass it where a Request is accepted.

An abstract class that represents a request to the App Store.

func RequestFromID added in v0.17.0

func RequestFromID(id objc.ID) *Request

RequestFromID adopts an existing Objective-C object as a Request (nil for 0), retaining it and registering a release finalizer.

func (*Request) Cancel added in v0.17.0

func (r *Request) Cancel()

Cancel cancels a previously started request.

func (*Request) Description added in v0.17.0

func (r *Request) Description() string

Description returns the object's -description text.

func (*Request) IsEqual added in v0.17.0

func (r *Request) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*Request) IsKind added in v0.17.0

func (r *Request) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*Request) Start added in v0.17.0

func (r *Request) Start()

Start sends the request to the Apple App Store.

func (*Request) String added in v0.17.0

func (r *Request) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

func (*Request) WithDelegate added in v0.17.0

func (r *Request) WithDelegate(delegate RequestDelegate) *Request

WithDelegate sets the delegate of the request object.

type RequestDelegate added in v0.17.0

type RequestDelegate interface {
}

RequestDelegate receives the callbacks of the Objective-C protocol SKRequestDelegate. Pass an implementation to the matching With… setter; the wrapper builds the Objective-C delegate object for you. Every method listed here is required. The protocol's optional methods are separate one-method interfaces (RequestDelegate…Handler): implement the ones you need on the same value and the framework will call them too.

type RequestDelegateRequestDidFailWithErrorHandler added in v0.17.0

type RequestDelegateRequestDidFailWithErrorHandler interface {
	RequestDidFailWithError(request *Request, err error)
}

RequestDelegateRequestDidFailWithErrorHandler is the optional SKRequestDelegate method request:didFailWithError:. Implement it on a RequestDelegate value to receive that callback; a value without it is simply never sent one.

type RequestDelegateRequestDidFinishHandler added in v0.17.0

type RequestDelegateRequestDidFinishHandler interface {
	RequestDidFinish(request *Request)
}

RequestDelegateRequestDidFinishHandler is the optional SKRequestDelegate method requestDidFinish:. Implement it on a RequestDelegate value to receive that callback; a value without it is simply never sent one.

type RequestProvider added in v0.17.0

type RequestProvider interface {
	objref.Object
	// contains filtered or unexported methods
}

RequestProvider is accepted wherever a SKRequest (or one of its subclasses) is expected.

type StoreProductViewController added in v0.17.0

type StoreProductViewController struct {
	objref.Handle
}

StoreProductViewController is an idiomatic wrapper over the Objective-C class SKStoreProductViewController.

A view controller that provides a page where customers can purchase media from the App Store.

func NewStoreProductViewController added in v0.17.0

func NewStoreProductViewController() *StoreProductViewController

NewStoreProductViewController creates a new StoreProductViewController.

func StoreProductViewControllerFromID added in v0.17.0

func StoreProductViewControllerFromID(id objc.ID) *StoreProductViewController

StoreProductViewControllerFromID adopts an existing Objective-C object as a StoreProductViewController (nil for 0), retaining it and registering a release finalizer.

func (*StoreProductViewController) Description added in v0.17.0

func (spvc *StoreProductViewController) Description() string

Description returns the object's -description text.

func (*StoreProductViewController) IsEqual added in v0.17.0

func (spvc *StoreProductViewController) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*StoreProductViewController) IsKind added in v0.17.0

func (spvc *StoreProductViewController) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*StoreProductViewController) String added in v0.17.0

func (spvc *StoreProductViewController) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

func (*StoreProductViewController) WithDelegate added in v0.17.0

WithDelegate sets the store view controller’s delegate.

type StoreProductViewControllerDelegate added in v0.17.0

type StoreProductViewControllerDelegate interface {
}

StoreProductViewControllerDelegate receives the callbacks of the Objective-C protocol SKStoreProductViewControllerDelegate. Pass an implementation to the matching With… setter; the wrapper builds the Objective-C delegate object for you. Every method listed here is required. The protocol's optional methods are separate one-method interfaces (StoreProductViewControllerDelegate…Handler): implement the ones you need on the same value and the framework will call them too.

type StoreProductViewControllerDelegateProductViewControllerDidFinishHandler added in v0.17.0

type StoreProductViewControllerDelegateProductViewControllerDidFinishHandler interface {
	ProductViewControllerDidFinish(viewController *StoreProductViewController)
}

StoreProductViewControllerDelegateProductViewControllerDidFinishHandler is the optional SKStoreProductViewControllerDelegate method productViewControllerDidFinish:. Implement it on a StoreProductViewControllerDelegate value to receive that callback; a value without it is simply never sent one.

type StoreReviewController added in v0.17.0

type StoreReviewController struct {
	objref.Handle
}

StoreReviewController is an idiomatic wrapper over the Objective-C class SKStoreReviewController.

An object that controls the process of requesting App Store ratings and reviews from customers.

func NewStoreReviewController added in v0.17.0

func NewStoreReviewController() *StoreReviewController

NewStoreReviewController creates a new StoreReviewController.

func StoreReviewControllerFromID added in v0.17.0

func StoreReviewControllerFromID(id objc.ID) *StoreReviewController

StoreReviewControllerFromID adopts an existing Objective-C object as a StoreReviewController (nil for 0), retaining it and registering a release finalizer.

func (*StoreReviewController) Description added in v0.17.0

func (src *StoreReviewController) Description() string

Description returns the object's -description text.

func (*StoreReviewController) IsEqual added in v0.17.0

func (src *StoreReviewController) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*StoreReviewController) IsKind added in v0.17.0

func (src *StoreReviewController) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*StoreReviewController) String added in v0.17.0

func (src *StoreReviewController) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

type Storefront added in v0.17.0

type Storefront struct {
	objref.Handle
}

Storefront is an idiomatic wrapper over the Objective-C class SKStorefront.

An object containing the location and unique identifier of an Apple App Store storefront.

func NewStorefront added in v0.17.0

func NewStorefront() *Storefront

NewStorefront creates a new Storefront.

func StorefrontFromID added in v0.17.0

func StorefrontFromID(id objc.ID) *Storefront

StorefrontFromID adopts an existing Objective-C object as a Storefront (nil for 0), retaining it and registering a release finalizer.

func (*Storefront) CountryCode added in v0.17.0

func (s *Storefront) CountryCode() string

CountryCode returns the country code.

func (*Storefront) Description added in v0.17.0

func (s *Storefront) Description() string

Description returns the object's -description text.

func (*Storefront) Identifier added in v0.17.0

func (s *Storefront) Identifier() string

Identifier returns the identifier.

func (*Storefront) IsEqual added in v0.17.0

func (s *Storefront) IsEqual(other obj.Object) bool

IsEqual reports Objective-C equality (isEqual:) with another object.

func (*Storefront) IsKind added in v0.17.0

func (s *Storefront) IsKind(className string) bool

IsKind reports whether the object is an instance of the named class or a subclass.

func (*Storefront) String added in v0.17.0

func (s *Storefront) String() string

String returns the object's -description text, so a wrapper prints usefully under fmt.

type Tag added in v0.17.0

type Tag int64
const (
	TagUndefinedTag  Tag = 0
	TagExtendedAllow Tag = 1
	TagExtendedDeny  Tag = 2
)

func (Tag) String added in v0.17.0

func (e Tag) String() string

String returns the Tag constant's name, or its numeric form when the value is not a known constant.

type Type added in v0.17.0

type Type int64
const (
	TypeExtended Type = 256
	TypeAccess   Type = 0
	TypeDefault  Type = 1
	TypeAfs      Type = 2
	TypeCoda     Type = 3
	TypeNtfs     Type = 4
	TypeNwfs     Type = 5
)

func (Type) String added in v0.17.0

func (e Type) String() string

String returns the Type constant's name, or its numeric form when the value is not a known constant.

type VirtualMemoryGuardExceptionCode added in v0.17.0

type VirtualMemoryGuardExceptionCode int64
const (
	KGUARD_EXC_DEALLOC_GAP                   VirtualMemoryGuardExceptionCode = 1
	KGUARD_EXC_RECLAIM_COPYIO_FAILURE        VirtualMemoryGuardExceptionCode = 2
	KGUARD_EXC_RECLAIM_INDEX_FAILURE         VirtualMemoryGuardExceptionCode = 4
	KGUARD_EXC_RECLAIM_DEALLOCATE_FAILURE    VirtualMemoryGuardExceptionCode = 8
	KGUARD_EXC_RECLAIM_ACCOUNTING_FAILURE    VirtualMemoryGuardExceptionCode = 9
	KGUARD_EXC_SEC_IOPL_ON_EXEC_PAGE         VirtualMemoryGuardExceptionCode = 10
	KGUARD_EXC_SEC_EXEC_ON_IOPL_PAGE         VirtualMemoryGuardExceptionCode = 11
	KGUARD_EXC_SEC_UPL_WRITE_ON_EXEC_REGION  VirtualMemoryGuardExceptionCode = 12
	KGUARD_EXC_LARGE_ALLOCATION_TELEMETRY    VirtualMemoryGuardExceptionCode = 13
	KGUARD_EXC_SEC_ACCESS_FAULT              VirtualMemoryGuardExceptionCode = 98
	KGUARD_EXC_SEC_ASYNC_ACCESS_FAULT        VirtualMemoryGuardExceptionCode = 99
	KGUARD_EXC_SEC_COPY_DENIED               VirtualMemoryGuardExceptionCode = 100
	KGUARD_EXC_SEC_SHARING_DENIED            VirtualMemoryGuardExceptionCode = 101
	KGUARD_EXC_MTE_SYNC_FAULT                VirtualMemoryGuardExceptionCode = 200
	KGUARD_EXC_MTE_ASYNC_USER_FAULT          VirtualMemoryGuardExceptionCode = 201
	KGUARD_EXC_MTE_ASYNC_KERN_FAULT          VirtualMemoryGuardExceptionCode = 202
	KGUARD_EXC_GUARD_OBJECT_ASYNC_USER_FAULT VirtualMemoryGuardExceptionCode = 203
	KGUARD_EXC_GUARD_OBJECT_ASYNC_KERN_FAULT VirtualMemoryGuardExceptionCode = 204
)

func (VirtualMemoryGuardExceptionCode) String added in v0.17.0

String returns the VirtualMemoryGuardExceptionCode constant's name, or its numeric form when the value is not a known constant.

type XpcListenerCreateFlags added in v0.17.0

type XpcListenerCreateFlags int64

Bitmask — values may be combined with |.

const (
	XpcListenerCreateFlagsNone            XpcListenerCreateFlags = 0
	XpcListenerCreateFlagsInactive        XpcListenerCreateFlags = 1
	XpcListenerCreateFlagsForceMach       XpcListenerCreateFlags = 2
	XpcListenerCreateFlagsForceXpcservice XpcListenerCreateFlags = 4
)

func (XpcListenerCreateFlags) String added in v0.17.0

func (e XpcListenerCreateFlags) String() string

String returns the XpcListenerCreateFlags constant's name, or its numeric form when the value is not a known constant.

type XpcSessionCreateFlags added in v0.17.0

type XpcSessionCreateFlags int64

Bitmask — values may be combined with |.

const (
	XpcSessionCreateFlagsNone           XpcSessionCreateFlags = 0
	XpcSessionCreateFlagsInactive       XpcSessionCreateFlags = 1
	XpcSessionCreateFlagsMachPrivileged XpcSessionCreateFlags = 2
)

func (XpcSessionCreateFlags) String added in v0.17.0

func (e XpcSessionCreateFlags) String() string

String returns the XpcSessionCreateFlags constant's name, or its numeric form when the value is not a known constant.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL