ProjectManager
0.2
|
00001 /* 00002 ProjectType.h 00003 00004 Protocol declaration of the ProjectType protocol for the 00005 ProjectManager application. 00006 00007 Copyright (C) 2005, 2006 Saso Kiselkov 00008 00009 This program is free software; you can redistribute it and/or modify 00010 it under the terms of the GNU General Public License as published by 00011 the Free Software Foundation; either version 2 of the License, or 00012 (at your option) any later version. 00013 00014 This program is distributed in the hope that it will be useful, 00015 but WITHOUT ANY WARRANTY; without even the implied warranty of 00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00017 GNU General Public License for more details. 00018 00019 You should have received a copy of the GNU General Public License 00020 along with this program; if not, write to the Free Software 00021 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 00022 */ 00023 00024 #import <Foundation/NSObject.h> 00025 #import <Foundation/NSString.h> 00026 #import <Foundation/NSDictionary.h> 00027 00028 @class NSArray, NSDictionary, NSImage; 00029 00030 @class ProjectDocument; 00031 00040 @protocol ProjectType <NSObject> 00041 00042 // ======== Class Methods ========= 00043 00045 + (NSString *) projectTypeID; 00046 00051 + (NSString *) humanReadableProjectTypeName; 00052 00054 + (NSString *) projectTypeDescription; 00055 00057 + (NSImage *) projectTypeIcon; 00058 00063 + (NSArray *) projectModules; 00064 00070 + (NSDictionary *) projectTemplateDescriptions; 00071 00076 + (NSString *) pathToProjectTemplate: (NSString *) templateName; 00077 00078 00079 // ========= Instance Methods ========== 00080 00095 - initWithDocument: (ProjectDocument *) aProject 00096 infoDictionary: (NSDictionary *) infoDict 00097 projectModules: (NSArray *) modules; 00098 00105 - (NSDictionary *) infoDictionary; 00106 00116 - (BOOL) regenerateDerivedFiles; 00117 00125 - (NSString *) pathToSubprojectsDirectory; 00126 00127 @end 00128 00145 static inline NSDictionary * 00146 PMCreateTemplateDescription(NSString * templateDescription, 00147 NSImage * templateIcon) 00148 { 00149 return // templateIcon can be `nil' here![NSDictionary dictionaryWithObjectsAndKeys: 00150 templateDescription, @"Description", 00151 00152 templateIcon, @"Icon", 00153 nil]; 00154 }