Creates and returns a data object from the mapped file at a given path.
- iOS 2.0–8.0Deprecated
- macOS 10.0–10.10Deprecated
- tvOS 9.0–9.0Deprecated
- watchOS 2.0–2.0Deprecated
The absolute path of the file from which to read data.
A data object from the mapped file specified by
nil if the data object could not be created.
Because of file mapping restrictions, this method should only be used if the file is guaranteed to exist for the duration of the data object’s existence. It is generally safer to use the
This methods assumes mapped files are available from the underlying operating system. A mapped file uses virtual memory techniques to avoid copying pages of the file into memory until they are actually needed.