gpt4 book ai didi

org.apache.poi.openxml4j.opc.internal.ZipContentTypeManager.()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-17 19:09:31 27 4
gpt4 key购买 nike

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

ZipContentTypeManager.<init>介绍

[英]Delegate constructor to the super constructor.
[中]将构造函数委托给超级构造函数。

代码示例

代码示例来源:origin: org.apache.poi/poi-ooxml

/**
 * Constructor. Creates a new, empty ZipPackage.
 */
public ZipPackage() {
  super(defaultPackageAccess);
  this.zipArchive = null;
  try {
    this.contentTypeManager = new ZipContentTypeManager(null, this);
  } catch (InvalidFormatException e) {
    LOG.log(POILogger.WARN,"Could not parse ZipPackage", e);
  }
}

代码示例来源:origin: org.apache.poi/poi-ooxml

private static void configurePackage(OPCPackage pkg) {
  try {
    // Content type manager
    pkg.contentTypeManager = new ZipContentTypeManager(null, pkg);
    
    // Add default content types for .xml and .rels
    pkg.contentTypeManager.addContentType(
        PackagingURIHelper.createPartName(
            PackagingURIHelper.PACKAGE_RELATIONSHIPS_ROOT_URI),
        ContentTypes.RELATIONSHIPS_PART);
    pkg.contentTypeManager.addContentType(
        PackagingURIHelper.createPartName("/default.xml"),
        ContentTypes.PLAIN_OLD_XML);
    // Initialise some PackageBase properties
    pkg.packageProperties = new PackagePropertiesPart(pkg,
        PackagingURIHelper.CORE_PROPERTIES_PART_NAME);
    pkg.packageProperties.setCreatorProperty("Generated by Apache POI OpenXML4J");
    pkg.packageProperties.setCreatedProperty(Optional.of(new Date()));
  } catch (InvalidFormatException e) {
    // Should never happen
    throw new IllegalStateException(e);
  }
}

代码示例来源:origin: org.apache.poi/poi-ooxml

this.contentTypeManager = new ZipContentTypeManager(
      zipArchive.getInputStream(contentTypeEntry), this);
} catch (IOException e) {

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi

/**
 * Constructor. Creates a new, empty ZipPackage.
 */
public ZipPackage() {
  super(defaultPackageAccess);
  this.zipArchive = null;
  try {
    this.contentTypeManager = new ZipContentTypeManager(null, this);
  } catch (InvalidFormatException e) {
    LOG.log(POILogger.WARN,"Could not parse ZipPackage", e);
  }
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi

private static void configurePackage(OPCPackage pkg) {
  try {
    // Content type manager
    pkg.contentTypeManager = new ZipContentTypeManager(null, pkg);
    
    // Add default content types for .xml and .rels
    pkg.contentTypeManager.addContentType(
        PackagingURIHelper.createPartName(
            PackagingURIHelper.PACKAGE_RELATIONSHIPS_ROOT_URI),
        ContentTypes.RELATIONSHIPS_PART);
    pkg.contentTypeManager.addContentType(
        PackagingURIHelper.createPartName("/default.xml"),
        ContentTypes.PLAIN_OLD_XML);
    // Initialise some PackageBase properties
    pkg.packageProperties = new PackagePropertiesPart(pkg,
        PackagingURIHelper.CORE_PROPERTIES_PART_NAME);
    pkg.packageProperties.setCreatorProperty("Generated by Apache POI OpenXML4J");
    pkg.packageProperties.setCreatedProperty(Optional.of(new Date()));
  } catch (InvalidFormatException e) {
    // Should never happen
    throw new IllegalStateException(e);
  }
}

代码示例来源:origin: org.openl.rules/org.openl.lib.poi.dev

/**
 * Configure the package.
 *
 * @param pkg
 */
private static void configurePackage(OPCPackage pkg) {
  try {
    // Content type manager
    pkg.contentTypeManager = new ZipContentTypeManager(null, pkg);
    // Add default content types for .xml and .rels
    pkg.contentTypeManager
        .addContentType(
            PackagingURIHelper
                .createPartName(PackagingURIHelper.PACKAGE_RELATIONSHIPS_ROOT_URI),
            ContentTypes.RELATIONSHIPS_PART);
    pkg.contentTypeManager
        .addContentType(PackagingURIHelper
            .createPartName("/default.xml"),
            ContentTypes.PLAIN_OLD_XML);
    // Init some PackageBase properties
    pkg.packageProperties = new PackagePropertiesPart(pkg,
        PackagingURIHelper.CORE_PROPERTIES_PART_NAME);
    pkg.packageProperties.setCreatorProperty("Generated by OpenXML4J");
    pkg.packageProperties.setCreatedProperty(new Nullable<Date>(
        new Date()));
  } catch (InvalidFormatException e) {
    // Should never happen
    throw new IllegalStateException(e);
  }
}

代码示例来源:origin: org.openl.rules/org.openl.lib.poi.dev

/**
 * Configure the package.
 * 
 * @param pkg
 */
private static void configurePackage(Package pkg) {
  try {
    // Content type manager
    pkg.contentTypeManager = new ZipContentTypeManager(null, pkg);
    // Add default content types for .xml and .rels
    pkg.contentTypeManager
        .addContentType(
            PackagingURIHelper
                .createPartName(PackagingURIHelper.PACKAGE_RELATIONSHIPS_ROOT_URI),
            ContentTypes.RELATIONSHIPS_PART);
    pkg.contentTypeManager
        .addContentType(PackagingURIHelper
            .createPartName("/default.xml"),
            ContentTypes.PLAIN_OLD_XML);
    // Init some Package properties
    pkg.packageProperties = new PackagePropertiesPart(pkg,
        PackagingURIHelper.CORE_PROPERTIES_PART_NAME);
    pkg.packageProperties.setCreatorProperty("Generated by OpenXML4J");
    pkg.packageProperties.setCreatedProperty(new Nullable<Date>(
        new Date()));
  } catch (InvalidFormatException e) {
    // Should never happen
    throw new IllegalStateException(e);
  }
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi

this.contentTypeManager = new ZipContentTypeManager(
      zipArchive.getInputStream(contentTypeEntry), this);
} catch (IOException e) {

代码示例来源:origin: jbaliuka/x4j-analytic

ZipContentTypeManager manager = new ZipContentTypeManager(null,null);

代码示例来源:origin: org.openl.rules/org.openl.lib.poi.dev

ContentTypeManager.CONTENT_TYPES_PART_NAME)) {
try {
  this.contentTypeManager = new ZipContentTypeManager(
      getZipArchive().getInputStream(entry), this);
} catch (IOException e) {

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com