Hey, I was wondering if anyone knew details on some of the new(ish) methods in the plugin API. They don’t seem to have any comments in the headers and there are no docs (that I’m aware of).
Here are some examples of stuff that’s a mystery to me from RWAbstrackPlugin.h
in the RWKit framework of the latest RW7 builds:
what’s this one for? is it different from the regular old NSFileManager similar stuff? is this something a plugin should subclass? or call?
- (NSArray *)directoryContents:(NSString *)path;
i’ve asked what the pluginStorage value is – someone might have told me once, but i’ve forgotten (my bad). is it per-document or global for all documents? is it persisted? what’s it for? do any of the built-in plugins use this for something that might be a good example for me to consider?
- (RWSharedStorage *)sharedPluginStorage;
i don’t think this one is very new, but I’ve never used it as I don’t really know what it’s for. any hints? what sort of values should i pass it? where will they get displayed? do the built in plugins use it?
- (NSMutableDictionary *)pluginSettingsValueForDisplay:(NSString *)display value:(id)value;
i can guess that these are for managing URL <-> sandbox-bookmarks – but the details on how to use them aren’t super obvious. would be great to have a hint at what “token” means etc.
- (NSString *)registerFileURL:(NSURL *)fileURL error:(NSError **)error;
- (void)removeFileReferenceForToken:(NSString *)token;
- (NSURL *)fileURLForToken:(NSString *)token error:(NSError **)error;
i should note that i found a nice doc on github that details some new RW7 things…
AWSUM!!! MOAR PLZ!!! KTHXBAI!!!
i did find that ```+ (BOOL)canCreateNewPage:(NSError **)errorRef;
+ (void)willMigrateAddonLocation;
https://github.com/realmacsoftware/RWPluginKit/wiki/Changes-in-RapidWeaver-7
thanks!