One Logo Pool Ball
SwiftUI · IOS API REFERENCE

DropInfo

struct · iOS 13.4+ · SDK 27.1

struct DropInfo

The current state of a drop.

Members (5)

method · iOS 14.0+

itemProviders

TypeScript
itemProvidersFor(contentTypes: Array<_UniformTypeIdentifiers_UTType>): Array<_Foundation_NSItemProvider>
Swift declaration
func itemProviders(for contentTypes: [UTType]) -> [NSItemProvider]

Finds item providers that conform to at least one of the specified uniform type identifiers. This function is only valid during the `performDrop()` action. - Parameter contentTypes: The uniform type identifiers to query for. - Returns: The item providers that conforms to `contentTypes`.

method · iOS 13.4+ · Deprecated in iOS 100000.0

itemProviders

TypeScript
itemProvidersFor92542(types: Array<string>): Array<_Foundation_NSItemProvider>
Swift declaration
func itemProviders(for types: [String]) -> [NSItemProvider]

Returns an Array of items that each conform to at least one of the specified uniform type identifiers. This function is only valid during the performDrop() action.

method · iOS 14.0+

hasItemsConforming

TypeScript
hasItemsConformingTo(contentTypes: Array<_UniformTypeIdentifiers_UTType>): boolean
Swift declaration
func hasItemsConforming(to contentTypes: [UTType]) -> Bool

Indicates whether at least one item conforms to at least one of the specified uniform type identifiers. - Parameter contentTypes: The uniform type identifiers to query for. - Returns: Whether at least one item conforms to one of `contentTypes`.

method · iOS 13.4+ · Deprecated in iOS 100000.0

hasItemsConforming

TypeScript
hasItemsConformingTo4243(types: Array<string>): boolean
Swift declaration
func hasItemsConforming(to types: [String]) -> Bool

Returns whether at least one item conforms to at least one of the specified uniform type identifiers.

get · iOS 13.4+

location

TypeScript
get location(): { x: number; y: number }
Swift declaration
var location: CGPoint { get }

The location of the drag in the coordinate space of the drop view.

Skipped declarations

No declarations were skipped in this snapshot.

All SwiftUI types →