|
FoundationExtension
FoundationExtension is common Foundation/UIKit/Cocoa shortcuts and snippets collection.
|
Creation method extension. More...
#import <NSURL.h>
Instance Methods | |
Initializing an URL | |
| (instancetype) | - initResourceURLWithPath: |
| Initializes a newly created NSURL referencing the local file or directory at path based on resource directory of main bundle. More... | |
| (instancetype) | - initConfigurationURLWithPath: |
| Initializes a newly created NSURL referencing the local file or directory at path based on configuration directory. More... | |
| (instancetype) | - initTemporaryURLWithPath: |
| Initializes a newly created NSURL referencing the local file or directory at path based on temporary directory. More... | |
| (instancetype) | - initSmartURLWithPath: |
| Initializes a newly created NSURL referencing any URL decodable by protocol prefix. More... | |
Class Methods | |
Creating an URL | |
| (instancetype) | + resourceURLWithPath: |
| Initializes and returns a newly created NSURL object as a file URL with a specified path based on resource directory of main bundle. More... | |
| (instancetype) | + configurationURLWithPath: |
| Initializes and returns a newly created NSURL object as a file URL with a specified path based on configuration directory. More... | |
| (instancetype) | + temporaryURLWithPath: |
| Initializes and returns a newly created NSURL object as a file URL with a specified path based on temporary directory. More... | |
| (instancetype) | + smartURLWithPath: |
| Initializes and returns a newly created NSURL referencing any URL decodable by protocol prefix. More... | |
Deprecated | |
| (id) | - initWithAbstractPath: |
| (id) | - initWithAbstractFormat: |
| (id) | - initWithFormat: |
| (id) | - initFileURLWithFormat: |
| (NSURL *) | + URLWithAbstractPath: |
| (NSURL *) | + URLWithAbstractFormat: |
| (NSURL *) | + URLWithFormat: |
| (NSURL *) | + fileURLWithFormat: |
Creation method extension.
| + (instancetype) configurationURLWithPath: | (NSString *) | path |
Initializes and returns a newly created NSURL object as a file URL with a specified path based on configuration directory.
| + (NSURL *) fileURLWithFormat: | (NSString *) | format | |
| , | (1) | ||
| (2) | __deprecated | ||
| - (instancetype) initConfigurationURLWithPath: | (NSString *) | path |
Initializes a newly created NSURL referencing the local file or directory at path based on configuration directory.
| path | The path that the NSURL object will represent. path should be a valid system path. If path begins with the prefix 'conf://', it will be removed. path should be a relative path from configuration directory |
| - (id) initFileURLWithFormat: | (NSString *) | format | |
| , | (1) | ||
| (2) | __deprecated | ||
| - (instancetype) initResourceURLWithPath: | (NSString *) | path |
Initializes a newly created NSURL referencing the local file or directory at path based on resource directory of main bundle.
| path | The path that the NSURL object will represent. path should be a valid system path. If path begins with the prefix 'res://', it will be removed. path should be a relative path from main bundle resource directory. |
| - (instancetype) initSmartURLWithPath: | (NSString *) | path |
Initializes a newly created NSURL referencing any URL decodable by protocol prefix.
| path | The path that the NSURL object will represent. path should contains known protocol prefix or be a valid system path. If path begins with the prefix "http://" or "https://", it would be initialized with initWithString:. If path begins with the prefix "res://", it would be initialized with initResourceURLWithPath:. If path begins with the prefix "conf://", it would be initialized with initConfigurationURLWithPath:. Else path should be a valid file system path. It would be initialized with initFileURLWithPath:. |
| - (instancetype) initTemporaryURLWithPath: | (NSString *) | path |
Initializes a newly created NSURL referencing the local file or directory at path based on temporary directory.
| path | The path that the NSURL object will represent. path should be a valid system path. If path begins with the prefix 'conf://', it will be removed. path should be a relative path from temporary directory |
| - (id) initWithAbstractFormat: | (NSString *) | format | |
| , | (1) | ||
| (2) | __deprecated | ||
| - (id) initWithAbstractPath: | (NSString *) | __deprecated |
| - (id) initWithFormat: | (NSString *) | format | |
| , | (1) | ||
| (2) | __deprecated | ||
| + (instancetype) resourceURLWithPath: | (NSString *) | path |
Initializes and returns a newly created NSURL object as a file URL with a specified path based on resource directory of main bundle.
| + (instancetype) smartURLWithPath: | (NSString *) | path |
Initializes and returns a newly created NSURL referencing any URL decodable by protocol prefix.
| + (instancetype) temporaryURLWithPath: | (NSString *) | path |
Initializes and returns a newly created NSURL object as a file URL with a specified path based on temporary directory.
| + (NSURL *) URLWithAbstractFormat: | (NSString *) | format | |
| , | (1) | ||
| (2) | __deprecated | ||
| + (NSURL *) URLWithAbstractPath: | (NSString *) | __deprecated |
| + (NSURL *) URLWithFormat: | (NSString *) | format | |
| , | (1) | ||
| (2) | __deprecated | ||