Java Doc for COSBasedObject.java in  » PDF » jPod » de » intarsys » pdf » cos » 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 » PDF » jPod » de.intarsys.pdf.cos 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   de.intarsys.pdf.cos.COSBasedObject

All known Subclasses:   de.intarsys.pdf.cds.CDSBase,  de.intarsys.pdf.cos.COSTrailer,  de.intarsys.pdf.pd.PDObject,  de.intarsys.pdf.font.CMap,  de.intarsys.pdf.font.CIDSystemInfo,  de.intarsys.pdf.fd.FDObject,  de.intarsys.pdf.st.COSObjectStream,  de.intarsys.pdf.cos.COSInfoDict,  de.intarsys.pdf.crypt.COSEncryption,  de.intarsys.pdf.font.CIDToGIDMap,  de.intarsys.pdf.cos.COSCatalog,
COSBasedObject
abstract public class COSBasedObject implements IAttributeSupport,ICOSObjectListener(Code)
The abstract superclass for all objects/data structures that are build on the basic COSObject types.

The base COSObject will represent the state while this wrapper will provide the behavior.

The COSBasedObject and its base COSObject are always closely related, all changes are immediately reflected in both objects.

The COSBasedObject uses a META framework that ensures identity (you will always get the identical COSBasedObject for a COSObject created via META) and defines the lifecycle of the COSBasedObject . A COSBasedObject should always be created using META.createNew or META.createFromCos.

A COSBasedObject based on a COSDictionary can use some convenience methods for generic access to its fields. As a convention, filed names are always declared with the associated COSBasedObject as public static final COSName DK_.

The COSBasedObject implements IAttributeSupport . Client code can use this feature to transparently associate objects with objects from client code, for example for caching or client defined relationships.


Inner Class :public static class MetaClass extends de.intarsys.pdf.cos.MetaClass

Field Summary
final public static  MetaClassMETA
    

Constructor Summary
protected  COSBasedObject(COSObject object)
    

Method Summary
public  voidchanged(COSObject pObject, Object slot, Object oldValue, Object newValue)
    
public  COSArraycosGetArray()
     Get the base object as a COSArray .
public  COSDictionarycosGetDict()
     Get the base object as a COSDictionary .
public  COSDocumentcosGetDoc()
     The COSDocument for this.
public  COSObjectcosGetField(COSName name)
     The COSObject associated with name in the receiver or COSNull .
public  COSObjectcosGetObject()
     The base COSObject for this.
public  COSStreamcosGetStream()
     Get the base object as a COSStream .
public  booleancosHasField(COSName name)
     Answer true if this has a field named name.
public  COSObjectcosRemoveField(COSName name)
     Remove a field in this.
public  COSObjectcosSetField(COSName name, COSObject cosObj)
     Set a field value in this.
public  ObjectgetAttribute(Object key)
    
public  booleangetFieldBoolean(COSName name, boolean defaultValue)
     The value of a field within this as a boolean or the defaultValue if not found or not a COSBoolean .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type.

public  CDSDategetFieldDate(COSName name, CDSDate defaultValue)
     The value of a field within this as a CDSDate or the defaultValue if not found or not a COSString .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type.

public  floatgetFieldFixed(COSName name, float defaultValue)
     The value of a field within this as a float or the defaultValue if not found or not a COSNumber .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type.

public  float[]getFieldFixedArray(COSName name, float[] defaultValue)
     The value of a field within this as a float[] or the defaultValue if not found or not a COSArray .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type.

public  intgetFieldInt(COSName name, int defaultValue)
     The value of a field within this as a int or the defaultValue if not found or not a COSNumber .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type.

public  StringgetFieldMLString(COSName name, String defaultValue)
     The value of a field within this as a String or the defaultValue if not found or not a COSString .
public  StringgetFieldString(COSName name, String defaultValue)
     The value of a field within this as a String or the defaultValue if not found or not a COSString .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type.

protected  voidinitializeFromCos()
    
protected  voidinitializeFromScratch()
    
public  voidinvalidateCaches()
     Invalidate all local caches as the base object may have changed.
public  ObjectremoveAttribute(Object key)
    
public  ObjectsetAttribute(Object key, Object value)
    
public  voidsetFieldBoolean(COSName name, boolean value)
     Set the value of field namewithin this.
public  voidsetFieldFixed(COSName name, float value)
     Set the value of field namewithin this.
protected  voidsetFieldFixedArray(COSName key, float[] array)
     Set the value of field namewithin this.
public  voidsetFieldInt(COSName name, int value)
     Set the value of field namewithin this.
public  voidsetFieldMLString(COSName name, String value)
     Set the value of field namewithin this.
public  voidsetFieldName(COSName name, String value)
     Set the value of field namewithin this.
public  voidsetFieldObject(COSName name, COSBasedObject value)
     Set the value of field namewithin this.
public  voidsetFieldString(COSName name, String value)
     Set the value of field namewithin this.
public  StringtoString()
    

Field Detail
META
final public static MetaClass META(Code)
The meta class instance




Constructor Detail
COSBasedObject
protected COSBasedObject(COSObject object)(Code)




