Revision: 24025
          http://sourceforge.net/p/bibdesk/svn/24025
Author:   hofman
Date:     2019-07-15 13:43:32 +0000 (Mon, 15 Jul 2019)
Log Message:
-----------
use properties for group classes

Modified Paths:
--------------
    trunk/bibdesk/BDSKCategoryGroup.h
    trunk/bibdesk/BDSKCategoryGroup.m
    trunk/bibdesk/BDSKEntrezGroupServer.h
    trunk/bibdesk/BDSKEntrezGroupServer.m
    trunk/bibdesk/BDSKExternalGroup.h
    trunk/bibdesk/BDSKExternalGroup.m
    trunk/bibdesk/BDSKGroup.h
    trunk/bibdesk/BDSKGroup.m
    trunk/bibdesk/BDSKParentGroup.h
    trunk/bibdesk/BDSKParentGroup.m
    trunk/bibdesk/BDSKScriptGroup.h
    trunk/bibdesk/BDSKScriptGroup.m
    trunk/bibdesk/BDSKSearchGroup.h
    trunk/bibdesk/BDSKSearchGroup.m
    trunk/bibdesk/BDSKSharedGroup.h
    trunk/bibdesk/BDSKSharedGroup.m
    trunk/bibdesk/BDSKSmartGroup.h
    trunk/bibdesk/BDSKSmartGroup.m
    trunk/bibdesk/BDSKStaticGroup.h
    trunk/bibdesk/BDSKStaticGroup.m
    trunk/bibdesk/BDSKURLGroup.h
    trunk/bibdesk/BDSKURLGroup.m
    trunk/bibdesk/BDSKWebGroup.h
    trunk/bibdesk/BDSKWebGroup.m
    trunk/bibdesk/BDSKZoomGroupServer.h
    trunk/bibdesk/BDSKZoomGroupServer.m

Modified: trunk/bibdesk/BDSKCategoryGroup.h
===================================================================
--- trunk/bibdesk/BDSKCategoryGroup.h   2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKCategoryGroup.h   2019-07-15 13:43:32 UTC (rev 24025)
@@ -53,21 +53,10 @@
 */
 - (id)initWithName:(id)aName key:(NSString *)aKey;
 
-/*!
-       @method key
-       @abstract Returns the key of the group.
-       @discussion -
-*/
-- (NSString *)key;
+@property (nonatomic, readonly) NSString *key;
 
-/*!
-       @method setName:
-       @param newName The new name for the group.
-       @abstract Returns the key of the group.
-       @discussion This is only used to preserve the selection after an edit
-*/
-- (void)setName:(id)newName;
+@property (nonatomic, retain) id name;
 
-- (BOOL)isEmpty;
+@property (nonatomic, readonly, getter=isEmpty) BOOL empty;
 
 @end

Modified: trunk/bibdesk/BDSKCategoryGroup.m
===================================================================
--- trunk/bibdesk/BDSKCategoryGroup.m   2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKCategoryGroup.m   2019-07-15 13:43:32 UTC (rev 24025)
@@ -50,6 +50,8 @@
 
 @implementation BDSKCategoryGroup
 
