aQute.bnd.osgi.Jar.ensureManifest()方法的使用及代码示例

x33g5p2x  于2022-01-22 转载在 其他  
字(5.9k)|赞(0)|评价(0)|浏览(191)

本文整理了Java中aQute.bnd.osgi.Jar.ensureManifest()方法的一些代码示例,展示了Jar.ensureManifest()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Jar.ensureManifest()方法的具体详情如下:
包路径:aQute.bnd.osgi.Jar
类名称:Jar
方法名:ensureManifest

Jar.ensureManifest介绍

[英]Make sure we have a manifest
[中]确保我们有舱单

代码示例

代码示例来源:origin: biz.aQute.bnd/biz.aQute.bnd

  1. private Jar getSources(Tool tool, Processor context, String path) throws Exception {
  2. Jar jar = toJar(context, path);
  3. if (jar == null) {
  4. jar = tool.doSource();
  5. }
  6. jar.ensureManifest();
  7. jar.setName("sources"); // set jar name to classifier
  8. tool.addClose(jar);
  9. return jar;
  10. }

代码示例来源:origin: biz.aQute.bnd/biz.aQute.bnd

  1. private Jar getJavadoc(Tool tool, Processor context, String path, Map<String, String> options, boolean exports)
  2. throws Exception {
  3. Jar jar = toJar(context, path);
  4. if (jar == null) {
  5. jar = tool.doJavadoc(options, exports);
  6. }
  7. jar.ensureManifest();
  8. jar.setName("javadoc"); // set jar name to classifier
  9. tool.addClose(jar);
  10. return jar;
  11. }

代码示例来源:origin: biz.aQute.bnd/biz.aQute.repository

  1. private Jar getSources(Tool tool, Processor context, String path) throws Exception {
  2. Jar jar = toJar(context, path);
  3. if (jar == null) {
  4. jar = tool.doSource();
  5. }
  6. jar.ensureManifest();
  7. jar.setName("sources"); // set jar name to classifier
  8. tool.addClose(jar);
  9. return jar;
  10. }

代码示例来源:origin: biz.aQute.bnd/biz.aQute.repository

  1. private Jar getJavadoc(Tool tool, Processor context, String path, Map<String, String> options, boolean exports)
  2. throws Exception {
  3. Jar jar = toJar(context, path);
  4. if (jar == null) {
  5. jar = tool.doJavadoc(options, exports);
  6. }
  7. jar.ensureManifest();
  8. jar.setName("javadoc"); // set jar name to classifier
  9. tool.addClose(jar);
  10. return jar;
  11. }

代码示例来源:origin: biz.aQute/bndlib

  1. private void copyInfo(Jar source, Jar dest, String type) throws Exception {
  2. source.ensureManifest();
  3. dest.ensureManifest();
  4. copyInfoResource(source, dest, "LICENSE");
  5. copyInfoResource(source, dest, "LICENSE.html");
  6. copyInfoResource(source, dest, "about.html");
  7. Manifest sm = source.getManifest();
  8. Manifest dm = dest.getManifest();
  9. copyInfoHeader(sm, dm, "Bundle-Description", "");
  10. copyInfoHeader(sm, dm, "Bundle-Vendor", "");
  11. copyInfoHeader(sm, dm, "Bundle-Copyright", "");
  12. copyInfoHeader(sm, dm, "Bundle-DocURL", "");
  13. copyInfoHeader(sm, dm, "Bundle-License", "");
  14. copyInfoHeader(sm, dm, "Bundle-Name", " " + type);
  15. copyInfoHeader(sm, dm, "Bundle-SymbolicName", "." + type);
  16. copyInfoHeader(sm, dm, "Bundle-Version", "");
  17. }

代码示例来源:origin: biz.aQute.bnd/biz.aQute.bndlib

  1. private void copyInfo(Jar source, Jar dest, String type) throws Exception {
  2. source.ensureManifest();
  3. dest.ensureManifest();
  4. copyInfoResource(source, dest, "LICENSE");
  5. copyInfoResource(source, dest, "LICENSE.html");
  6. copyInfoResource(source, dest, "about.html");
  7. Manifest sm = source.getManifest();
  8. Manifest dm = dest.getManifest();
  9. copyInfoHeader(sm, dm, Constants.BUNDLE_DESCRIPTION, "");
  10. copyInfoHeader(sm, dm, Constants.BUNDLE_VENDOR, "");
  11. copyInfoHeader(sm, dm, Constants.BUNDLE_COPYRIGHT, "");
  12. copyInfoHeader(sm, dm, Constants.BUNDLE_DOCURL, "");
  13. copyInfoHeader(sm, dm, Constants.BUNDLE_LICENSE, "");
  14. copyInfoHeader(sm, dm, Constants.BUNDLE_NAME, " " + type);
  15. copyInfoHeader(sm, dm, Constants.BUNDLE_SYMBOLICNAME, "." + type);
  16. copyInfoHeader(sm, dm, Constants.BUNDLE_VERSION, "");
  17. }

