From 24de462cba0f25ccf3f2a441c5fceb86a2745521 Mon Sep 17 00:00:00 2001 From: Rainer Klute Date: Mon, 15 Sep 2003 20:13:45 +0000 Subject: [PATCH] *** empty log message *** git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@353352 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/poi/hpsf/examples/WriteTitle.java | 20 +++++++------------ 1 file changed, 7 insertions(+), 13 deletions(-) diff --git a/src/examples/src/org/apache/poi/hpsf/examples/WriteTitle.java b/src/examples/src/org/apache/poi/hpsf/examples/WriteTitle.java index 3992741e3..c98274829 100644 --- a/src/examples/src/org/apache/poi/hpsf/examples/WriteTitle.java +++ b/src/examples/src/org/apache/poi/hpsf/examples/WriteTitle.java @@ -54,19 +54,11 @@ */ package org.apache.poi.hpsf.examples; -import java.io.FileOutputStream; -import java.io.IOException; -import java.io.InputStream; +import java.io.*; -import org.apache.poi.hpsf.MutableProperty; -import org.apache.poi.hpsf.MutablePropertySet; -import org.apache.poi.hpsf.MutableSection; -import org.apache.poi.hpsf.SummaryInformation; -import org.apache.poi.hpsf.Variant; -import org.apache.poi.hpsf.WritingNotSupportedException; -import org.apache.poi.hpsf.wellknown.PropertyIDMap; -import org.apache.poi.hpsf.wellknown.SectionIDMap; -import org.apache.poi.poifs.filesystem.POIFSFileSystem; +import org.apache.poi.hpsf.*; +import org.apache.poi.hpsf.wellknown.*; +import org.apache.poi.poifs.filesystem.*; /** *

This class is a simple sample application showing how to create a property @@ -99,7 +91,6 @@ public class WriteTitle } final String fileName = args[0]; - final POIFSFileSystem poiFs = new POIFSFileSystem(); /* Create a mutable property set. Initially it contains a single section * with no properties. */ @@ -122,6 +113,9 @@ public class WriteTitle p.setType(Variant.VT_LPWSTR); p.setValue("Sample title"); + /* Create the POI file system the property set is to be written to. */ + final POIFSFileSystem poiFs = new POIFSFileSystem(); + /* For writing the property set into a POI file system it has to be * handed over to the POIFS.createDocument() method as an input stream * which produces the bytes making out the property set stream. */