+@dynamic key, name, empty;
+
 // designated initializer
 - (id)initWithName:(id)aName key:(NSString *)aKey {
     if (aName == nil) {

Modified: trunk/bibdesk/BDSKEntrezGroupServer.h
===================================================================
--- trunk/bibdesk/BDSKEntrezGroupServer.h       2019-07-15 06:31:17 UTC (rev 
24024)
+++ trunk/bibdesk/BDSKEntrezGroupServer.h       2019-07-15 13:43:32 UTC (rev 
24025)
@@ -58,12 +58,9 @@
     NSString *errorMessage;
 }
 
-- (void)setSearchTerm:(NSString *)string;
-- (NSString *)searchTerm;
-- (void)setWebEnv:(NSString *)env;
-- (NSString *)webEnv;
-- (void)setQueryKey:(NSString *)aKey;
-- (NSString *)queryKey;
+@property(nonatomic, copy) NSString *searchTerm;
+@property(nonatomic, copy) NSString *webEnv;
+@property(nonatomic, copy) NSString *queryKey;
 
 - (void)resetSearch;
 - (void)fetch;

Modified: trunk/bibdesk/BDSKEntrezGroupServer.m
===================================================================
--- trunk/bibdesk/BDSKEntrezGroupServer.m       2019-07-15 06:31:17 UTC (rev 
24024)
+++ trunk/bibdesk/BDSKEntrezGroupServer.m       2019-07-15 13:43:32 UTC (rev 
24025)
@@ -64,6 +64,8 @@
 
 @implementation BDSKEntrezGroupServer
 
+@synthesize searchTerm, webEnv, queryKey;
+
 enum { BDSKIdleState, BDSKEsearchState, BDSKEfetchState };
 
 + (NSString *)baseURLString { return 
@"https://eutils.ncbi.nlm.nih.gov/entrez/eutils";; }
@@ -170,38 +172,6 @@
 
 - (NSFormatter *)searchStringFormatter { return nil; }
 
-#pragma mark Other accessors
-
-- (void)setSearchTerm:(NSString *)string;
-{
-    if(searchTerm != string){
-        [searchTerm release];
-        searchTerm = [string copy];
-    }
-}
-
-- (NSString *)searchTerm { return searchTerm; }
-
-- (void)setWebEnv:(NSString *)env;
-{
-    if(webEnv != env){
-        [webEnv release];
-        webEnv = [env copy];
-    }
-}
-
-- (NSString *)webEnv { return webEnv; }
-
-- (void)setQueryKey:(NSString *)aKey;
-{
-    if(queryKey != aKey){
-        [queryKey release];
-        queryKey = [aKey copy];
-    }
-}
-
-- (NSString *)queryKey { return queryKey; }
-
 #pragma mark Search methods
 
 - (void)resetSearch;

Modified: trunk/bibdesk/BDSKExternalGroup.h
===================================================================
--- trunk/bibdesk/BDSKExternalGroup.h   2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKExternalGroup.h   2019-07-15 13:43:32 UTC (rev 24025)
@@ -58,8 +58,6 @@
 
 - (BDSKItemSearchIndexes *)searchIndexes;
 
-- (BDSKPublicationsArray *)publications;
-
 // for subclasses to use
 
 - (void)setPublications:(NSArray *)newPublications;
@@ -70,7 +68,8 @@
 
 // for subclasses to override
 
-- (BOOL)shouldRetrievePublications;
+@property(nonatomic, readonly) BOOL shouldRetrievePublications;
+
 - (void)retrievePublications;
 
 - (void)stopRetrieving;
@@ -83,7 +82,6 @@
     NSString *errorMessage;
 }
 
-- (NSString *)errorMessage;
-- (void)setErrorMessage:(NSString *)newErrorMessage;
+@property (nonatomic, retain) NSString *errorMessage;
 
 @end

Modified: trunk/bibdesk/BDSKExternalGroup.m
===================================================================
--- trunk/bibdesk/BDSKExternalGroup.m   2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKExternalGroup.m   2019-07-15 13:43:32 UTC (rev 24025)
@@ -48,6 +48,8 @@
 
 @implementation BDSKExternalGroup
 
+@dynamic shouldRetrievePublications;
+
 // designated initializer
 - (id)initWithName:(NSString *)aName {
     NSAssert(aName != nil, @"External group requires a name");
@@ -217,6 +219,8 @@
 
 @implementation BDSKMutableExternalGroup
 
+@synthesize errorMessage;
+
 - (void)dealloc {
     BDSKDESTROY(errorMessage);
     [super dealloc];
@@ -231,17 +235,6 @@
     }
 }
 
-- (NSString *)errorMessage {
-    return errorMessage;
-}
-
-- (void)setErrorMessage:(NSString *)newErrorMessage {
-    if (errorMessage != newErrorMessage) {
-        [errorMessage release];
-        errorMessage = [newErrorMessage retain];
-    }
-}
-
 - (NSUndoManager *)undoManager {
     return [document undoManager];
 }

Modified: trunk/bibdesk/BDSKGroup.h
===================================================================
--- trunk/bibdesk/BDSKGroup.h   2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKGroup.h   2019-07-15 13:43:32 UTC (rev 24025)
@@ -81,116 +81,41 @@
 - (id)initWithName:(id)aName;
 
 - (id)initWithDictionary:(NSDictionary *)groupDict;
-- (NSDictionary *)dictionaryValue;
 
-- (NSString *)uniqueID;
+@property (nonatomic, readonly) NSDictionary *dictionaryValue;
 
-/*!
-       @method name
-       @abstract Returns the name of the group.
-       @discussion -
-*/
-- (id)name;
+@property (nonatomic, readonly) NSString *uniqueID;
 
-- (NSString *)label;
+@property (nonatomic, readonly) id name;
+@property (nonatomic, readonly) NSString *label;
+@property (nonatomic) NSInteger count;
+@property (nonatomic, readonly) NSImage *icon;
 
-/*!
-       @method count
-       @abstract Returns the count of the group.
-       @discussion -
-*/
-- (NSInteger)count;
+@property (nonatomic, readonly) BDSKGroupType groupType;
 
