Returns the attributes of the item at a given path.
- iOS 2.0+
- macOS 10.5+
- UIKit for Mac 13.0+Beta
- tvOS 9.0+
- watchOS 2.0+
The path of a file or directory.
A dictionary object that describes the attributes (file, directory, symlink, and so on) of the file specified by
path. The keys in the dictionary are described in File Attribute Keys.
If the item at the path is a symbolic link—that is, the value of the
type key in the attributes dictionary is
type—you can use the
destination method to retrieve the path of the item pointed to by the link. You can also use the
resolving method of
NSString to resolve links in the path before retrieving the item’s attributes.
As a convenience,
NSDictionary provides a set of methods (declared as a category on
NSDictionary) for quickly and efficiently obtaining attribute information from the returned dictionary: