Source Code Cross Referenced for SpecialPropertySet.java in  » Collaboration » poi-3.0.2-beta2 » org » apache » poi » hpsf » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Collaboration » poi 3.0.2 beta2 » org.apache.poi.hpsf 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /* ====================================================================
002:           Licensed to the Apache Software Foundation (ASF) under one or more
003:           contributor license agreements.  See the NOTICE file distributed with
004:           this work for additional information regarding copyright ownership.
005:           The ASF licenses this file to You under the Apache License, Version 2.0
006:           (the "License"); you may not use this file except in compliance with
007:           the License.  You may obtain a copy of the License at
008:
009:               http://www.apache.org/licenses/LICENSE-2.0
010:
011:           Unless required by applicable law or agreed to in writing, software
012:           distributed under the License is distributed on an "AS IS" BASIS,
013:           WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014:           See the License for the specific language governing permissions and
015:           limitations under the License.
016:        ==================================================================== */
017:
018:        package org.apache.poi.hpsf;
019:
020:        import java.io.IOException;
021:        import java.io.InputStream;
022:        import java.io.OutputStream;
023:        import java.util.List;
024:
025:        import org.apache.poi.poifs.filesystem.DirectoryEntry;
026:
027:        /**
028:         * <p>Abstract superclass for the convenience classes {@link
029:         * SummaryInformation} and {@link DocumentSummaryInformation}.</p>
030:         *
031:         * <p>The motivation behind this class is quite nasty if you look
032:         * behind the scenes, but it serves the application programmer well by
033:         * providing him with the easy-to-use {@link SummaryInformation} and
034:         * {@link DocumentSummaryInformation} classes. When parsing the data a
035:         * property set stream consists of (possibly coming from an {@link
036:         * java.io.InputStream}) we want to read and process each byte only
037:         * once. Since we don't know in advance which kind of property set we
038:         * have, we can expect only the most general {@link
039:         * PropertySet}. Creating a special subclass should be as easy as
040:         * calling the special subclass' constructor and pass the general
041:         * {@link PropertySet} in. To make things easy internally, the special
042:         * class just holds a reference to the general {@link PropertySet} and
043:         * delegates all method calls to it.</p>
044:         *
045:         * <p>A cleaner implementation would have been like this: The {@link
046:         * PropertySetFactory} parses the stream data into some internal
047:         * object first.  Then it finds out whether the stream is a {@link
048:         * SummaryInformation}, a {@link DocumentSummaryInformation} or a
049:         * general {@link PropertySet}.  However, the current implementation
050:         * went the other way round historically: the convenience classes came
051:         * only late to my mind.</p>
052:         *
053:         * @author Rainer Klute <a
054:         * href="mailto:klute@rainer-klute.de">&lt;klute@rainer-klute.de&gt;</a>
055:         * @version $Id: SpecialPropertySet.java 489730 2006-12-22 19:18:16Z bayard $
056:         * @since 2002-02-09
057:         */
058:        public abstract class SpecialPropertySet extends MutablePropertySet {
059:
060:            /**
061:             * <p>The "real" property set <code>SpecialPropertySet</code>
062:             * delegates to.</p>
063:             */
064:            private MutablePropertySet delegate;
065:
066:            /**
067:             * <p>Creates a <code>SpecialPropertySet</code>.
068:             *
069:             * @param ps The property set to be encapsulated by the
070:             * <code>SpecialPropertySet</code>
071:             */
072:            public SpecialPropertySet(final PropertySet ps) {
073:                delegate = new MutablePropertySet(ps);
074:            }
075:
076:            /**
077:             * <p>Creates a <code>SpecialPropertySet</code>.
078:             *
079:             * @param ps The mutable property set to be encapsulated by the
080:             * <code>SpecialPropertySet</code>
081:             */
082:            public SpecialPropertySet(final MutablePropertySet ps) {
083:                delegate = ps;
084:            }
085:
086:            /**
087:             * @see PropertySet#getByteOrder
088:             */
089:            public int getByteOrder() {
090:                return delegate.getByteOrder();
091:            }
092:
093:            /**
094:             * @see PropertySet#getFormat
095:             */
096:            public int getFormat() {
097:                return delegate.getFormat();
098:            }
099:
100:            /**
101:             * @see PropertySet#getOSVersion
102:             */
103:            public int getOSVersion() {
104:                return delegate.getOSVersion();
105:            }
106:
107:            /**
108:             * @see PropertySet#getClassID
109:             */
110:            public ClassID getClassID() {
111:                return delegate.getClassID();
112:            }
113:
114:            /**
115:             * @see PropertySet#getSectionCount
116:             */
117:            public int getSectionCount() {
118:                return delegate.getSectionCount();
119:            }
120:
121:            /**
122:             * @see PropertySet#getSections
123:             */
124:            public List getSections() {
125:                return delegate.getSections();
126:            }
127:
128:            /**
129:             * @see PropertySet#isSummaryInformation
130:             */
131:            public boolean isSummaryInformation() {
132:                return delegate.isSummaryInformation();
133:            }
134:
135:            /**
136:             * @see PropertySet#isDocumentSummaryInformation
137:             */
138:            public boolean isDocumentSummaryInformation() {
139:                return delegate.isDocumentSummaryInformation();
140:            }
141:
142:            /**
143:             * @see PropertySet#getSingleSection
144:             */
145:            public Section getFirstSection() {
146:                return delegate.getFirstSection();
147:            }
148:
149:            /**
150:             * @see org.apache.poi.hpsf.MutablePropertySet#addSection(org.apache.poi.hpsf.Section)
151:             */
152:            public void addSection(final Section section) {
153:                delegate.addSection(section);
154:            }
155:
156:            /**
157:             * @see org.apache.poi.hpsf.MutablePropertySet#clearSections()
158:             */
159:            public void clearSections() {
160:                delegate.clearSections();
161:            }
162:
163:            /**
164:             * @see org.apache.poi.hpsf.MutablePropertySet#setByteOrder(int)
165:             */
166:            public void setByteOrder(final int byteOrder) {
167:                delegate.setByteOrder(byteOrder);
168:            }
169:
170:            /**
171:             * @see org.apache.poi.hpsf.MutablePropertySet#setClassID(org.apache.poi.hpsf.ClassID)
172:             */
173:            public void setClassID(final ClassID classID) {
174:                delegate.setClassID(classID);
175:            }
176:
177:            /**
178:             * @see org.apache.poi.hpsf.MutablePropertySet#setFormat(int)
179:             */
180:            public void setFormat(final int format) {
181:                delegate.setFormat(format);
182:            }
183:
184:            /**
185:             * @see org.apache.poi.hpsf.MutablePropertySet#setOSVersion(int)
186:             */
187:            public void setOSVersion(final int osVersion) {
188:                delegate.setOSVersion(osVersion);
189:            }
190:
191:            /**
192:             * @see org.apache.poi.hpsf.MutablePropertySet#toInputStream()
193:             */
194:            public InputStream toInputStream() throws IOException,
195:                    WritingNotSupportedException {
196:                return delegate.toInputStream();
197:            }
198:
199:            /**
200:             * @see org.apache.poi.hpsf.MutablePropertySet#write(org.apache.poi.poifs.filesystem.DirectoryEntry, java.lang.String)
201:             */
202:            public void write(final DirectoryEntry dir, final String name)
203:                    throws WritingNotSupportedException, IOException {
204:                delegate.write(dir, name);
205:            }
206:
207:            /**
208:             * @see org.apache.poi.hpsf.MutablePropertySet#write(java.io.OutputStream)
209:             */
210:            public void write(final OutputStream out)
211:                    throws WritingNotSupportedException, IOException {
212:                delegate.write(out);
213:            }
214:
215:            /**
216:             * @see org.apache.poi.hpsf.PropertySet#equals(java.lang.Object)
217:             */
218:            public boolean equals(final Object o) {
219:                return delegate.equals(o);
220:            }
221:
222:            /**
223:             * @see org.apache.poi.hpsf.PropertySet#getProperties()
224:             */
225:            public Property[] getProperties() throws NoSingleSectionException {
226:                return delegate.getProperties();
227:            }
228:
229:            /**
230:             * @see org.apache.poi.hpsf.PropertySet#getProperty(int)
231:             */
232:            protected Object getProperty(final int id)
233:                    throws NoSingleSectionException {
234:                return delegate.getProperty(id);
235:            }
236:
237:            /**
238:             * @see org.apache.poi.hpsf.PropertySet#getPropertyBooleanValue(int)
239:             */
240:            protected boolean getPropertyBooleanValue(final int id)
241:                    throws NoSingleSectionException {
242:                return delegate.getPropertyBooleanValue(id);
243:            }
244:
245:            /**
246:             * @see org.apache.poi.hpsf.PropertySet#getPropertyIntValue(int)
247:             */
248:            protected int getPropertyIntValue(final int id)
249:                    throws NoSingleSectionException {
250:                return delegate.getPropertyIntValue(id);
251:            }
252:
253:            /**
254:             * @see org.apache.poi.hpsf.PropertySet#hashCode()
255:             */
256:            public int hashCode() {
257:                return delegate.hashCode();
258:            }
259:
260:            /**
261:             * @see org.apache.poi.hpsf.PropertySet#toString()
262:             */
263:            public String toString() {
264:                return delegate.toString();
265:            }
266:
267:            /**
268:             * @see org.apache.poi.hpsf.PropertySet#wasNull()
269:             */
270:            public boolean wasNull() throws NoSingleSectionException {
271:                return delegate.wasNull();
272:            }
273:
274:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.