-/*!
-       @method setCount:
-       @abstract Sets the count for the group.
-       @discussion -
-       @param newCount The new count to set.
-*/
-- (void)setCount:(NSInteger)newCount;
+@property (nonatomic, readonly) BOOL isNameEditable;
+@property (nonatomic, readonly) BOOL isEditable;
+@property (nonatomic, readonly) BOOL allowsRemoval;
+@property (nonatomic, readonly) BOOL failedDownload;
+@property (nonatomic, readonly) BOOL isRetrieving;
 
-/*!
-       @method icon
-       @abstract Returns the icon for the group.
-       @discussion -
-*/
-- (NSImage *)icon;
+@property (nonatomic, readonly) NSString *stringValue;
+@property (nonatomic, readonly) NSNumber *numberValue;
+@property (nonatomic, readonly) NSString *editingStringValue;
+@property (nonatomic, readonly) id cellValue;
 
-/*!
-       @method grouptType
-       @abstract enumeration, returns the type of the group. 
-       @discussion -
-*/
-- (BDSKGroupType)groupType;
+@property (nonatomic, readonly) NSString *toolTip;
 
-/*!
-    @method     isNameEditable
-    @abstract   Returns NO by default.  Editable subclasses should override 
this to allow changing the name of a group.
-*/
-- (BOOL)isNameEditable;
+@property (nonatomic, readonly) NSString *errorMessage;
 
-/*!
- @method     isEditable
- @abstract   Returns NO by default.  Editable subclasses should override this 
to allow editing of its properties.
- */
-- (BOOL)isEditable;
+@property (nonatomic, assign) BDSKParentGroup *parent;
 
-/*!
- @method     allowsRemoval
- @abstract   Returns NO by default.  Subclasses that allow removing 
publications should override this to allow removal.
- */
-- (BOOL)allowsRemoval;
+@property (nonatomic, assign) BibDocument *document;
 
-/*!
-    @method     failedDownload
-    @abstract   Method for remote groups.  Returns NO by default.
-*/
-- (BOOL)failedDownload;
+@property (nonatomic, readonly) BDSKMacroResolver *macroResolver;
 
-/*!
-    @method     isRetrieving
-    @abstract   Method for remote groups.  Returns NO by default.
-*/
-- (BOOL)isRetrieving;
+@property (nonatomic, readonly) NSArray *publications;
 
-/*!
-       @method stringValue
-       @abstract Returns string value of the name.
-       @discussion -
-*/
-- (NSString *)stringValue;
-
-/*!
-       @method numberValue
-       @abstract Returns count as an NSNumber.
-       @discussion -
-*/
-- (NSNumber *)numberValue;
-
-- (NSString *)editingStringValue;
-
-- (id)cellValue;
-
-- (NSString *)toolTip;
-
-- (NSString *)errorMessage;
-
-- (BDSKParentGroup *)parent;
-- (void)setParent:(BDSKParentGroup *)newParent;
-
-- (BibDocument *)document;
-- (void)setDocument:(BibDocument *)newDocument;
-
-- (BDSKMacroResolver *)macroResolver;
-
-- (NSArray *)publications;
-
-/*!
-       @method containsItem:
-       @abstract Returns a boolean indicating whether the item is contained in 
the group.
-       @discussion -
-       @param item A BibItem to test for containment.
-*/
 - (BOOL)containsItem:(BibItem *)item;
 
 @end
@@ -198,8 +123,8 @@
 
 @protocol BDSKMutableGroup <NSObject>
 
-- (void)setName:(id)newName;
-- (NSUndoManager *)undoManager;
+@property (nonatomic, retain) id name;
+@property (nonatomic, readonly) NSUndoManager *undoManager;
 
 @end
 

Modified: trunk/bibdesk/BDSKGroup.m
===================================================================
--- trunk/bibdesk/BDSKGroup.m   2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKGroup.m   2019-07-15 13:43:32 UTC (rev 24025)
@@ -49,6 +49,9 @@
 
 @implementation BDSKGroup
 
+@synthesize uniqueID, name, count, parent, document;
+@dynamic dictionaryValue, label, icon, groupType, isNameEditable, isEditable, 
allowsRemoval, failedDownload, isRetrieving, stringValue, numberValue, 
editingStringValue, cellValue, toolTip, errorMessage, macroResolver, 
publications;
+
 static NSArray *cellValueKeys = nil;
 static NSArray *noCountCellValueKeys = nil;
 
@@ -121,26 +124,10 @@
 
 // accessors
 
