ProjectManager
0.2
|
This class is the principal document class for project files. More...
Public Member Functions | |
(NSArray *) | - projectMenuEntries |
This message is sent to the receiver by the app delegate when the receiver becomes the currently active document in the app to determine what menu entries of it to put into the main menu's 'Project' submenu. | |
(NSString *) | - projectName |
(void) | - setProjectName: |
Sets a new project name. | |
(NSString *) | - projectDirectory |
(void) | - setProjectName: |
(NSString *) | - projectTypeID |
(id< ProjectType >) | - projectType |
(NSArray *) | - projectModules |
(id< ProjectModule >) | - projectModuleWithName: |
Returns the project module of the specified name, or `nil' if no such module is found. | |
(void) | - setCurrentProjectModule: |
Sets the currently displayed project module in the receiver's project window. | |
(id< ProjectModule >) | - currentProjectModule |
Returns the currently displayed project module. | |
(BOOL) | - openFile:inCodeEditorOnLine: |
Opens a specified file in a code editor (either the internal code editor, or an external one, if configured to do so). | |
(void) | - logMessage: |
Appends a message to the project log. | |
Static Public Member Functions | |
(BOOL) | + validateProjectName:error: |
Checks whether a given string is a valid project name. | |
Protected Attributes | |
NSString * | projectDirectory |
Returns a path to where the project's directory is located. | |
NSString * | projectName |
Returns the abstract project name. | |
NSString * | projectTypeID |
Returns the type ID of the project's project type. | |
id< ProjectType > | projectType |
Returns the project type object associated currently with the project. | |
NSArray * | projectModules |
Returns the project modules of the receiver. | |
NSArray * | moduleMenuEntries |
An array of menu items of project modules which are to appear in the Modules menu. | |
ProjectWindowController * | wc |
This class is the principal document class for project files.
It's responsibility is to manage it's project modules, the project type object, and it's window controller.
- (void) logMessage: | (NSString *) | aMessage |
Appends a message to the project log.
This method serves as a frontend to the -[ProjectWindowController logMessage:] method, so that project modules and project types can log messages (since they don't have direct access to the window controller object).
aMessage | The message which to send to the log. |
References ProjectWindowController::logMessage:.
Referenced by MakeBuilder::buildTarget:, MakeBuilder::cleanTarget:, GNUstepAppLauncher::launch:, GNUstepAppLauncher::stopLaunch:, and GNUstepAppLauncher::taskTerminated.
- (BOOL) openFile: | (NSString *) | aPath | |
inCodeEditorOnLine: | (int) | aLine | |
Opens a specified file in a code editor (either the internal code editor, or an external one, if configured to do so).
aPath | The file which to open. |
aLine | The line number at which to open the file. If the file is already open, it is scrolled to that line. If you pass aLine < 0, no scrolling occurs and the file is only opened. |
Referenced by FileManager::openPath:.
- (NSArray *) projectMenuEntries |
This message is sent to the receiver by the app delegate when the receiver becomes the currently active document in the app to determine what menu entries of it to put into the main menu's 'Project' submenu.
References moduleMenuEntries, and projectModules.
- (void) setCurrentProjectModule: | (id <ProjectModule>) | aModule |
Sets the currently displayed project module in the receiver's project window.
aModule | The project module which to display. It must one of the project's modules. |
References ProjectWindowController::setCurrentModule:.
Referenced by ProjectAttributes::switchView:.
- (void) setProjectName: | (NSString *) | aName |
Sets a new project name.
The project's name doesn't necessarily need to be the same as the project file's or project directory's name, but can instead by anything that the user finds descriptive.
References projectName.
Referenced by FileManager::changeName:, and ProjectAttributes::changeProjectName:.
+ (BOOL) validateProjectName: | (NSString *) | aProjectName | |
error: | (NSError **) | error | |
Checks whether a given string is a valid project name.
projectName | The project name which to check. |
error | A pointer which if not set to NULL will be filled with an object describing the problem with the name. |
- (NSString *) projectDirectory [protected] |
Returns a path to where the project's directory is located.
The location of the project's project file can be determined by simply saying -[ProjectDocument fileName].
Referenced by MakeBuilder::buildTarget:, and MakeBuilder::cleanTarget:.
- (NSString *) projectName [protected] |
Returns the abstract project name.
Referenced by ProjectWindowController::projectNameChanged:, and setProjectName:.