| Inherits from | |
|---|---|
| Declared in | NNFile.h |
Represents a file that can be tagged. Uses a subclass of NNTagReaderWriter to access the backing storage.
- initWithPath:
- initWithPath:displayName:kind:contentType:lastUsed:contentTypeTree:tags:
- setPath:
- path
- standardizedPath
- filename
- url
- extension
- parentDirectory
- isDirectory
- icon
- kind
- creationDate
- modificationDate
- size
- isInManagedHierarchy
- loadTags
- destinationForNewFile:
+ (NNFile *)fileWithPath:(NSString *)aPath path to file
NNFile representing file at aPath
create a new NNFile from a path
NNFile.h+ (NSArray *)filesWithFilepaths:(NSArray *)filepaths paths to file (NSArray of NSString)
NSArray of NNFiles representing file at aPath
create a new NSArray of NNFiles from a NSArray of file paths (NSString)
NNFile.h+ (NNFile *)fileWithPath:(NSString *)aPath displayName:(NSString *)aDisplayName kind:(NSString *)aKind contentType:(NSString *)aContentType lastUsed:(NSDate *)lastUsed contentTypeTree:(NSArray *)aContentTypeTree tags:(NSArray *)someTags Use this initializer to create a file without ever accessing the spotlight db. This is currently the fastest way!
NNFile.h- (id)initWithPath:(NSString *)aPath path to file
NNFile representing file at aPath
create a new NNFile from a path
NNFile.h- (id)initWithPath:(NSString *)aPath displayName:(NSString *)aDisplayName kind:(NSString *)aKind contentType:(NSString *)aContentType lastUsed:(NSDate *)lastUsed contentTypeTree:(NSArray *)aContentTypeTree tags:(NSArray *)someTags Path to file
Display name to use
File kind
Content type
Date this file was last used
Content type tree
tags on file
New NNFile for params
Use this initializer to create a file without ever accessing the spotlight db. This is currently the fastest way!
NNFile.h- (void)setPath:(NSString *)path New file path
NNFile.h- (NSString *)pathFull path including file.extension
NNFile.h- (NSString *)standardizedPathStandardized path (stringByStandardizingPath)
NNFile.h- (NSString *)filenameFile name including extension
NNFile.h- (NSURL *)urlFull path as file URL
NNFile.h- (NSString *)extensionFile extension
NNFile.h- (NSString *)parentDirectoryDirectory path the file is located in
NNFile.h- (BOOL)isDirectoryYES if file is a directory, NO otherwise
NNFile.h- (NSImage *)iconIcon representing file
NNFile.h- (NSString *)kindA description of the kind of item this file represents
NNFile.h- (NSDate *)creationDateFile creation date
NNFile.h- (NSDate *)modificationDateFile modification date
NNFile.h- (unsigned long long)sizeFile's logical size in bytes (data + resource fork). Does not work for folders.
NNFile.h- (BOOL)isInManagedHierarchyYES if this is the case, NO otherwise
Checks if the self is already located in the managed files directory (or a subdirectory).
NNFile.h- (NSMutableSet *)loadTagstags read from storage
loads tags from backing storage
NNFile.m- (NSString *)destinationForNewFile:(NSString *)fileName name of the new file
complete path for the new file. save the drop data there
helper method
returns the destination for a file to be written use this to get a destination for the dropped data, it will consider user settings of managing files
NNFile.mLast updated: 2010-5-13