代码示例来源:origin: biz.aQute.bnd/bndlib

  1. private void copyInfo(Jar source, Jar dest, String type) throws Exception {
  2. source.ensureManifest();
  3. dest.ensureManifest();
  4. copyInfoResource(source, dest, "LICENSE");
  5. copyInfoResource(source, dest, "LICENSE.html");
  6. copyInfoResource(source, dest, "about.html");
  7. Manifest sm = source.getManifest();
  8. Manifest dm = dest.getManifest();
  9. copyInfoHeader(sm, dm, Constants.BUNDLE_DESCRIPTION, "");
  10. copyInfoHeader(sm, dm, Constants.BUNDLE_VENDOR, "");
  11. copyInfoHeader(sm, dm, Constants.BUNDLE_COPYRIGHT, "");
  12. copyInfoHeader(sm, dm, Constants.BUNDLE_DOCURL, "");
  13. copyInfoHeader(sm, dm, Constants.BUNDLE_LICENSE, "");
  14. copyInfoHeader(sm, dm, Constants.BUNDLE_NAME, " " + type);
  15. copyInfoHeader(sm, dm, Constants.BUNDLE_SYMBOLICNAME, "." + type);
  16. copyInfoHeader(sm, dm, Constants.BUNDLE_VERSION, "");
  17. }

代码示例来源:origin: biz.aQute.bnd/biz.aQute.bnd

  1. private void copyInfo(Jar source, Jar dest, String type) throws Exception {
  2. source.ensureManifest();
  3. dest.ensureManifest();
  4. copyInfoResource(source, dest, "LICENSE");
  5. copyInfoResource(source, dest, "LICENSE.html");
  6. copyInfoResource(source, dest, "about.html");
  7. Manifest sm = source.getManifest();
  8. Manifest dm = dest.getManifest();
  9. copyInfoHeader(sm, dm, Constants.BUNDLE_DESCRIPTION, "");
  10. copyInfoHeader(sm, dm, Constants.BUNDLE_VENDOR, "");
  11. copyInfoHeader(sm, dm, Constants.BUNDLE_COPYRIGHT, "");
  12. copyInfoHeader(sm, dm, Constants.BUNDLE_DOCURL, "");
  13. copyInfoHeader(sm, dm, Constants.BUNDLE_LICENSE, "");
  14. copyInfoHeader(sm, dm, Constants.BUNDLE_NAME, " " + type);
  15. copyInfoHeader(sm, dm, Constants.BUNDLE_SYMBOLICNAME, "." + type);
  16. copyInfoHeader(sm, dm, Constants.BUNDLE_VERSION, "");
  17. }

代码示例来源:origin: biz.aQute.bnd/bnd

  1. private void copyInfo(Jar source, Jar dest, String type) throws Exception {
  2. source.ensureManifest();
  3. dest.ensureManifest();
  4. copyInfoResource(source, dest, "LICENSE");
  5. copyInfoResource(source, dest, "LICENSE.html");
  6. copyInfoResource(source, dest, "about.html");
  7. Manifest sm = source.getManifest();
  8. Manifest dm = dest.getManifest();
  9. copyInfoHeader(sm, dm, Constants.BUNDLE_DESCRIPTION, "");
  10. copyInfoHeader(sm, dm, Constants.BUNDLE_VENDOR, "");
  11. copyInfoHeader(sm, dm, Constants.BUNDLE_COPYRIGHT, "");
  12. copyInfoHeader(sm, dm, Constants.BUNDLE_DOCURL, "");
  13. copyInfoHeader(sm, dm, Constants.BUNDLE_LICENSE, "");
  14. copyInfoHeader(sm, dm, Constants.BUNDLE_NAME, " " + type);
  15. copyInfoHeader(sm, dm, Constants.BUNDLE_SYMBOLICNAME, "." + type);
  16. copyInfoHeader(sm, dm, Constants.BUNDLE_VERSION, "");
  17. }

相关文章