KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > hibernate > eclipse > builder > HibernateBuilder


1 /**
2  * $Id$
3  *
4  * Public Domain code
5  */

6 package org.hibernate.eclipse.builder;
7
8 import java.io.File JavaDoc;
9 import java.util.Map JavaDoc;
10
11 import org.eclipse.core.resources.IProject;
12 import org.eclipse.core.resources.IncrementalProjectBuilder;
13 import org.eclipse.core.runtime.CoreException;
14 import org.eclipse.core.runtime.IProgressMonitor;
15 import org.hibernate.eclipse.console.HibernateConsolePlugin;
16
17 /**
18  * @author juozas
19  *
20  */

21 public class HibernateBuilder extends IncrementalProjectBuilder {
22
23     public static final String JavaDoc BUILDER_ID = HibernateConsolePlugin.ID + ".hibernateBuilder";
24     
25     protected IProject[] build(int kind, Map JavaDoc args, final IProgressMonitor monitor)
26             throws CoreException {
27         
28         
29      /* IJavaProject jproject = JavaCore.create(getProject());
30         IPath location = jproject.getOutputLocation();
31         IResource res = ResourcesPlugin.getWorkspace().getRoot().findMember(location);
32         if(res != null){
33             res.accept( new IResourceVisitor(){
34                 
35                 public boolean visit(IResource resource) throws CoreException {
36                     
37                     if( resource instanceof IFile ){
38                         IFile file = (IFile)resource;
39                         process(file.getLocation().toFile());
40                         file.refreshLocal(IResource.DEPTH_ZERO, monitor);
41                     }
42                     return true;
43                 }
44                 
45                 
46             });
47         }*/

48         
49         return null;
50     }
51
52    private void process(final File JavaDoc file){
53 /*
54         InstrumentTask task = new InstrumentTask(){
55             
56              protected Collection getFiles() {
57                return Collections.singleton(file);
58             
59              }
60            };
61          
62            task.execute();
63            */

64     }
65     
66 }
67
68 /**
69 * $Log$
70 * Revision 1.2 2005/05/30 20:28:46 maxcsaucdk
71 * enablement of HibernateNature
72 *
73 * Revision 1.1 2005/05/24 20:21:36 maxcsaucdk
74 * commit for jbosside integration build
75 *
76 */

77
Popular Tags