Java Doc for Thumbnail.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 Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.apache.poi.hpsf.Thumbnail

Thumbnail
public class Thumbnail (Code)

Class to manipulate data in the Clipboard Variant ( Variant.VT_CF VT_CF ) format.


author:
   Drew Varner (Drew.Varner inOrAround sc.edu)
See Also:   SummaryInformation.getThumbnail
version:
   $Id: Thumbnail.java 489730 2006-12-22 19:18:16Z bayard $
since:
   2002-04-29


Field Summary
public static  intCFTAG_FMTID
    

Clipboard Format Tag - Format ID

A GUID containing a format identifier (FMTID).

public static  intCFTAG_MACINTOSH
    
public static  intCFTAG_NODATA
    

Clipboard Format Tag - No Data

A DWORD indicating No data.

public static  intCFTAG_WINDOWS
    
public static  intCF_BITMAP
    
public static  intCF_DIB
    
public static  intCF_ENHMETAFILE
    
public static  intCF_METAFILEPICT
    

Clipboard Format - Windows metafile format.

public static  intOFFSET_CF
    
public static  intOFFSET_CFTAG
    
public static  intOFFSET_WMFDATA
    

Offset in bytes where the Windows Metafile (WMF) image data starts in the byte[] returned by SummaryInformation.getThumbnail

There is only WMF data at this point in the byte[] if the Clipboard Format Tag is Thumbnail.CFTAG_WINDOWS and the Clipboard Format is Thumbnail.CF_METAFILEPICT .

Note: The byte[] that starts at OFFSET_WMFDATA and ends at getThumbnail().length - 1 forms a complete WMF image.


Constructor Summary
public  Thumbnail()
    

Default Constructor.

public  Thumbnail(byte[] thumbnailData)
    

Method Summary
public  longgetClipboardFormat()
    
public  longgetClipboardFormatTag()
    
public  byte[]getThumbnail()
    
public  byte[]getThumbnailAsWMF()
    
public  voidsetThumbnail(byte[] thumbnail)
    

Field Detail
CFTAG_FMTID
public static int CFTAG_FMTID(Code)

Clipboard Format Tag - Format ID

A GUID containing a format identifier (FMTID). This is rarely used.




CFTAG_MACINTOSH
public static int CFTAG_MACINTOSH(Code)

Clipboard Format Tag - Macintosh clipboard format

A DWORD indicating a Macintosh clipboard format value




CFTAG_NODATA
public static int CFTAG_NODATA(Code)

Clipboard Format Tag - No Data

A DWORD indicating No data. This is rarely used.




CFTAG_WINDOWS
public static int CFTAG_WINDOWS(Code)

Clipboard Format Tag - Windows clipboard format

A DWORD indicating a built-in Windows clipboard format value




CF_BITMAP
public static int CF_BITMAP(Code)

Clipboard Format - Bitmap

Obsolete, see msdn.microsoft.com/library/en-us/dnw98bk/html/clipboardoperations.asp.




CF_DIB
public static int CF_DIB(Code)

Clipboard Format - Device Independent Bitmap




CF_ENHMETAFILE
public static int CF_ENHMETAFILE(Code)

Clipboard Format - Enhanced Windows metafile format




CF_METAFILEPICT
public static int CF_METAFILEPICT(Code)

Clipboard Format - Windows metafile format. This is the recommended way to store thumbnails in Property Streams.

Note: This is not the same format used in regular WMF images. The clipboard version of this format has an extra clipboard-specific header.




OFFSET_CF
public static int OFFSET_CF(Code)

Offset in bytes where the Clipboard Format starts in the byte[] returned by SummaryInformation.getThumbnail

This is only valid if the Clipboard Format Tag is Thumbnail.CFTAG_WINDOWS




OFFSET_CFTAG
public static int OFFSET_CFTAG(Code)

Offset in bytes where the Clipboard Format Tag starts in the byte[] returned by SummaryInformation.getThumbnail




OFFSET_WMFDATA
public static int OFFSET_WMFDATA(Code)

Offset in bytes where the Windows Metafile (WMF) image data starts in the byte[] returned by SummaryInformation.getThumbnail

There is only WMF data at this point in the byte[] if the Clipboard Format Tag is Thumbnail.CFTAG_WINDOWS and the Clipboard Format is Thumbnail.CF_METAFILEPICT .

Note: The byte[] that starts at OFFSET_WMFDATA and ends at getThumbnail().length - 1 forms a complete WMF image. It can be saved to disk with a .wmf file type and read using a WMF-capable image viewer.





Constructor Detail
Thumbnail
public Thumbnail()(Code)

Default Constructor. If you use it then one you'll have to add the thumbnail byte[] from SummaryInformation.getThumbnail to do any useful manipulations, otherwise you'll get a NullPointerException.




Thumbnail
public Thumbnail(byte[] thumbnailData)(Code)

Creates a Thumbnail instance and initializes with the specified image bytes.


Parameters:
  thumbnailData - The thumbnail data




Method Detail
getClipboardFormat
public long getClipboardFormat() throws HPSFException(Code)

Returns an int representing the Clipboard Format

Will throw an exception if the Thumbnail's Clipboard Format Tag is not Thumbnail.CFTAG_WINDOWS CFTAG_WINDOWS .

Possible return values are:

a flag indicating the Clipboard Format
throws:
  HPSFException - if the Thumbnail isn't CFTAG_WINDOWS



getClipboardFormatTag
public long getClipboardFormatTag()(Code)

Returns an int representing the Clipboard Format Tag

Possible return values are:

A flag indicating the Clipboard Format Tag



getThumbnail
public byte[] getThumbnail()(Code)

Returns the thumbnail as a byte[] in Variant.VT_CF VT_CF format.

The thumbnail value
See Also:   SummaryInformation.getThumbnail



getThumbnailAsWMF
public byte[] getThumbnailAsWMF() throws HPSFException(Code)

Returns the Thumbnail as a byte[] of WMF data if the Thumbnail's Clipboard Format Tag is Thumbnail.CFTAG_WINDOWS CFTAG_WINDOWS and its Clipboard Format is Thumbnail.CF_METAFILEPICT CF_METAFILEPICT

This byte[] is in the traditional WMF file, not the clipboard-specific version with special headers.

See http://www.wvware.com/caolan/ora-wmf.html for more information on the WMF image format.

A WMF image of the Thumbnail
throws:
  HPSFException - if the Thumbnail isn't CFTAG_WINDOWS andCF_METAFILEPICT



setThumbnail
public void setThumbnail(byte[] thumbnail)(Code)

Sets the Thumbnail's underlying byte[] in Variant.VT_CF VT_CF format.


Parameters:
  thumbnail - The new thumbnail value
See Also:   SummaryInformation.getThumbnail



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.