nonatomic
– Specifies that accessors are nonatomic. By default, accessors are atomic.
readwrite
– Indicates that the property should be treated as read/write. This attribute is the default.
readonly
– Indicates that the property is read-only.
strong
– Specifies that there is a strong (owning) relationship to the destination object. (ARC)
weak
– Specifies that there is a weak (non-owning) relationship to the destination object.
If the destination object is deallocated, the property value is automatically set to nil. (not supported in iOS 4; use assign
instead)
copy
– Specifies that a copy of the object should be used for assignment, releasing the previous value and copying the incoming value (only valid for objects that implement the NSCopying
protocol).
assign
– Specifies that the setter uses simple assignment. This attribute is the default. (use for scalar types, weak references in iOS 4, etc.)
retain
– Specifies that retain should be invoked on the object upon assignment. The previous value is sent a release message.
4.1.1. Property declarations
A property of retainable object pointer type may have ownership. If the property's type is ownership-qualified, then the property has that ownership. If the property has one of the following modifiers, then the property has the corresponding ownership. A property is ill-formed if it has conflicting sources of ownership, or if it has redundant ownership modifiers, or if it has __autoreleasing ownership.
assign implies __unsafe_unretained ownership.
copy implies __strong ownership, as well as the usual behavior of copy semantics on the setter.
retain implies __strong ownership.
strong implies __strong ownership.
unsafe_unretained implies __unsafe_unretained ownership.
weak implies __weak ownership.