ProjectManager  0.2
Public Member Functions | Static Public Member Functions | Protected Attributes
ProjectCreator Class Reference

List of all members.

Public Member Functions

(NSDictionary *) - getNewProjectSetupWithLocation:
 Runs a series of panels to ask the user to define a new project.
(void) - cancel:
(void) - goToProjectLocationSelection:
(void) - projectTypeSelected:
(void) - doubleClickedProjectType:
 Action invoked when the user double-clicks the projectType outline.
(void) - validateProjectName:
(NSView *) - wizardPanel:viewForStage:
(NSView *) - wizardPanel:initialFirstResponderForStage:
(int) - outlineView:numberOfChildrenOfItem:
(BOOL) - outlineView:isItemExpandable:
(id) - outlineView:child:ofItem:
(id) - outlineView:objectValueForTableColumn:byItem:

Static Public Member Functions

(id) + shared
(BOOL) + createNewProjectAtPath:projectName:fromTemplate:error:
 Creates a new project.

Protected Attributes

WKWizardPanel * wizard
id projectNameCell
id projectNameForm
id projectNameNotice
id projectNameMistake
id projectNameView
id projectTypes
id projectTypeView
id projectTypeIcon
id projectTypeDescription
id window1
id window2
id templateNeededNotice
id finishButton
id backToLocationButton
id toProjectTypeSelectionButton
NSArrayprojectTypesCache
NSStringlocation
NSStringprojectName

Member Function Documentation

+ (BOOL) createNewProjectAtPath: (NSString *)  aProjectPath
projectName: (NSString *)  aProjectName
fromTemplate: (NSString *)  aTemplatePath
error: (NSError **)  error 

Creates a new project.

Parameters:
projectPathThe path where to create the project.
projectNameThe name of the new project.
templatePathA path to the template which will be used to create the new project's files.
errorA pointer which if not set to NULL will be filled with an error object describing the problem in case creating the project fails.

After the template has been copied, the project directory is searched for files named "$PROJECT_NAME$".<ext> and these are then renamed to the proper project name. Simmilar variable substitution occurs inside the ProjectInfo.plist.

Returns:
YES if creating the new project bundle succeeded, NO if it didn't.
- (void) doubleClickedProjectType: (id)  sender

Action invoked when the user double-clicks the projectType outline.

Since each double-click also invokes a single-click before (which means that the user's choice has been validated in -[ProjectCreator projectTypeSelected:], we only check whether the button is enabled (meaning that the selection is valid) and aftewards make the button perform a click.

- (NSDictionary *) getNewProjectSetupWithLocation: (BOOL)  withLocation

Runs a series of panels to ask the user to define a new project.

Parameters:
withLocationIf this argument is NO, then the user isn't asked about the location of the project (and the key `ProjectPath' will be absent in the return value), and the calling code is assumed to know where the project is supposed to reside.
Returns:
A dictionary with these key-value pairs: { ProjectName = projectName; ProjectPath = projectPath; ProjectType = projectTypeID; ProjectTemplate = templateLocation; }

References ProjectTemplateDescription::name, ProjectTypeDescription::name, ProjectTemplateDescription::parent, and ProjectTypeDescription::projectType.


The documentation for this class was generated from the following files: