void createProject(final IProjectDescription description,final IProject proj,final IProgressMonitor monitor) throws CoreException, OperationCanceledException {
  try {
    monitor.beginTask("",2000);
    proj.create(description,new SubProgressMonitor(monitor,1000));
    if (monitor.isCanceled()) {
      throw new OperationCanceledException();
    }
    proj.open(new SubProgressMonitor(monitor,1000));
    WorkspaceModelsManager.setValuesProjectDescription(proj,false,false,null);
    final IContainer container=proj;
    final IFolder libFolder=container.getFolder(new Path("doc"));
    libFolder.create(true,true,monitor);
    final IFolder snapshotsFolder=libFolder.getFolder(new Path("snapshots"));
    snapshotsFolder.create(true,true,monitor);
    final IFolder modelFolder=container.getFolder(new Path("models"));
    modelFolder.create(true,true,monitor);
    final IFolder incFolder=container.getFolder(new Path("includes"));
    incFolder.create(true,true,monitor);
    final IFolder imFolder=container.getFolder(new Path("images"));
    imFolder.create(true,true,monitor);
  }
 catch (  final CoreException ioe) {
    final IStatus status=new Status(IStatus.ERROR,"ProjectWizard",IStatus.OK,ioe.getLocalizedMessage(),null);
    throw new CoreException(status);
  }
 finally {
    monitor.done();
  }
}

void createProject ( final IProjectDescription description , final IProject proj , final IProgressMonitor monitor ) throws CoreException , OperationCanceledException { try { monitor . beginTask ( "" , 2000 ) ; proj . create ( description , new SubProgressMonitor ( monitor , 1000 ) ) ; if ( monitor . isCanceled ( ) ) { throw new OperationCanceledException ( ) ; } proj . open ( new SubProgressMonitor ( monitor , 1000 ) ) ; WorkspaceModelsManager . setValuesProjectDescription ( proj , false , false , null ) ; final IContainer container = proj ; final IFolder libFolder = container . getFolder ( new Path ( "doc" ) ) ; libFolder . create ( true , true , monitor ) ; final IFolder snapshotsFolder = libFolder . getFolder ( new Path ( "snapshots" ) ) ; snapshotsFolder . create ( true , true , monitor ) ; final IFolder modelFolder = container . getFolder ( new Path ( "models" ) ) ; modelFolder . create ( true , true , monitor ) ; final IFolder incFolder = container . getFolder ( new Path ( "includes" ) ) ; incFolder . create ( true , true , monitor ) ; final IFolder imFolder = container . getFolder ( new Path ( "images" ) ) ; imFolder . create ( true , true , monitor ) ; } catch ( final CoreException ioe ) { final IStatus status = new Status ( IStatus . ERROR , "ProjectWizard" , IStatus . OK , ioe . getLocalizedMessage ( ) , null ) ; throw new CoreException ( status ) ; } finally { monitor . done ( ) ; } }
this creates the project in the workspace .
