Skip to main content
summaryrefslogtreecommitdiffstats
blob: a471b67f5c6d59a1ce01cf0d1f3f6e88b6637a87 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
/*****************************************************************************
 * Copyright (c) 2011 CEA LIST.
 *
 *
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *  Vincent Lorenzo (CEA LIST) vincent.lorenzo@cea.fr - Initial API and implementation
 *  Camille Letavernier (CEA LIST) camille.letavernier@cea.fr
 *
 *****************************************************************************/
package org.eclipse.papyrus.eclipse.project.editors.interfaces;



/**
 *
 * Editor for the Manifest
 *
 */
public interface IManifestEditor extends IProjectEditor, IFileEditor {

	/** the path for the manifest file */
	public static final String MANIFEST_PATH = "META-INF/MANIFEST.MF"; //$NON-NLS-1$

	/** the path for the META-INF folder */
	public static final String META_INF_PATH = "META-INF/"; //$NON-NLS-1$

	/** the key for the bundle symbolic name */
	public static final String BUNDLE_SYMBOLIC_NAME = "Bundle-SymbolicName"; //$NON-NLS-1$

	/** the key for the bundle name */
	public static final String BUNDLE_NAME = "Bundle-Name";//$NON-NLS-1$

	/** the key for the required bundle */
	public static final String REQUIRED_BUNDLE = "Require-Bundle"; //$NON-NLS-1$

	/** the key for the bundle version */
	public static final String BUNDLE_VERSION = "bundle-version"; //$NON-NLS-1$

	/** the key for the bundle vendor */
	public static final String BUNDLE_VENDOR = "Bundle-Vendor"; //$NON-NLS-1$

	/** the build command for the manifest */
	public static final String MANIFEST_BUILD_COMMAND = "org.eclipse.pde.ManifestBuilder"; //$NON-NLS-1$

	/** the key for the bundle localization */
	public static final String BUNDLE_LOCALIZATION = "Bundle-Localization"; //$NON-NLS-1$
	
	/**
	 * Add a dependency to the MANIFEST
	 * @param dependency
	 *            the dependency to add
	 */
	public void addDependency(final String dependency);

	/**
	 * Add a specific version of a dependency to the MANIFEST
	 *
	 * @param dependency
	 *            the dependency to add
	 * @param version
	 *            the version of the dependency
	 */
	public void addDependency(final String dependency, final String version);

	/**
	 * Check whether a dependency is already present in the MANIFEST
	 *
	 * @param dependency
	 *            the dependency to check
	 */
	public boolean hasDependency(final String dependency);

	/**
	 *
	 * @param key
	 *            the key
	 * @param value
	 *            the new value for the key
	 */
	public void setValue(final String key, final String value);

	public String getValue(final String key);

	/**
	 *
	 * @param key
	 *            the key
	 * @param name
	 *            the name
	 * @param value
	 *            the new value for the key
	 */
	public void setValue(final String key, final String name, final String value);

	/**
	 *
	 * @param key
	 *            the key
	 * @param value
	 *            the value to remove for this key
	 */
	public void removeValue(final String key, final String value);

	/**
	 *
	 * @param key
	 *            a key to remove from the manifest
	 *
	 */
	public void removeValue(final String key);

	/**
	 *
	 * @param name
	 *            the symbolic name for the bundle
	 */
	public void setSymbolicBundleName(final String name);


	/**
	 *
	 * @return
	 *         the bundle name for the project
	 */
	public String getSymbolicBundleName();

	/**
	 *
	 * @return
	 *         the symbolic bundle name for the project
	 */
	public String getBundleName();

	/**
	 *
	 * @param name
	 *            the bundle name for the bundle
	 */
	public void setBundleName(final String name);

	/**
	 *
	 * @return
	 *         the version of the bundle
	 */
	public String getBundleVersion();

	/**
	 * Set the version of the bundle
	 */
	public void setBundleVersion(final String version);

	/**
	 * Gets this plug-in's provider
	 *
	 * @return
	 *         this plug-in's provider
	 */
	public String getBundleVendor();

	/**
	 * Sets this plug-in's provider
	 *
	 * @param vendor
	 *            this plug-in's provider
	 */
	public void setBundleVendor(final String vendor);

	/**
	 * Get the bundle localization
	 *
	 * @return
	 *         the bundle localization
	 */
	public String getBundleLocalization();

	/**
	 * Sets the Manifest's singleton directive
	 *
	 * @param singleton
	 *            Whether this plug-in should be a singleton
	 */
	public void setSingleton(boolean singleton);

	/**
	 *
	 * @param dependencyPattern
	 *            the pattern for the dependency to update
	 * @param newVersion
	 *            the version for the dependency
	 */
	public void setDependenciesVersion(final String dependencyPattern, final String newVersion);
}

Back to the top