From fc08d48b9f34a0a8ac6a78985c7c57f312ee4dde Mon Sep 17 00:00:00 2001 From: Rainer Klute Date: Thu, 20 Feb 2003 17:51:37 +0000 Subject: [PATCH] *** empty log message *** git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@353008 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/poi/hpsf/examples/ReadTitle.java | 50 +++++++++---------- 1 file changed, 25 insertions(+), 25 deletions(-) diff --git a/src/examples/src/org/apache/poi/hpsf/examples/ReadTitle.java b/src/examples/src/org/apache/poi/hpsf/examples/ReadTitle.java index fce1bd4c07..749d14e843 100644 --- a/src/examples/src/org/apache/poi/hpsf/examples/ReadTitle.java +++ b/src/examples/src/org/apache/poi/hpsf/examples/ReadTitle.java @@ -74,36 +74,36 @@ public class ReadTitle public static void main(String[] args) throws IOException { - final String filename = args[0]; - POIFSReader r = new POIFSReader(); - r.registerListener(new MyPOIFSReaderListener(), - "\005SummaryInformation"); - r.read(new FileInputStream(filename)); + final String filename = args[0]; + POIFSReader r = new POIFSReader(); + r.registerListener(new MyPOIFSReaderListener(), + "\005SummaryInformation"); + r.read(new FileInputStream(filename)); } static class MyPOIFSReaderListener implements POIFSReaderListener { - public void processPOIFSReaderEvent(POIFSReaderEvent event) - { - SummaryInformation si = null; - try - { - si = (SummaryInformation) - PropertySetFactory.create(event.getStream()); - } - catch (Exception ex) - { - throw new RuntimeException - ("Property set stream \"" + - event.getPath() + event.getName() + "\": " + ex); - } - final String title = si.getTitle(); - if (title != null) - System.out.println("Title: \"" + title + "\""); - else - System.out.println("Document has no title."); - } + public void processPOIFSReaderEvent(POIFSReaderEvent event) + { + SummaryInformation si = null; + try + { + si = (SummaryInformation) + PropertySetFactory.create(event.getStream()); + } + catch (Exception ex) + { + throw new RuntimeException + ("Property set stream \"" + + event.getPath() + event.getName() + "\": " + ex); + } + final String title = si.getTitle(); + if (title != null) + System.out.println("Title: \"" + title + "\""); + else + System.out.println("Document has no title."); + } } } -- 2.39.5