createProject method
Creates a project of the specified type with the given name.
The type parameter specifies the type of project to create.
The name parameter specifies the name of the project.
If the type is 'empty', an EmptyTemplate project is created.
If the type is 'template', a ExampleProject is created.
If the type is neither 'empty' nor 'template', an error message is printed.
Implementation
void createProject(String type, String name) {
ProjectType project;
switch (type) {
case 'empty':
project = EmptyTemplate();
break;
case 'example':
project = ExampleProject();
break;
default:
print('Error: Unknown project type "$type".');
return;
}
project.create(name);
}