Java Doc for Serializer.java in  » 6.0-JDK-Modules » Java-Advanced-Imaging » javax » media » jai » remote » 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 » 6.0 JDK Modules » Java Advanced Imaging » javax.media.jai.remote 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


javax.media.jai.remote.Serializer

All known Subclasses:   com.sun.media.jai.rmi.SerializerImpl,
Serializer
public interface Serializer (Code)
An interface to be implemented by classes which are capable of converting an instance of a supported class into a state representation of the object which is serializable. Supported classes may in fact be classes or interfaces.

When possible, classes (not interfaces) should be supported explicitly, i.e., the getObjectClass() method of the SerializableState returned by getState(Object) should return the same value which would be returned by invoking getClass() on the object passed to getState(Object). In particular, whenever feasible a Serializer should not be used to serialize a given object into a form which when deserialized would yield an instance of the superclass of the class of which the object is an instance. When it is not possible to provide a class-specific Serializer, such as when a factory class generate subclasses of itself via factory methods, then permitsSubclasses() should return true; in the case of class-specific Serializers it should return false.
See Also:   SerializableState
See Also:   java.io.Serializable
since:
   JAI 1.1





Method Summary
 SerializableStategetState(Object o, RenderingHints h)
     Converts an object into a state-preserving object which may be serialized.
 ClassgetSupportedClass()
     Returns the class or interface which is supported by this Serializer.
 booleanpermitsSubclasses()
     Returns true if and only if it is legal for this Serializer to be used to serialize a subclass.



Method Detail
getState
SerializableState getState(Object o, RenderingHints h)(Code)
Converts an object into a state-preserving object which may be serialized. If the value returned by getSupportedClass() is a class, i.e., not an interface, then the parameter of getState() should be an instance of that class; if getSupportedClass() returns an interface, then the parameter of getState() should implement that interface. If the apposite condition is not satisfied then an IllegalArgumentException will be thrown.

If the class of the parameter is supported explicitly, i.e., is an instance of the class returned by getSupportedClass(), then the object returned by the getObject() method of the generated SerializableState will be an instance of the same class. If getSupportedClass() returns an interface which the class of the parameter implements, then the object returned by the getObject() method of the generated SerializableState will be an instance of an unspecified class which implements that interface.
Parameters:
  o - The object to be converted into a serializable form.
Parameters:
  h - Configuration parameters the exact nature of which isSerializer-dependent. If null,reasonable default settings should be used. A serializable form of the supplied object.
exception:
  IllegalArgumentException - if o isnull, the supported class is an interfacenot implemented by the class of which o isan instance, or the supported class is not an interfaceand getSupportedClass().equals(o.getClass())returns false.




getSupportedClass
Class getSupportedClass()(Code)
Returns the class or interface which is supported by this Serializer. The supported Class.



permitsSubclasses
boolean permitsSubclasses()(Code)
Returns true if and only if it is legal for this Serializer to be used to serialize a subclass. In general this method should return false, i.e., a specific Serializer should be registered explicitly for each class. In some cases this is however not expedient. An example of this is a Serializer of classes created by a factory class: the exact subclasses may not be known but sufficient information may be able to be extracted from the subclass instance to permit its serialization by the Serializer registered for the factory class.



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