KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > ant > internal > ui > antsupport > EclipseDefaultExecutor


1 /*******************************************************************************
2  * Copyright (c) 2005 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11 package org.eclipse.ant.internal.ui.antsupport;
12
13 import java.util.Arrays JavaDoc;
14 import java.util.Vector JavaDoc;
15
16 import org.apache.tools.ant.BuildException;
17 import org.apache.tools.ant.Executor;
18 import org.apache.tools.ant.Project;
19 import org.apache.tools.ant.helper.DefaultExecutor;
20
21 public class EclipseDefaultExecutor extends DefaultExecutor {
22
23     private static final EclipseSingleCheckExecutor SUB_EXECUTOR = new EclipseSingleCheckExecutor();
24     
25     /* (non-Javadoc)
26      * @see org.apache.tools.ant.Executor#executeTargets(org.apache.tools.ant.Project, java.lang.String[])
27      */

28     public void executeTargets(Project project, String JavaDoc[] targetNames) throws BuildException {
29         Vector JavaDoc v= new Vector JavaDoc();
30         v.addAll(Arrays.asList(targetNames));
31         project.addReference("eclipse.ant.targetVector", v); //$NON-NLS-1$
32
super.executeTargets(project, targetNames);
33     }
34     
35     /* (non-Javadoc)
36      * @see org.apache.tools.ant.Executor#getSubProjectExecutor()
37      */

38     public Executor getSubProjectExecutor() {
39        return SUB_EXECUTOR;
40     }
41 }
42
Popular Tags