1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- //
- // ASFileManager.h
- // AIPlayRingtones
- //
- // Created by mini on 2025/5/28.
- //
- #import <Foundation/Foundation.h>
- NS_ASSUME_NONNULL_BEGIN
- @interface ASFileManager : NSObject
- + (NSURL *)documentsDirectory;
- + (NSURL *)cacheDirectory;
- + (void)copyFileWithOverwriteFrom:(NSURL *)sourceURL to:(NSURL *)targetURL;
- + (void)removeItemFrom:(NSURL *)sourceURL;
- + (void)checkFolderAndCreateFrom:(NSURL *)destinationURL;
- + (BOOL)fileExistsAtURL:(NSURL *)url;
- + (void)createDirectoryAtURL:(NSURL *)url error:(NSError **)error;
- + (NSString *)getCacheSubPathAtURL:(NSURL *)url;
- @end
- @interface NSString (CachePath)
- @property (nonatomic, readonly) BOOL isCachesPath;
- @property (nonatomic, readonly) NSString *fillCachePath;
- @property (nonatomic, readonly) NSURL *fillCacheURL;
- @property (nonatomic, readonly) NSString *cachesLastURLString;
- @end
- @interface NSString (DocumentPath)
- @property (nonatomic, readonly) BOOL isDocumentPath;
- @property (nonatomic, readonly) NSString *fillDocumentPath;
- @property (nonatomic, readonly) NSURL *fillDocumentURL;
- @property (nonatomic, readonly) NSString *documentLastURLString;
- @end
- NS_ASSUME_NONNULL_END
|