public class NSURL extends NSObject implements NSSecureCoding, NSCopying, NSItemProviderReading, NSItemProviderWriting, QLPreviewItem
NSObject.Function_instanceMethodForSelector_ret, NSObject.Function_methodForSelector_retNSItemProviderWriting.Block_loadDataWithTypeIdentifierForItemProviderCompletionHandler| Modifier | Constructor and Description |
|---|---|
protected |
NSURL(org.moe.natj.general.Pointer peer) |
| Modifier and Type | Method and Description |
|---|---|
long |
_itemProviderVisibilityForRepresentationWithTypeIdentifier_static(java.lang.String typeIdentifier) |
NSURL |
_objectWithItemProviderDataTypeIdentifierError(NSData data,
java.lang.String typeIdentifier,
org.moe.natj.general.ptr.Ptr<NSError> outError) |
NSArray<java.lang.String> |
_readableTypeIdentifiersForItemProvider() |
boolean |
_supportsSecureCoding()
This property must return YES on all classes that allow secure coding.
|
NSArray<java.lang.String> |
_writableTypeIdentifiersForItemProvider_static() |
java.lang.String |
absoluteString() |
NSURL |
absoluteURL()
if the receiver is itself absolute, this will return self.
|
static NSURL |
absoluteURLWithDataRepresentationRelativeToURL(NSData data,
NSURL baseURL)
Initializes and returns a newly created absolute NSURL using the contents of the given data, relative to a base URL.
|
static boolean |
accessInstanceVariablesDirectly() |
static NSURL |
alloc() |
static NSURL |
allocWithZone(org.moe.natj.general.ptr.VoidPtr zone) |
static boolean |
automaticallyNotifiesObserversForKey(java.lang.String key) |
NSURL |
baseURL()
may be nil.
|
static NSData |
bookmarkDataWithContentsOfURLError(NSURL bookmarkFileURL,
org.moe.natj.general.ptr.Ptr<NSError> error)
Initializes and returns bookmark data derived from an alias file pointed to by a specified URL.
|
NSData |
bookmarkDataWithOptionsIncludingResourceValuesForKeysRelativeToURLError(long options,
NSArray<java.lang.String> keys,
NSURL relativeURL,
org.moe.natj.general.ptr.Ptr<NSError> error)
Returns bookmark data for the URL, created with specified options and resource values.
|
static void |
cancelPreviousPerformRequestsWithTarget(java.lang.Object aTarget) |
static void |
cancelPreviousPerformRequestsWithTargetSelectorObject(java.lang.Object aTarget,
org.moe.natj.objc.SEL aSelector,
java.lang.Object anArgument) |
boolean |
checkPromisedItemIsReachableAndReturnError(org.moe.natj.general.ptr.Ptr<NSError> error) |
boolean |
checkResourceIsReachableAndReturnError(org.moe.natj.general.ptr.Ptr<NSError> error)
Returns whether the URL's resource exists and is reachable.
|
static NSArray<java.lang.String> |
classFallbacksForKeyedArchiver() |
static org.moe.natj.objc.Class |
classForKeyedUnarchiver() |
java.lang.Object |
copyWithZone(org.moe.natj.general.ptr.VoidPtr zone) |
NSData |
dataRepresentation()
Returns the data representation of the URL's relativeString.
|
static java.lang.String |
debugDescription_static() |
static java.lang.String |
description_static() |
void |
encodeWithCoder(NSCoder coder) |
NSURL |
filePathURL()
Returns a file path URL that refers to the same resource as a specified URL.
|
NSURL |
fileReferenceURL()
Returns a file reference URL that refers to the same resource as a specified file URL.
|
java.lang.String |
fileSystemRepresentation()
Returns the URL's path in file system representation.
|
static NSURL |
fileURLWithFileSystemRepresentationIsDirectoryRelativeToURL(java.lang.String path,
boolean isDir,
NSURL baseURL)
Initializes and returns a newly created URL referencing the local file or directory at the file system representation of the path.
|
static NSURL |
fileURLWithPath(java.lang.String path)
Better to use fileURLWithPath:isDirectory: if you know if the path is a directory vs non-directory, as it saves an i/o.
|
static NSURL |
fileURLWithPathComponents(NSArray<java.lang.String> components)
The following methods work on the path portion of a URL in the same manner that the NSPathUtilities methods on NSString do.
|
static NSURL |
fileURLWithPathIsDirectory(java.lang.String path,
boolean isDir) |
static NSURL |
fileURLWithPathIsDirectoryRelativeToURL(java.lang.String path,
boolean isDir,
NSURL baseURL)
Initializes and returns a newly created file NSURL referencing the local file or directory at path, relative to a base URL.
|
static NSURL |
fileURLWithPathRelativeToURL(java.lang.String path,
NSURL baseURL)
Better to use fileURLWithPath:isDirectory:relativeToURL: if you know if the path is a directory vs non-directory, as it saves an I/O.
|
java.lang.String |
fragment() |
boolean |
getFileSystemRepresentationMaxLength(org.moe.natj.general.ptr.BytePtr buffer,
long maxBufferLength)
Returns the URL's path in file system representation.
|
boolean |
getPromisedItemResourceValueForKeyError(org.moe.natj.general.ptr.Ptr<org.moe.natj.objc.ObjCObject> value,
java.lang.String key,
org.moe.natj.general.ptr.Ptr<NSError> error)
Get resource values from URLs of 'promised' items.
|
boolean |
getResourceValueForKeyError(org.moe.natj.general.ptr.Ptr<org.moe.natj.objc.ObjCObject> value,
java.lang.String key,
org.moe.natj.general.ptr.Ptr<NSError> error)
Returns the resource value identified by a given resource key.
|
boolean |
hasDirectoryPath()
Determines if a given URL string's path represents a directory (i.e.
|
static long |
hash_static() |
java.lang.String |
host()
If the URL conforms to rfc 1808 (the most common form of URL), the following accessors will return the various components; otherwise they return nil.
|
NSURL |
init() |
NSURL |
initAbsoluteURLWithDataRepresentationRelativeToURL(NSData data,
NSURL baseURL)
Initializes a newly created absolute NSURL using the contents of the given data, relative to a base URL.
|
NSURL |
initByResolvingBookmarkDataOptionsRelativeToURLBookmarkDataIsStaleError(NSData bookmarkData,
long options,
NSURL relativeURL,
org.moe.natj.general.ptr.BoolPtr isStale,
org.moe.natj.general.ptr.Ptr<NSError> error)
Initializes a newly created NSURL that refers to a location specified by resolving bookmark data.
|
NSURL |
initFileURLWithFileSystemRepresentationIsDirectoryRelativeToURL(java.lang.String path,
boolean isDir,
NSURL baseURL)
Initializes a newly created URL referencing the local file or directory at the file system representation of the path.
|
NSURL |
initFileURLWithPath(java.lang.String path)
Better to use initFileURLWithPath:isDirectory: if you know if the path is a directory vs non-directory, as it saves an i/o.
|
NSURL |
initFileURLWithPathIsDirectory(java.lang.String path,
boolean isDir) |
NSURL |
initFileURLWithPathIsDirectoryRelativeToURL(java.lang.String path,
boolean isDir,
NSURL baseURL)
Initializes a newly created file NSURL referencing the local file or directory at path, relative to a base URL.
|
NSURL |
initFileURLWithPathRelativeToURL(java.lang.String path,
NSURL baseURL)
Better to use initFileURLWithPath:isDirectory:relativeToURL: if you know if the path is a directory vs non-directory, as it saves an I/O.
|
NSURL |
initWithCoder(NSCoder coder)
NS_DESIGNATED_INITIALIZER
|
NSURL |
initWithDataRepresentationRelativeToURL(NSData data,
NSURL baseURL)
Initializes a newly created NSURL using the contents of the given data, relative to a base URL.
|
NSURL |
initWithSchemeHostPath(java.lang.String scheme,
java.lang.String host,
java.lang.String path)
Deprecated.
|
NSURL |
initWithString(java.lang.String URLString)
These methods expect their string arguments to contain any percent escape codes that are necessary.
|
NSURL |
initWithStringRelativeToURL(java.lang.String URLString,
NSURL baseURL) |
static NSObject.Function_instanceMethodForSelector_ret |
instanceMethodForSelector(org.moe.natj.objc.SEL aSelector) |
static NSMethodSignature |
instanceMethodSignatureForSelector(org.moe.natj.objc.SEL aSelector) |
static boolean |
instancesRespondToSelector(org.moe.natj.objc.SEL aSelector) |
boolean |
isFileReferenceURL()
Returns whether the URL is a file reference URL.
|
boolean |
isFileURL()
Whether the scheme is file:; if [myURL isFileURL] is YES, then [myURL path] is suitable for input into NSFileManager or NSPathUtilities.
|
static boolean |
isSubclassOfClass(org.moe.natj.objc.Class aClass) |
static long |
itemProviderVisibilityForRepresentationWithTypeIdentifier_static(java.lang.String typeIdentifier) |
long |
itemProviderVisibilityForRepresentationWithTypeIdentifier(java.lang.String typeIdentifier) |
static NSSet<java.lang.String> |
keyPathsForValuesAffectingValueForKey(java.lang.String key) |
java.lang.String |
lastPathComponent() |
NSProgress |
loadDataWithTypeIdentifierForItemProviderCompletionHandler(java.lang.String typeIdentifier,
NSItemProviderWriting.Block_loadDataWithTypeIdentifierForItemProviderCompletionHandler completionHandler)
One of writableTypeIdentifiersForItemProvider
|
static NSURL |
new_objc() |
static NSURL |
objectWithItemProviderDataTypeIdentifierError(NSData data,
java.lang.String typeIdentifier,
org.moe.natj.general.ptr.Ptr<NSError> outError) |
java.lang.String |
parameterString() |
java.lang.String |
password() |
java.lang.String |
path() |
NSArray<java.lang.String> |
pathComponents() |
java.lang.String |
pathExtension() |
NSNumber |
port() |
java.lang.String |
previewItemTitle()
The item's title this will be used as apparent item title.
|
NSURL |
previewItemURL()
The URL of the item to preview.
|
NSDictionary<java.lang.String,?> |
promisedItemResourceValuesForKeysError(NSArray<java.lang.String> keys,
org.moe.natj.general.ptr.Ptr<NSError> error) |
java.lang.String |
query() |
static NSArray<java.lang.String> |
readableTypeIdentifiersForItemProvider() |
java.lang.String |
relativePath()
The same as path if baseURL is nil
|
java.lang.String |
relativeString()
The relative portion of a URL.
|
void |
removeAllCachedResourceValues()
Removes all cached resource values and all temporary resource values from the URL object.
|
void |
removeCachedResourceValueForKey(java.lang.String key)
Removes the cached resource value identified by a given resource value key from the URL object.
|
static boolean |
resolveClassMethod(org.moe.natj.objc.SEL sel) |
static boolean |
resolveInstanceMethod(org.moe.natj.objc.SEL sel) |
java.lang.String |
resourceSpecifier() |
NSDictionary<java.lang.String,?> |
resourceValuesForKeysError(NSArray<java.lang.String> keys,
org.moe.natj.general.ptr.Ptr<NSError> error)
Returns the resource values identified by specified array of resource keys.
|
static NSDictionary<java.lang.String,?> |
resourceValuesForKeysFromBookmarkData(NSArray<java.lang.String> keys,
NSData bookmarkData)
Returns the resource values for properties identified by a specified array of keys contained in specified bookmark data.
|
java.lang.String |
scheme()
Any URL is composed of these two basic pieces.
|
boolean |
setResourceValueForKeyError(java.lang.Object value,
java.lang.String key,
org.moe.natj.general.ptr.Ptr<NSError> error)
Sets the resource value identified by a given resource key.
|
boolean |
setResourceValuesError(NSDictionary<java.lang.String,?> keyedValues,
org.moe.natj.general.ptr.Ptr<NSError> error)
Sets any number of resource values of a URL's resource.
|
void |
setTemporaryResourceValueForKey(java.lang.Object value,
java.lang.String key)
Sets a temporary resource value on the URL object.
|
static void |
setVersion_static(long aVersion) |
NSURL |
standardizedURL() |
boolean |
startAccessingSecurityScopedResource()
Given a NSURL created by resolving a bookmark data created with security scope, make the resource referenced by the url accessible to the process.
|
void |
stopAccessingSecurityScopedResource()
Revokes the access granted to the url by a prior successful call to startAccessingSecurityScopedResource.
|
static org.moe.natj.objc.Class |
superclass_static() |
static boolean |
supportsSecureCoding() |
NSURL |
URLByAppendingPathComponent(java.lang.String pathComponent) |
NSURL |
URLByAppendingPathComponentConformingToType(java.lang.String partialName,
UTType contentType)
\brief Generate a path component based on a partial filename and a file
type, then append it to a copy of the receiver.
|
NSURL |
URLByAppendingPathComponentIsDirectory(java.lang.String pathComponent,
boolean isDirectory) |
NSURL |
URLByAppendingPathExtension(java.lang.String pathExtension) |
NSURL |
URLByAppendingPathExtensionForType(UTType contentType)
\brief Generate a path component based on the last path component of the
receiver and a file type, then append it to a copy of the receiver.
|
NSURL |
URLByDeletingLastPathComponent() |
NSURL |
URLByDeletingPathExtension() |
static NSURL |
URLByResolvingAliasFileAtURLOptionsError(NSURL url,
long options,
org.moe.natj.general.ptr.Ptr<NSError> error)
Creates and initializes a NSURL that refers to the location specified by resolving the alias file at url.
|
static NSURL |
URLByResolvingBookmarkDataOptionsRelativeToURLBookmarkDataIsStaleError(NSData bookmarkData,
long options,
NSURL relativeURL,
org.moe.natj.general.ptr.BoolPtr isStale,
org.moe.natj.general.ptr.Ptr<NSError> error)
Creates and Initializes an NSURL that refers to a location specified by resolving bookmark data.
|
NSURL |
URLByResolvingSymlinksInPath() |
NSURL |
URLByStandardizingPath()
The following methods work only on `file:` scheme URLs; for non-`file:` scheme URLs, these methods return the URL unchanged.
|
static NSURL |
URLWithDataRepresentationRelativeToURL(NSData data,
NSURL baseURL)
Initializes and returns a newly created NSURL using the contents of the given data, relative to a base URL.
|
static NSURL |
URLWithString(java.lang.String URLString) |
static NSURL |
URLWithStringRelativeToURL(java.lang.String URLString,
NSURL baseURL) |
java.lang.String |
user() |
static long |
version_static() |
static NSArray<java.lang.String> |
writableTypeIdentifiersForItemProvider_static() |
NSArray<java.lang.String> |
writableTypeIdentifiersForItemProvider() |
static boolean |
writeBookmarkDataToURLOptionsError(NSData bookmarkData,
NSURL bookmarkFileURL,
long options,
org.moe.natj.general.ptr.Ptr<NSError> error)
Creates an alias file on disk at a specified location with specified bookmark data.
|
accessibilityActivate, accessibilityActivationPoint, accessibilityAssistiveTechnologyFocusedIdentifiers, accessibilityAttributedHint, accessibilityAttributedLabel, accessibilityAttributedUserInputLabels, accessibilityAttributedValue, accessibilityContainerType, accessibilityCustomActions, accessibilityCustomRotors, accessibilityDecrement, accessibilityDragSourceDescriptors, accessibilityDropPointDescriptors, accessibilityElementAtIndex, accessibilityElementCount, accessibilityElementDidBecomeFocused, accessibilityElementDidLoseFocus, accessibilityElementIsFocused, accessibilityElements, accessibilityElementsHidden, accessibilityFrame, accessibilityHint, accessibilityIncrement, accessibilityLabel, accessibilityLanguage, accessibilityNavigationStyle, accessibilityPath, accessibilityPerformEscape, accessibilityPerformMagicTap, accessibilityRespondsToUserInteraction, accessibilityScroll, accessibilityTextualContext, accessibilityTraits, accessibilityUserInputLabels, accessibilityValue, accessibilityViewIsModal, addObserverForKeyPathOptionsContext, attemptRecoveryFromErrorOptionIndex, attemptRecoveryFromErrorOptionIndexDelegateDidRecoverSelectorContextInfo, autoContentAccessingProxy, awakeAfterUsingCoder, awakeFromNib, class_objc, classForCoder, classForKeyedArchiver, copy, dealloc, debugDescription, description, dictionaryWithValuesForKeys, didChangeValueForKey, didChangeValueForKeyWithSetMutationUsingObjects, didChangeValuesAtIndexesForKey, doesNotRecognizeSelector, fileManagerShouldProceedAfterError, fileManagerWillProcessPath, finalize_objc, forwardingTargetForSelector, forwardInvocation, hash, indexOfAccessibilityElement, isAccessibilityElement, isEqual, isKindOfClass, isMemberOfClass, isProxy, methodForSelector, methodSignatureForSelector, mutableArrayValueForKey, mutableArrayValueForKeyPath, mutableCopy, mutableOrderedSetValueForKey, mutableOrderedSetValueForKeyPath, mutableSetValueForKey, mutableSetValueForKeyPath, observationInfo, observeValueForKeyPathOfObjectChangeContext, performSelector, performSelectorInBackgroundWithObject, performSelectorOnMainThreadWithObjectWaitUntilDone, performSelectorOnMainThreadWithObjectWaitUntilDoneModes, performSelectorOnThreadWithObjectWaitUntilDone, performSelectorOnThreadWithObjectWaitUntilDoneModes, performSelectorWithObject, performSelectorWithObjectAfterDelay, performSelectorWithObjectAfterDelayInModes, performSelectorWithObjectWithObject, prepareForInterfaceBuilder, provideImageDataBytesPerRowOrigin_Size_UserInfo, removeObserverForKeyPath, removeObserverForKeyPathContext, replacementObjectForCoder, replacementObjectForKeyedArchiver, respondsToSelector, self, setAccessibilityActivationPoint, setAccessibilityAttributedHint, setAccessibilityAttributedLabel, setAccessibilityAttributedUserInputLabels, setAccessibilityAttributedValue, setAccessibilityContainerType, setAccessibilityCustomActions, setAccessibilityCustomRotors, setAccessibilityDragSourceDescriptors, setAccessibilityDropPointDescriptors, setAccessibilityElements, setAccessibilityElementsHidden, setAccessibilityFrame, setAccessibilityHint, setAccessibilityLabel, setAccessibilityLanguage, setAccessibilityNavigationStyle, setAccessibilityPath, setAccessibilityRespondsToUserInteraction, setAccessibilityTextualContext, setAccessibilityTraits, setAccessibilityUserInputLabels, setAccessibilityValue, setAccessibilityViewIsModal, setIsAccessibilityElement, setNilValueForKey, setObservationInfo, setShouldGroupAccessibilityChildren, setValueForKey, setValueForKeyPath, setValueForUndefinedKey, setValuesForKeysWithDictionary, shouldGroupAccessibilityChildren, superclass, validateValueForKeyError, validateValueForKeyPathError, valueForKey, valueForKeyPath, valueForUndefinedKey, willChangeValueForKey, willChangeValueForKeyWithSetMutationUsingObjects, willChangeValuesAtIndexesForKeypublic static NSURL URLByResolvingAliasFileAtURLOptionsError(NSURL url, long options, org.moe.natj.general.ptr.Ptr<NSError> error)
public static NSURL URLByResolvingBookmarkDataOptionsRelativeToURLBookmarkDataIsStaleError(NSData bookmarkData, long options, NSURL relativeURL, org.moe.natj.general.ptr.BoolPtr isStale, org.moe.natj.general.ptr.Ptr<NSError> error)
public static NSURL URLWithDataRepresentationRelativeToURL(NSData data, NSURL baseURL)
public static NSURL URLWithString(java.lang.String URLString)
public static NSURL URLWithStringRelativeToURL(java.lang.String URLString, NSURL baseURL)
public static NSURL absoluteURLWithDataRepresentationRelativeToURL(NSData data, NSURL baseURL)
public static boolean accessInstanceVariablesDirectly()
public static NSURL alloc()
public static NSURL allocWithZone(org.moe.natj.general.ptr.VoidPtr zone)
public static boolean automaticallyNotifiesObserversForKey(java.lang.String key)
public static NSData bookmarkDataWithContentsOfURLError(NSURL bookmarkFileURL, org.moe.natj.general.ptr.Ptr<NSError> error)
public static void cancelPreviousPerformRequestsWithTarget(java.lang.Object aTarget)
public static void cancelPreviousPerformRequestsWithTargetSelectorObject(java.lang.Object aTarget,
org.moe.natj.objc.SEL aSelector,
java.lang.Object anArgument)
public static NSArray<java.lang.String> classFallbacksForKeyedArchiver()
public static org.moe.natj.objc.Class classForKeyedUnarchiver()
public static java.lang.String debugDescription_static()
public static java.lang.String description_static()
public static NSURL fileURLWithFileSystemRepresentationIsDirectoryRelativeToURL(java.lang.String path, boolean isDir, NSURL baseURL)
public static NSURL fileURLWithPath(java.lang.String path)
public static NSURL fileURLWithPathIsDirectory(java.lang.String path, boolean isDir)
public static NSURL fileURLWithPathIsDirectoryRelativeToURL(java.lang.String path, boolean isDir, NSURL baseURL)
public static NSURL fileURLWithPathRelativeToURL(java.lang.String path, NSURL baseURL)
public static NSURL fileURLWithPathComponents(NSArray<java.lang.String> components)
public static long hash_static()
public static NSObject.Function_instanceMethodForSelector_ret instanceMethodForSelector(org.moe.natj.objc.SEL aSelector)
public static NSMethodSignature instanceMethodSignatureForSelector(org.moe.natj.objc.SEL aSelector)
public static boolean instancesRespondToSelector(org.moe.natj.objc.SEL aSelector)
public static boolean isSubclassOfClass(org.moe.natj.objc.Class aClass)
public static NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey(java.lang.String key)
public static NSURL new_objc()
public static boolean resolveClassMethod(org.moe.natj.objc.SEL sel)
public static boolean resolveInstanceMethod(org.moe.natj.objc.SEL sel)
public static NSDictionary<java.lang.String,?> resourceValuesForKeysFromBookmarkData(NSArray<java.lang.String> keys, NSData bookmarkData)
public static void setVersion_static(long aVersion)
public static org.moe.natj.objc.Class superclass_static()
public static boolean supportsSecureCoding()
public static long version_static()
public static boolean writeBookmarkDataToURLOptionsError(NSData bookmarkData, NSURL bookmarkFileURL, long options, org.moe.natj.general.ptr.Ptr<NSError> error)
public NSURL URLByAppendingPathComponent(java.lang.String pathComponent)
public NSURL URLByAppendingPathComponentIsDirectory(java.lang.String pathComponent, boolean isDirectory)
public NSURL URLByAppendingPathExtension(java.lang.String pathExtension)
public NSURL URLByDeletingLastPathComponent()
public NSURL URLByDeletingPathExtension()
public NSURL URLByResolvingSymlinksInPath()
public NSURL URLByStandardizingPath()
public java.lang.String absoluteString()
public NSURL absoluteURL()
public NSURL baseURL()
public NSData bookmarkDataWithOptionsIncludingResourceValuesForKeysRelativeToURLError(long options, NSArray<java.lang.String> keys, NSURL relativeURL, org.moe.natj.general.ptr.Ptr<NSError> error)
public boolean checkPromisedItemIsReachableAndReturnError(org.moe.natj.general.ptr.Ptr<NSError> error)
public boolean checkResourceIsReachableAndReturnError(org.moe.natj.general.ptr.Ptr<NSError> error)
public java.lang.Object copyWithZone(org.moe.natj.general.ptr.VoidPtr zone)
copyWithZone in interface NSCopyingpublic NSData dataRepresentation()
public void encodeWithCoder(NSCoder coder)
encodeWithCoder in interface NSCodingpublic NSURL filePathURL()
public NSURL fileReferenceURL()
public java.lang.String fileSystemRepresentation()
public java.lang.String fragment()
public boolean getFileSystemRepresentationMaxLength(org.moe.natj.general.ptr.BytePtr buffer,
long maxBufferLength)
public boolean getPromisedItemResourceValueForKeyError(org.moe.natj.general.ptr.Ptr<org.moe.natj.objc.ObjCObject> value,
java.lang.String key,
org.moe.natj.general.ptr.Ptr<NSError> error)
The following methods behave identically to their similarly named methods above (-getResourceValue:forKey:error:, etc.), except that they allow you to get resource values and check for presence regardless of whether the promised item's contents currently exist at the URL. You must use these APIs instead of the normal NSURL resource value APIs if and only if any of the following are true: - You are using a URL that you know came directly from one of the above APIs - You are inside the accessor block of a coordinated read or write that used NSFileCoordinatorReadingImmediatelyAvailableMetadataOnly, NSFileCoordinatorWritingForDeleting, NSFileCoordinatorWritingForMoving, or NSFileCoordinatorWritingContentIndependentMetadataOnly
Most of the NSURL resource value keys will work with these APIs. However, there are some that are tied to the item's contents that will not work, such as NSURLContentAccessDateKey or NSURLGenerationIdentifierKey. If one of these keys is used, the method will return YES, but the value for the key will be nil.
public boolean getResourceValueForKeyError(org.moe.natj.general.ptr.Ptr<org.moe.natj.objc.ObjCObject> value,
java.lang.String key,
org.moe.natj.general.ptr.Ptr<NSError> error)
public boolean hasDirectoryPath()
public java.lang.String host()
public NSURL initAbsoluteURLWithDataRepresentationRelativeToURL(NSData data, NSURL baseURL)
public NSURL initByResolvingBookmarkDataOptionsRelativeToURLBookmarkDataIsStaleError(NSData bookmarkData, long options, NSURL relativeURL, org.moe.natj.general.ptr.BoolPtr isStale, org.moe.natj.general.ptr.Ptr<NSError> error)
public NSURL initFileURLWithFileSystemRepresentationIsDirectoryRelativeToURL(java.lang.String path, boolean isDir, NSURL baseURL)
public NSURL initFileURLWithPath(java.lang.String path)
public NSURL initFileURLWithPathIsDirectory(java.lang.String path, boolean isDir)
public NSURL initFileURLWithPathIsDirectoryRelativeToURL(java.lang.String path, boolean isDir, NSURL baseURL)
public NSURL initFileURLWithPathRelativeToURL(java.lang.String path, NSURL baseURL)
public NSURL initWithCoder(NSCoder coder)
NSCodinginitWithCoder in interface NSCodingpublic NSURL initWithDataRepresentationRelativeToURL(NSData data, NSURL baseURL)
@Deprecated public NSURL initWithSchemeHostPath(java.lang.String scheme, java.lang.String host, java.lang.String path)
public NSURL initWithString(java.lang.String URLString)
public NSURL initWithStringRelativeToURL(java.lang.String URLString, NSURL baseURL)
public boolean isFileReferenceURL()
public boolean isFileURL()
public java.lang.String lastPathComponent()
public java.lang.String parameterString()
public java.lang.String password()
public java.lang.String path()
public NSArray<java.lang.String> pathComponents()
public java.lang.String pathExtension()
public NSNumber port()
public java.lang.String previewItemTitle()
QLPreviewItemThe title replaces the default item display name. This property is optional.
previewItemTitle in interface QLPreviewItempublic NSURL previewItemURL()
QLPreviewItemThe URL must be a file URL.
previewItemURL in interface QLPreviewItempublic NSDictionary<java.lang.String,?> promisedItemResourceValuesForKeysError(NSArray<java.lang.String> keys, org.moe.natj.general.ptr.Ptr<NSError> error)
public java.lang.String query()
public java.lang.String relativePath()
public java.lang.String relativeString()
public void removeAllCachedResourceValues()
public void removeCachedResourceValueForKey(java.lang.String key)
public java.lang.String resourceSpecifier()
public NSDictionary<java.lang.String,?> resourceValuesForKeysError(NSArray<java.lang.String> keys, org.moe.natj.general.ptr.Ptr<NSError> error)
public java.lang.String scheme()
public boolean setResourceValueForKeyError(java.lang.Object value,
java.lang.String key,
org.moe.natj.general.ptr.Ptr<NSError> error)
public boolean setResourceValuesError(NSDictionary<java.lang.String,?> keyedValues, org.moe.natj.general.ptr.Ptr<NSError> error)
public void setTemporaryResourceValueForKey(java.lang.Object value,
java.lang.String key)
public NSURL standardizedURL()
public boolean startAccessingSecurityScopedResource()
public void stopAccessingSecurityScopedResource()
public boolean _supportsSecureCoding()
NSSecureCoding_supportsSecureCoding in interface NSSecureCodingpublic java.lang.String user()
public static long itemProviderVisibilityForRepresentationWithTypeIdentifier_static(java.lang.String typeIdentifier)
public long _itemProviderVisibilityForRepresentationWithTypeIdentifier_static(java.lang.String typeIdentifier)
_itemProviderVisibilityForRepresentationWithTypeIdentifier_static in interface NSItemProviderWritingpublic long itemProviderVisibilityForRepresentationWithTypeIdentifier(java.lang.String typeIdentifier)
public NSProgress loadDataWithTypeIdentifierForItemProviderCompletionHandler(java.lang.String typeIdentifier, NSItemProviderWriting.Block_loadDataWithTypeIdentifierForItemProviderCompletionHandler completionHandler)
NSItemProviderWritingloadDataWithTypeIdentifierForItemProviderCompletionHandler in interface NSItemProviderWritingpublic static NSURL objectWithItemProviderDataTypeIdentifierError(NSData data, java.lang.String typeIdentifier, org.moe.natj.general.ptr.Ptr<NSError> outError)
public NSURL _objectWithItemProviderDataTypeIdentifierError(NSData data, java.lang.String typeIdentifier, org.moe.natj.general.ptr.Ptr<NSError> outError)
_objectWithItemProviderDataTypeIdentifierError in interface NSItemProviderReadingpublic static NSArray<java.lang.String> readableTypeIdentifiersForItemProvider()
public NSArray<java.lang.String> _readableTypeIdentifiersForItemProvider()
_readableTypeIdentifiersForItemProvider in interface NSItemProviderReadingpublic static NSArray<java.lang.String> writableTypeIdentifiersForItemProvider_static()
public NSArray<java.lang.String> _writableTypeIdentifiersForItemProvider_static()
_writableTypeIdentifiersForItemProvider_static in interface NSItemProviderWritingpublic NSArray<java.lang.String> writableTypeIdentifiersForItemProvider()
public NSURL URLByAppendingPathComponentConformingToType(java.lang.String partialName, UTType contentType)
\param partialName The partial filename that should be expanded upon, e.g. \c "readme". \param contentType The type the resulting file should conform to, e.g. \c UTTypePlainText.
\result A complete URL. Using the argument examples above, this method would return a URL with a last path component of \c "readme.txt".
Use this method when you have partial input from a user or other source and need to produce a complete filename suitable for that input. For example, if you are downloading a file from the Internet and know its MIME type, you can use this method to ensure the correct filename extension is applied to the URL where you save the file.
If \a partialName already has a path extension, and that path extension is valid for file system objects of type \a contentType, no additional extension is appended to the path component before constructing the URL. For example, if the inputs are \c "puppy.jpg" and \c UTTypeImage respectively, then the resulting URL will have a last path component of \c "puppy.jpg" . On the other hand, if the inputs are \c "puppy.jpg" and \c UTTypePlainText respectively, the resulting URL will have a last path component of \c "puppy.jpg.txt" . If you want to ensure any existing path extension is replaced, you can use the \c URLByDeletingPathExtension property first.
If the path component could not be appended, this method returns a copy of \c self .
\note The resulting URL has a directory path if \c contentType conforms to \c UTTypeDirectory .
public NSURL URLByAppendingPathExtensionForType(UTType contentType)
\param contentType The type the resulting file should conform to, e.g. \c UTTypePlainText.
\result A complete URL. Using the argument example above and assuming the receiver equals \c "file:///readme" , this method would return \c "file:///readme.txt".
Use this method when you have partial input from a user or other source and need to produce a complete filename suitable for that input. For example, if you are downloading a file from the Internet and know its MIME type, you can use this method to ensure the correct filename extension is applied to the URL where you save the file.
If the receiver already has a path extension, and that path extension is valid for file system objects of type \a contentType, no additional extension is appended to the path component before constructing the URL. For example, if the receiver's last path component equals \c "puppy.jpg" and \a contentType equals \c UTTypeImage , then the resulting URL will have a last path component of \c "puppy.jpg" . On the other hand, if the inputs are \c "puppy.jpg" and \c UTTypePlainText respectively, the resulting URL will have a last path component of \c "puppy.jpg.txt" . If you want to ensure any existing path extension is replaced, you can use the \c URLByDeletingPathExtension property first.
If the extension could not be appended, this method returns a copy of \c self .
\note The resulting URL has a directory path if \c contentType conforms to \c UTTypeDirectory .