]>
Commit | Line | Data |
---|---|---|
1b2798f6 EK |
1 | /******************************************************************************* |
2 | * Copyright (c) 2008 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.jdt.ui.jarpackager; | |
12 | ||
13 | import java.io.File; | |
14 | ||
15 | import org.eclipse.core.runtime.CoreException; | |
16 | import org.eclipse.core.runtime.IPath; | |
17 | ||
18 | ||
19 | /** | |
20 | * Extends {@link org.eclipse.jdt.ui.jarpackager.IJarBuilder} with the following functions: | |
21 | * <ul> | |
22 | * <li>Write a file to the JAR to build</li> | |
23 | * </ul> | |
24 | * | |
25 | * @since 3.5 | |
26 | */ | |
27 | public interface IJarBuilderExtension { | |
28 | ||
29 | /** | |
30 | * Add the given file to the archive at the given path | |
31 | * | |
32 | * @param file | |
33 | * the file to be written. It is guaranteed, that the file is not a directory. | |
34 | * @param destinationPath | |
35 | * the path for the file inside the archive | |
36 | * @throws CoreException | |
37 | * thrown when the file could not be written | |
38 | */ | |
39 | public void writeFile(File file, IPath destinationPath) throws CoreException; | |
40 | ||
41 | } |