Package org.eclipse.tycho.model.manifest
Class MutableBundleManifest
java.lang.Object
org.eclipse.tycho.model.manifest.MutableBundleManifest
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidadd(ManifestAttribute attribute) Get a map containing the name of packages in Export-Package manifest attribute as a map.Get a map containing the name of packages in Import-Package manifest attribute as a map.Read the RequiredBundle with optional versionsbooleanstatic MutableBundleManifeststatic MutableBundleManifestread(InputStream is) static StringreadLineWithLineEnding(PushbackReader reader, Consumer<String> lineEndingConsumer) voidsetFragmentHostVersion(String newVersion) voidsetVersion(String version) voidupdateExportedPackageVersions(Map<String, String> versionsToUpdate) Updates version for packages in Export-Package with the version provided in the map.voidupdateImportedPackageVersions(Map<String, String> versionsToUpdate) Updates version range for packages in Import-Package with the version provided in the map.voidupdateRequiredBundleVersions(Map<String, String> versionsToUpdate) Updates version range for bundles in Require-Bundle with the versions provided in the map.static voidwrite(MutableBundleManifest mf, File file) static voidwrite(MutableBundleManifest mf, OutputStream os)
-
Constructor Details
-
MutableBundleManifest
public MutableBundleManifest()
-
-
Method Details
-
add
-
read
- Throws:
IOException
-
read
- Throws:
IOException
-
readLineWithLineEnding
public static String readLineWithLineEnding(PushbackReader reader, Consumer<String> lineEndingConsumer) throws IOException - Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
getSymbolicName
-
getVersion
-
getFragmentHostSymbolicName
-
isFragment
public boolean isFragment() -
getFragmentHostVersion
-
setFragmentHostVersion
-
getRequiredBundleVersions
Read the RequiredBundle with optional versions- Returns:
-
updateRequiredBundleVersions
Updates version range for bundles in Require-Bundle with the versions provided in the map.- Parameters:
versionsToUpdate- the bundle/version-range map. Keys are the bundle symbolicnames to update and the values are the new version range to apply.
-
getImportPackagesVersions
Get a map containing the name of packages in Import-Package manifest attribute as a map.The map keys are the package names and the values are the version range if present or null when absent.
- Returns:
-
updateImportedPackageVersions
Updates version range for packages in Import-Package with the version provided in the map.- Parameters:
versionsToUpdate- the package/version-range map. Keys are the package names to update and the values are the new version range to apply.
-
getExportedPackagesVersion
Get a map containing the name of packages in Export-Package manifest attribute as a map.- Returns:
- the package/version map. Keys are the package names and the values are the version if present or null when absent.
-
updateExportedPackageVersions
Updates version for packages in Export-Package with the version provided in the map.- Parameters:
versionsToUpdate- the package/version map. Keys are the package names to update and the values are the newVersion to apply.
-
setVersion
-