// // P4FileManager.h // P4Menu // // Created by Michael Bishop on 7/29/11. // Copyright 2011 Numerical Garden LLC. All rights reserved. // #import <Foundation/Foundation.h> @class P4Connection, P4Client, P4LocalFileManager, P4FilePath; typedef void(^FileUpdateBlock)(P4LocalFileManager * fileManager, NSString * localFilePath, NSDictionary * fileInfo); @interface P4FileObserverToken : NSObject { @private NSString * path; FileUpdateBlock block; P4LocalFileManager * fileManager; } +(id)tokenRegisteringLocalFilePath:(NSString*)path withFileManager:(P4LocalFileManager*)fileManager observationBlock:(FileUpdateBlock)block; -(void)unregister; @end @interface P4LocalFileManager : NSObject { @private P4Connection * connection; NSString * _clientName; NSMutableDictionary * _fileInfoCache; NSError * _lastError; NSString * _cachedTemporaryDirectory; } +(P4LocalFileManager*)managerWithPortString:(NSString*)portString username:(NSString*)username clientName:(NSString*)clientName; +(P4LocalFileManager*)managerWithClient:(P4Client*)client; -(P4Client*)client; -(NSDictionary*)informationForLocalFilePath:(NSString*)localfilepath; -(BOOL)purgeData:(NSError**)error; -(void)purgeDataForLocalPath:(NSString*)localPath; -(void)fetchInformationForLocalFilePath:(NSString*)localfilepath; @property (readonly, nonatomic, retain) NSError * lastError; @property (readonly, nonatomic, copy) NSString * clientName; -(void)contentForFilePath:(P4FilePath*)filepath block:(void(^)(NSString*, NSError*))block; @end
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#1 | 20722 | jdputsch | initial branch, prep for -Zapp= support | ||
//guest/michael_bishop/MacMenu/src/P4ObjectLayer/P4LocalFileManager.h | |||||
#1 | 8331 | Matt Attaway |
Adding initial version of MacMenu for Perforce MacMenu is a helpful Perforce client that sits in your toolbar. It allows you to run standard Perforce operations on the document that is open the currently active editor/viewer. |