code: private IProject getProjectFromPath(IPath path) {
  		IWorkspace workspace = ResourcesPlugin.getWorkspace();
  		IProject project = null;
  
  		if (path != null) {
  			if (workspace.validatePath(path.toString(), IResource.PROJECT).isOK()) {
  				project = workspace.getRoot().getProject(path.toString());
  			} else {
  				project = workspace.getRoot().getFile(path).getProject();
  			}
  		}
  
  		return project;
  	}
docs: Returns the project that contains the specified path
  
  @param path
  the path which project is needed
  @return IProject object. If path is <code>null</code> the return value is
  also <code>null</code>.