One Logo Pool Ball
UIKit · IOS API REFERENCE

UIAttachmentBehavior

class · iOS 7.0+ · SDK 27.1

@MainActor class UIAttachmentBehavior

Members (23)

static · iOS 9.0+

fixedAttachment

TypeScript
static fixedAttachment(item1: SDKHandle, item2: SDKHandle, point: { x: number; y: number }): Promise<UIAttachmentBehavior>
Swift declaration
class func fixedAttachment(with item1: any UIDynamicItem, attachedTo item2: any UIDynamicItem, attachmentAnchor point: CGPoint) -> Self
static · iOS 9.0+

limitAttachment

TypeScript
static limitAttachment(item1: SDKHandle, offset1: UIOffset, item2: SDKHandle, offset2: UIOffset): Promise<UIAttachmentBehavior>
Swift declaration
class func limitAttachment(with item1: any UIDynamicItem, offsetFromCenter offset1: UIOffset, attachedTo item2: any UIDynamicItem, offsetFromCenter offset2: UIOffset) -> Self
static · iOS 9.0+

pinAttachment

TypeScript
static pinAttachment(item1: SDKHandle, item2: SDKHandle, point: { x: number; y: number }): Promise<UIAttachmentBehavior>
Swift declaration
class func pinAttachment(with item1: any UIDynamicItem, attachedTo item2: any UIDynamicItem, attachmentAnchor point: CGPoint) -> Self
static · iOS 9.0+

slidingAttachment

TypeScript
static slidingAttachmentWithAttachedToAttachmentAnchorAxisOfTranslation(item1: SDKHandle, item2: SDKHandle, point: { x: number; y: number }, axis: { dx: number; dy: number }): Promise<UIAttachmentBehavior>
Swift declaration
class func slidingAttachment(with item1: any UIDynamicItem, attachedTo item2: any UIDynamicItem, attachmentAnchor point: CGPoint, axisOfTranslation axis: CGVector) -> Self
static · iOS 9.0+

slidingAttachment

TypeScript
static slidingAttachmentWithAttachmentAnchorAxisOfTranslation(item: SDKHandle, point: { x: number; y: number }, axis: { dx: number; dy: number }): Promise<UIAttachmentBehavior>
Swift declaration
class func slidingAttachment(with item: any UIDynamicItem, attachmentAnchor point: CGPoint, axisOfTranslation axis: CGVector) -> Self
init · iOS 7.0+

init

TypeScript
static initItemAttachedToAnchor(item: SDKHandle, point: { x: number; y: number }): Promise<UIAttachmentBehavior>
Swift declaration
convenience init(item: any UIDynamicItem, attachedToAnchor point: CGPoint)
init · iOS 7.0+

init

TypeScript
static initItemAttachedTo(item1: SDKHandle, item2: SDKHandle): Promise<UIAttachmentBehavior>
Swift declaration
convenience init(item item1: any UIDynamicItem, attachedTo item2: any UIDynamicItem)
init · iOS 7.0+

init

TypeScript
static initItemOffsetFromCenterAttachedToAnchor(item: SDKHandle, offset: UIOffset, point: { x: number; y: number }): Promise<UIAttachmentBehavior>
Swift declaration
init(item: any UIDynamicItem, offsetFromCenter offset: UIOffset, attachedToAnchor point: CGPoint)
init · iOS 7.0+

init

TypeScript
static initItemOffsetFromCenterAttachedToOffsetFromCenter(item1: SDKHandle, offset1: UIOffset, item2: SDKHandle, offset2: UIOffset): Promise<UIAttachmentBehavior>
Swift declaration
init(item item1: any UIDynamicItem, offsetFromCenter offset1: UIOffset, attachedTo item2: any UIDynamicItem, offsetFromCenter offset2: UIOffset)
get · iOS 7.0+

anchorPoint

TypeScript
get anchorPoint(): Promise<{ x: number; y: number }>
Swift declaration
var anchorPoint: CGPoint { get set }
set · iOS 7.0+

anchorPoint

TypeScript
setAnchorPoint(value: { x: number; y: number }): Promise<void>
Swift declaration
var anchorPoint: CGPoint { get set }
get · iOS 7.0+

attachedBehaviorType

TypeScript
get attachedBehaviorType(): Promise<UIAttachmentBehavior_AttachmentType>
Swift declaration
var attachedBehaviorType: UIAttachmentBehavior.AttachmentType { get }
get · iOS 9.0+

attachmentRange

TypeScript
get attachmentRange(): Promise<UIFloatRange>
Swift declaration
var attachmentRange: UIFloatRange { get set }
set · iOS 9.0+

attachmentRange

TypeScript
setAttachmentRange(value: UIFloatRange): Promise<void>
Swift declaration
var attachmentRange: UIFloatRange { get set }
get · iOS 7.0+

damping

TypeScript
get damping(): Promise<number>
Swift declaration
var damping: CGFloat { get set }
set · iOS 7.0+

damping

TypeScript
setDamping(value: number): Promise<void>
Swift declaration
var damping: CGFloat { get set }
get · iOS 7.0+

frequency

TypeScript
get frequency(): Promise<number>
Swift declaration
var frequency: CGFloat { get set }
set · iOS 7.0+

frequency

TypeScript
setFrequency(value: number): Promise<void>
Swift declaration
var frequency: CGFloat { get set }
get · iOS 9.0+

frictionTorque

TypeScript
get frictionTorque(): Promise<number>
Swift declaration
var frictionTorque: CGFloat { get set }
set · iOS 9.0+

frictionTorque

TypeScript
setFrictionTorque(value: number): Promise<void>
Swift declaration
var frictionTorque: CGFloat { get set }
get · iOS 7.0+

items

TypeScript
get items(): Promise<Array<SDKHandle>>
Swift declaration
var items: [any UIDynamicItem] { get }
get · iOS 7.0+

length

TypeScript
get length(): Promise<number>
Swift declaration
var length: CGFloat { get set }
set · iOS 7.0+

length

TypeScript
setLength(value: number): Promise<void>
Swift declaration
var length: CGFloat { get set }

Skipped declarations

1 declarations were excluded from these bindings. Each reason comes from the generator or the iOS SDK compiler.

UIAttachmentBehavior.init()

inherited init: cannot prove legal (class declares 6 custom initializers)

All UIKit types →