-- (NSString *)uniqueID {
-    return uniqueID;
-}
-
-- (id)name {
-    return name;
-}
-
 - (NSString *)label {
     return nil;
 }
 
-- (NSInteger)count {
-    return count;
-}
-
-- (void)setCount:(NSInteger)newCount {
-       count = newCount;
-}
-
 // "static" accessors
 
 - (NSImage *)icon {
@@ -191,22 +178,6 @@
     return nil;
 }
 
-- (BDSKParentGroup *)parent {
-    return parent;
-}
-
-- (void)setParent:(BDSKParentGroup *)newParent {
-    parent = newParent;
-}
-
-- (BibDocument *)document{
-    return document;
-}
-
-- (void)setDocument:(BibDocument *)newDocument{
-    document = newDocument;
-}
-
 - (BDSKMacroResolver *)macroResolver{
     return [[self document] macroResolver];
 }

Modified: trunk/bibdesk/BDSKParentGroup.h
===================================================================
--- trunk/bibdesk/BDSKParentGroup.h     2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKParentGroup.h     2019-07-15 13:43:32 UTC (rev 24025)
@@ -47,7 +47,7 @@
     NSArray *sortDescriptors;
 }
 
-- (NSString *)identifier;
+@property (nonatomic, readonly) NSString *identifier;
 
 - (NSUInteger)numberOfChildren;
 - (id)childAtIndex:(NSUInteger)anIndex;
@@ -75,12 +75,12 @@
     NSUInteger scriptGroupCount;
 }
 
-- (NSArray *)webGroups;
-- (NSArray *)searchGroups;
-- (NSArray *)sharedGroups;
-- (NSArray *)URLGroups;
-- (NSArray *)scriptGroups;
-- (void)setSharedGroups:(NSArray *)array;
+@property (nonatomic, readonly) NSArray *webGroups;
+@property (nonatomic, readonly) NSArray *searchGroups;
+@property (nonatomic, retain) NSArray *sharedGroups;
+@property (nonatomic, readonly) NSArray *URLGroups;
+@property (nonatomic, readonly) NSArray *scriptGroups;
+
 - (void)addWebGroup:(BDSKWebGroup *)group;
 - (void)removeWebGroup:(BDSKWebGroup *)group;
 - (void)addSearchGroup:(BDSKSearchGroup *)group;
@@ -98,8 +98,9 @@
     BOOL hasLastImportGroup;
 }
 
-- (BDSKLastImportGroup *)lastImportGroup;
-- (NSArray *)smartGroups;
+@property (nonatomic, readonly) BDSKLastImportGroup *lastImportGroup;
+@property (nonatomic, readonly) NSArray *smartGroups;
+
 - (void)setLastImportedPublications:(NSArray *)pubs;
 - (void)addSmartGroup:(BDSKSmartGroup *)group;
 - (void)removeSmartGroup:(BDSKSmartGroup *)group;
@@ -114,11 +115,9 @@
 
 - (id)initWithKey:(NSString *)aKey;
 
-- (NSArray *)categoryGroups;
-- (void)setCategoryGroups:(NSArray *)array;
+@property (nonatomic, retain) NSArray *categoryGroups;
 
-- (NSString *)key;
-- (void)setKey:(NSString *)newKey;
+@property (nonatomic, retain) NSString *key;
 
 @end
 
@@ -126,7 +125,8 @@
 
 @interface BDSKStaticParentGroup : BDSKParentGroup
 
-- (NSArray *)staticGroups;
+@property (nonatomic, readonly) NSArray *staticGroups;
+
 - (void)addStaticGroup:(BDSKStaticGroup *)group;
 - (void)removeStaticGroup:(BDSKStaticGroup *)group;
 

Modified: trunk/bibdesk/BDSKParentGroup.m
===================================================================
--- trunk/bibdesk/BDSKParentGroup.m     2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKParentGroup.m     2019-07-15 13:43:32 UTC (rev 24025)
@@ -54,6 +54,8 @@
 
 @implementation BDSKParentGroup
 