Method Detail
changed
public void changed(COSObject pObject, Object slot, Object oldValue, Object newValue)(Code)



cosGetArray
public COSArray cosGetArray()(Code)
Get the base object as a COSArray .

This will throw a ClassCastException if the base type is not appropriate! Get the base object as a COSArray.




cosGetDict
public COSDictionary cosGetDict()(Code)
Get the base object as a COSDictionary .

This will throw a ClassCastException if the base type is not appropriate! Get the base object as a COSDictionary.




cosGetDoc
public COSDocument cosGetDoc()(Code)
The COSDocument for this. The COSDocument for this.



cosGetField
public COSObject cosGetField(COSName name)(Code)
The COSObject associated with name in the receiver or COSNull .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The COSDictionary field to read The COSObject associated with name in thereceiver or COSNull.




cosGetObject
public COSObject cosGetObject()(Code)
The base COSObject for this. The base COSObject for this.



cosGetStream
public COSStream cosGetStream()(Code)
Get the base object as a COSStream .

This will throw a ClassCastException if the base type is not appropriate! Get the base object as a COSStream.




cosHasField
public boolean cosHasField(COSName name)(Code)
Answer true if this has a field named name.

This method requires the base object to be a COSDictionary .
Parameters:
  name - the field to check Answer true if this has a field namedname.




cosRemoveField
public COSObject cosRemoveField(COSName name)(Code)
Remove a field in this. The previously associated object is returned.

This method requires the base object to be a COSDictionary .
Parameters:
  name - the field to remove from the receiver The previously associated object is returned.




cosSetField
public COSObject cosSetField(COSName name, COSObject cosObj)(Code)
Set a field value in this. The previously associated object is returned.

This method requires the base object to be a COSDictionary .
Parameters:
  name - The field to set
Parameters:
  cosObj - The object to set in the field The previously associated object is returned.




getAttribute
public Object getAttribute(Object key)(Code)



getFieldBoolean
public boolean getFieldBoolean(COSName name, boolean defaultValue)(Code)
The value of a field within this as a boolean or the defaultValue if not found or not a COSBoolean .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type. The value of a field within this as a boolean




getFieldDate
public CDSDate getFieldDate(COSName name, CDSDate defaultValue)(Code)
The value of a field within this as a CDSDate or the defaultValue if not found or not a COSString .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type. The value of a field within this as a CDSDate




getFieldFixed
public float getFieldFixed(COSName name, float defaultValue)(Code)
The value of a field within this as a float or the defaultValue if not found or not a COSNumber .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type. The value of a field within this as a float




getFieldFixedArray
public float[] getFieldFixedArray(COSName name, float[] defaultValue)(Code)
The value of a field within this as a float[] or the defaultValue if not found or not a COSArray .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type. The value of a field within this as a float[]




getFieldInt
public int getFieldInt(COSName name, int defaultValue)(Code)
The value of a field within this as a int or the defaultValue if not found or not a COSNumber .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type. The value of a field within this as a int




getFieldMLString
public String getFieldMLString(COSName name, String defaultValue)(Code)
The value of a field within this as a String or the defaultValue if not found or not a COSString . The String is "expanded" to containn the correct new line characters.

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type. The value of a field within this as a String




getFieldString
public String getFieldString(COSName name, String defaultValue)(Code)
The value of a field within this as a String or the defaultValue if not found or not a COSString .

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  defaultValue - The default value to return if field is not found or not ofappropriate type. The value of a field within this as a String




initializeFromCos
protected void initializeFromCos()(Code)



initializeFromScratch
protected void initializeFromScratch()(Code)



invalidateCaches
public void invalidateCaches()(Code)
Invalidate all local caches as the base object may have changed.



removeAttribute
public Object removeAttribute(Object key)(Code)



setAttribute
public Object setAttribute(Object key, Object value)(Code)



setFieldBoolean
public void setFieldBoolean(COSName name, boolean value)(Code)
Set the value of field namewithin this.

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  value - The new value of the field.




setFieldFixed
public void setFieldFixed(COSName name, float value)(Code)
Set the value of field namewithin this.

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  value - The new value of the field.




setFieldFixedArray
protected void setFieldFixedArray(COSName key, float[] array)(Code)
Set the value of field namewithin this.

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  value - The new value of the field.




setFieldInt
public void setFieldInt(COSName name, int value)(Code)
Set the value of field namewithin this.

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  value - The new value of the field.




setFieldMLString
public void setFieldMLString(COSName name, String value)(Code)
Set the value of field namewithin this.

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  value - The new value of the field.




setFieldName
public void setFieldName(COSName name, String value)(Code)
Set the value of field namewithin this.

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  value - The new value of the field.




setFieldObject
public void setFieldObject(COSName name, COSBasedObject value)(Code)
Set the value of field namewithin this.

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  value - The new value of the field.




setFieldString
public void setFieldString(COSName name, String value)(Code)
Set the value of field namewithin this.

This method requires the base object to be a COSDictionary .
Parameters:
  name - The name of the field.
Parameters:
  value - The new value of the field.




toString
public String toString()(Code)



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.