+@dynamic identifier;
+
 - (id)initWithName:(NSString *)aName {
     self = [super initWithName:aName];
     if (self) {
@@ -211,6 +213,8 @@
 
 @implementation BDSKExternalParentGroup
 
+@dynamic webGroups, searchGroups, sharedGroups, URLGroups, scriptGroups;
+
 #define webGroupLocation    0
 #define searchGroupLocation webGroupCount
 #define sharedGroupLocation webGroupCount + searchGroupCount
@@ -332,6 +336,9 @@
 
 @implementation BDSKCategoryParentGroup
 
+@synthesize key;
+@dynamic categoryGroups;
+
 - (id)initWithKey:(NSString *)aKey {
     self = [self initWithName:aKey];
     if (self) {
@@ -364,10 +371,6 @@
     }
 }
 
-- (NSString *)key {
-    return key;
-}
-
 - (void)setKey:(NSString *)newKey {
     if (key != newKey) {
         [key release];
@@ -383,6 +386,8 @@
 
 @implementation BDSKStaticParentGroup
 
+@dynamic staticGroups;
+
 - (id)init {
     return [self initWithName:NSLocalizedString(@"Static", @"source list group 
row title")];
 }
@@ -408,6 +413,8 @@
 
 @implementation BDSKSmartParentGroup
 
+@dynamic lastImportGroup, smartGroups;
+
 - (id)init {
     self = [self initWithName:NSLocalizedString(@"Smart", @"source list group 
row title")];
     if (self) {

Modified: trunk/bibdesk/BDSKScriptGroup.h
===================================================================
--- trunk/bibdesk/BDSKScriptGroup.h     2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKScriptGroup.h     2019-07-15 13:43:32 UTC (rev 24025)
@@ -61,13 +61,8 @@
 - (id)initWithScriptPath:(NSString *)path scriptArguments:(NSString 
*)arguments;
 - (id)initWithName:(NSString *)aName scriptPath:(NSString *)path 
scriptArguments:(NSString *)arguments scriptType:(BDSKScriptType)type;
 
-- (NSString *)scriptPath;
-- (void)setScriptPath:(NSString *)newPath;
+@property (nonatomic, retain) NSString *scriptPath;
+@property (nonatomic, retain) NSString *scriptArguments;
+@property (nonatomic) BDSKScriptType scriptType;
 
-- (NSString *)scriptArguments;
-- (void)setScriptArguments:(NSString *)newArguments;
-
-- (BDSKScriptType)scriptType;
-- (void)setScriptType:(BDSKScriptType)newType;
-
 @end

Modified: trunk/bibdesk/BDSKScriptGroup.m
===================================================================
--- trunk/bibdesk/BDSKScriptGroup.m     2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKScriptGroup.m     2019-07-15 13:43:32 UTC (rev 24025)
@@ -73,6 +73,8 @@
 
 @implementation BDSKScriptGroup
 
+@synthesize scriptPath, scriptArguments, scriptType;
+
 // old designated initializer
 - (id)initWithName:(NSString *)aName;
 {
@@ -189,11 +191,6 @@
 
 - (BOOL)failedDownload { return failedDownload; }
 
-- (NSString *)scriptPath;
-{
-    return scriptPath;
-}
-
 - (void)setScriptPath:(NSString *)newPath;
 {
     if (newPath != scriptPath) {
@@ -205,11 +202,6 @@
     }
 }
 
-- (NSString *)scriptArguments;
-{
-    return scriptArguments;
-}
-
 - (void)setScriptArguments:(NSString *)newArguments;
 {
     if (newArguments != scriptArguments) {
@@ -223,11 +215,6 @@
     }
 }
 
-- (BDSKScriptType)scriptType;
-{
-    return scriptType;
-}
-
 - (void)setScriptType:(BDSKScriptType)newType;
 {
     if (newType != scriptType) {

Modified: trunk/bibdesk/BDSKSearchGroup.h
===================================================================
--- trunk/bibdesk/BDSKSearchGroup.h     2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKSearchGroup.h     2019-07-15 13:43:32 UTC (rev 24025)
@@ -54,18 +54,17 @@
 
 @protocol BDSKSearchGroupServer <NSObject>
 - (id)initWithGroup:(id<BDSKSearchGroup>)aGroup serverInfo:(BDSKServerInfo 
*)info;
-- (NSString *)type;
-- (BDSKServerInfo *)serverInfo;
-- (void)setServerInfo:(BDSKServerInfo *)info;
-- (NSInteger)numberOfAvailableResults;
-- (NSInteger)numberOfFetchedResults;
-- (BOOL)failedDownload;
-- (NSString *)errorMessage;
-- (BOOL)isRetrieving;
+@property (nonatomic, readonly) NSString *type;
+@property (nonatomic, copy) BDSKServerInfo *serverInfo;
+@property (nonatomic, readonly) NSInteger numberOfAvailableResults;
+@property (nonatomic, readonly) NSInteger numberOfFetchedResults;
+@property (nonatomic, readonly) BOOL failedDownload;
+@property (nonatomic, readonly) NSString *errorMessage;
+@property (nonatomic, readonly) BOOL isRetrieving;
+@property (nonatomic, readonly) NSFormatter *searchStringFormatter;
 - (void)retrieveWithSearchTerm:(NSString *)aSearchTerm;
 - (void)reset;
 - (void)terminate;
-- (NSFormatter *)searchStringFormatter;
 @end
 
 @interface BDSKSearchGroup : BDSKExternalGroup <BDSKSearchGroup, 
NSPasteboardItemDataProvider, NSFilePromiseProviderDelegate> {
@@ -77,30 +76,23 @@
 - (id)initWithServerInfo:(BDSKServerInfo *)info searchTerm:(NSString *)string;
 - (id)initWithURL:(NSURL *)bdsksearchURL;
 
-- (NSString *)type;
+@property (nonatomic, readonly) NSString *type;
+@property (nonatomic, copy) BDSKServerInfo *serverInfo;
+@property (nonatomic, copy) NSString *searchTerm;
+@property (nonatomic, copy) NSArray *history;
 
-- (void)setServerInfo:(BDSKServerInfo *)info;
-- (BDSKServerInfo *)serverInfo;
+@property (nonatomic, readonly) NSInteger numberOfAvailableResults;
+@property (nonatomic, readonly) NSString *errorMessage;
+@property (nonatomic, readonly) BOOL hasMoreResults;
 
-- (void)setSearchTerm:(NSString *)aTerm;
-- (NSString *)searchTerm;
-
-- (void)setHistory:(NSArray *)newHistory;
-- (NSArray *)history;
-
-- (NSInteger)numberOfAvailableResults;
-
-- (NSString *)errorMessage;
-
-- (BOOL)hasMoreResults;
-
 - (void)search;
 
 - (void)resetServerWithInfo:(BDSKServerInfo *)info;
-- (NSFormatter *)searchStringFormatter;
 
-- (NSURL *)bdsksearchURL;
+@property (nonatomic, readonly) NSFormatter *searchStringFormatter;
 
+@property (nonatomic, readonly) NSURL *bdsksearchURL;
+
 + (NSDictionary *)dictionaryWithBdsksearchURL:(NSURL *)bdsksearchURL;
 
 + (id<BDSKSearchGroupServer>)copyServerWithGroup:(id<BDSKSearchGroup>)group 
serverInfo:(BDSKServerInfo *)info;

Modified: trunk/bibdesk/BDSKSearchGroup.m
===================================================================
--- trunk/bibdesk/BDSKSearchGroup.m     2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKSearchGroup.m     2019-07-15 13:43:32 UTC (rev 24025)
@@ -64,6 +64,8 @@
 
 @implementation BDSKSearchGroup
 
+@dynamic type, serverInfo, searchTerm, history, numberOfAvailableResults, 
errorMessage, hasMoreResults, searchStringFormatter, bdsksearchURL;
+
 + (void)initialize {
     BDSKINITIALIZE;
     NSString *keys[14] = {@"searchTerm", @"term", @"name", @"database", @"db", 
@"password", @"username", @"user", @"recordSyntax", @"syntax", 
@"resultEncoding", @"encoding", @"removeDiacritics", @"lite"};

Modified: trunk/bibdesk/BDSKSharedGroup.h
===================================================================
--- trunk/bibdesk/BDSKSharedGroup.h     2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKSharedGroup.h     2019-07-15 13:43:32 UTC (rev 24025)
@@ -51,10 +51,10 @@
 + (NSImage *)unlockedIcon;
 
 - (id)initWithClient:(BDSKSharingClient *)aClient;
-- (BDSKSharingClient *)client;
-- (BOOL)isRetrieving;
-- (BOOL)needsUpdate;
 
+@property (nonatomic, readonly) BDSKSharingClient *client;
+@property (nonatomic, readonly) BOOL needsUpdate;
+
 - (void)handleClientUpdatedNotification:(NSNotification *)notification;
 
 @end

Modified: trunk/bibdesk/BDSKSharedGroup.m
===================================================================
--- trunk/bibdesk/BDSKSharedGroup.m     2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKSharedGroup.m     2019-07-15 13:43:32 UTC (rev 24025)
@@ -47,6 +47,9 @@
 
 @implementation BDSKSharedGroup
 
+@synthesize client;
+@dynamic needsUpdate;
+
 #pragma mark Class methods
 
 // Cached icons
@@ -135,8 +138,6 @@
     return [NSString stringWithFormat:@"<%@ %p>: {\n\tneeds update: 
%@\n\tname: %@\n }", [self class], self, ([self needsUpdate] ? @"yes" : @"no"), 
name];
 }
 
-- (BDSKSharingClient *)client { return client; }
-
 - (BOOL)shouldRetrievePublications {
     return [self needsUpdate] || ([super shouldRetrievePublications] && 
[client failedDownload] == NO);
 }

Modified: trunk/bibdesk/BDSKSmartGroup.h
===================================================================
--- trunk/bibdesk/BDSKSmartGroup.h      2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKSmartGroup.h      2019-07-15 13:43:32 UTC (rev 24025)
@@ -42,7 +42,7 @@
 @class BDSKFilter;
 
 @protocol BDSKSmartGroup <BDSKMutableGroup>
-- (BDSKFilter *)filter;
+@property (nonatomic, readonly) BDSKFilter *filter;
 @end
 
 @interface BDSKSmartGroup : BDSKMutableGroup <BDSKSmartGroup> {
@@ -49,43 +49,11 @@
        BDSKFilter *filter;
 }
 
-/*!
-       @method initWithFilter:
-       @abstract Initializes and returns a new smart group instance with a 
filter. 
-       @discussion This is the designated initializer. 
-       @param aFilter The filter for the smart group with. 
-*/
 - (id)initWithFilter:(BDSKFilter *)aFilter;
-
-/*!
-       @method initWithName:filter:
-       @abstract Initializes and returns a new group instance with a name, 
count and filter. 
-       @discussion This is the designated initializer. 
-       @param aName The name for the smart group.
-       @param aFilter The filter for the smart group with. 
-*/
 - (id)initWithName:(id)aName filter:(BDSKFilter *)aFilter;
 
-/*!
-       @method filter
-       @abstract Returns the filter of the group.
-       @discussion -
-*/
-- (BDSKFilter *)filter;
+@property (nonatomic, retain) BDSKFilter *filter;
 
-/*!
-       @method setFilter:
-       @abstract Sets the newFilter for the group.
-       @discussion -
-       @param newFilter The new filter to set.
-*/
-- (void)setFilter:(BDSKFilter *)newFilter;
-
-/*!
-       @method invalidateCount
-       @abstract Invalidates the count by setting it to -1.
-       @discussion -
- */
 - (void)invalidateCount;
 
 @end

Modified: trunk/bibdesk/BDSKSmartGroup.m
===================================================================
--- trunk/bibdesk/BDSKSmartGroup.m      2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKSmartGroup.m      2019-07-15 13:43:32 UTC (rev 24025)
@@ -44,6 +44,8 @@
 
 @implementation BDSKSmartGroup
 
+@dynamic filter;
+
 // super's designated initializer
 - (id)initWithName:(id)aName {
     BDSKFilter *aFilter = [[BDSKFilter alloc] init];

Modified: trunk/bibdesk/BDSKStaticGroup.h
===================================================================
--- trunk/bibdesk/BDSKStaticGroup.h     2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKStaticGroup.h     2019-07-15 13:43:32 UTC (rev 24025)
@@ -46,60 +46,13 @@
     NSArray *tmpKeys;
 }
 
-/*!
-       @method initWithName:publications:
-       @abstract Initializes and returns a new group instance with a name and 
publications.
-       @discussion This is the designated initializer. 
-       @param aName The name for the static group.
-       @param array The publications for the static group.
-*/
 - (id)initWithName:(id)aName publications:(NSArray *)array;
 
-/*!
-       @method publications
-       @abstract Returns the publications in the group.
-       @discussion -
-*/
-- (NSArray *)publications;
+@property (nonatomic, copy) NSArray *publications;
 
-/*!
-       @method setPublications:
-       @abstract Sets the publications of the group.
-       @discussion -
-       @param newPublications The publications to set.
-*/
-- (void)setPublications:(NSArray *)newPublications;
-
-/*!
-       @method addPublication:
-       @abstract Adds a publication to the group.
-       @discussion -
-       @param item The publication to add.
-*/
 - (void)addPublication:(BibItem *)item;
-
-/*!
-       @method addPublicationsFromArray:
-       @abstract Adds publications from the group.
-       @discussion -
-       @param items The publications to add.
-*/
 - (void)addPublicationsFromArray:(NSArray *)items;
-
-/*!
-       @method removePublication:
-       @abstract Removes a publication from the group.
-       @discussion -
-       @param item The publication to remove.
-*/
 - (void)removePublication:(BibItem *)item;
-
-/*!
-       @method removePublicationsInArray:
-       @abstract Removes publications from the group.
-       @discussion -
-       @param items The publications to remove.
-*/
 - (void)removePublicationsInArray:(NSArray *)items;
 
 @end

Modified: trunk/bibdesk/BDSKStaticGroup.m
===================================================================
--- trunk/bibdesk/BDSKStaticGroup.m     2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKStaticGroup.m     2019-07-15 13:43:32 UTC (rev 24025)
@@ -47,6 +47,8 @@
 
 @implementation BDSKStaticGroup
 
+@synthesize publications;
+
 // designated initializer
 - (id)initWithName:(id)aName publications:(NSArray *)array {
     self = [super initWithName:aName];
@@ -127,10 +129,6 @@
 
 - (BOOL)allowsRemoval { return YES; }
 
-- (NSArray *)publications {
-    return publications;
-}
-
 - (void)setPublications:(NSArray *)newPublications {
     if (newPublications != publications) {
                [[[self undoManager] prepareWithInvocationTarget:self] 
setPublications:publications];

Modified: trunk/bibdesk/BDSKURLGroup.h
===================================================================
--- trunk/bibdesk/BDSKURLGroup.h        2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKURLGroup.h        2019-07-15 13:43:32 UTC (rev 24025)
@@ -53,7 +53,6 @@
 - (id)initWithName:(NSString *)aName URL:(NSURL *)aURL;
 - (id)initWithURL:(NSURL *)aURL;
 
-- (NSURL *)URL;
-- (void)setURL:(NSURL *)newURL;
+@property (nonatomic, retain) NSURL *URL;
 
 @end

Modified: trunk/bibdesk/BDSKURLGroup.m
===================================================================
--- trunk/bibdesk/BDSKURLGroup.m        2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKURLGroup.m        2019-07-15 13:43:32 UTC (rev 24025)
@@ -53,6 +53,8 @@
 
 @implementation BDSKURLGroup
 
+@synthesize URL;
+
 // old designated initializer
 - (id)initWithName:(NSString *)aName;
 {
@@ -269,11 +271,6 @@
 
 - (BOOL)failedDownload { return failedDownload; }
 
-- (NSURL *)URL;
-{
-    return URL;
-}
-
 - (void)setURL:(NSURL *)newURL;
 {
     if (URL != newURL) {

Modified: trunk/bibdesk/BDSKWebGroup.h
===================================================================
--- trunk/bibdesk/BDSKWebGroup.h        2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKWebGroup.h        2019-07-15 13:43:32 UTC (rev 24025)
@@ -48,14 +48,12 @@
     NSMapTable *frameInfo;
 }
 
-- (NSString *)label;
-- (void)setLabel:(NSString *)newLabel;
+@property (nonatomic, retain) NSString *label;
 
-- (NSURL *)URL;
-- (void)setURL:(NSURL *)newURL;
+@property (nonatomic, retain) NSURL *URL;
 
-- (BDSKWebView *)webView;
+@property (nonatomic, readonly) BDSKWebView *webView;
 
-- (BOOL)isWebViewLoaded;
+@property (nonatomic, readonly, getter=isWebViewLoaded) BOOL webViewLoaded;
 
 @end

Modified: trunk/bibdesk/BDSKWebGroup.m
===================================================================
--- trunk/bibdesk/BDSKWebGroup.m        2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKWebGroup.m        2019-07-15 13:43:32 UTC (rev 24025)
@@ -68,6 +68,8 @@
 
 @implementation BDSKWebGroup
 
+@dynamic label, URL, webView, webViewLoaded;
+
 static NSString *BDSKWebLocalizedString = nil;
 
 + (void)initialize {

Modified: trunk/bibdesk/BDSKZoomGroupServer.h
===================================================================
--- trunk/bibdesk/BDSKZoomGroupServer.h 2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKZoomGroupServer.h 2019-07-15 13:43:32 UTC (rev 24025)
@@ -65,5 +65,5 @@
 + (NSArray *)supportedRecordSyntaxes;
 + (ZOOMSyntaxType)zoomRecordSyntaxForRecordSyntaxString:(NSString *)syntax;
 - (void)resetConnection;
-- (void)setErrorMessage:(NSString *)newErrorMessage;
+@property (nonatomic, retain) NSString *errorMessage;
 @end

Modified: trunk/bibdesk/BDSKZoomGroupServer.m
===================================================================
--- trunk/bibdesk/BDSKZoomGroupServer.m 2019-07-15 06:31:17 UTC (rev 24024)
+++ trunk/bibdesk/BDSKZoomGroupServer.m 2019-07-15 13:43:32 UTC (rev 24025)
@@ -66,6 +66,8 @@
 
 @implementation BDSKZoomGroupServer
 
+@dynamic errorMessage;
+
 + (void)initialize
 {
     BDSKINITIALIZE;

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.



_______________________________________________
Bibdesk-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bibdesk-commit

Reply via email to