Wednesday, November 28, 2007


This process of serializing an object is also called deflating or marshalling an object. The opposite operation, extracting a data structure from a series of bytes, is deserialization (which is also called inflating or unmarshalling).

Marshalling (also known as serialization) is the process of transforming the memory representation of an object to a data format suitable for storage or transmission. It is typically used when data must be moved between different parts of a computer program or from one program to another.
The opposite, or reverse, of Marshalling is called Unmarshalling (also known as deserialization).
Marshalling is heavily used within Microsoft's Component Object Model (COM), where it is necessary for transporting data between processes and between apartments. The conversion of an unmanaged type to a CLR type, in the P/Invoke process (used in the .NET Framework) is an example of an action that requires Marshalling to take place.
Additionally, Marshalling is used extensively within scripts and applications that utilize the XPCOM technologies provided within the Mozilla Application Framework. The Mozilla Firefox Browser is a popular application built with this framework, that additionally allows scripting languages to utilize XPCOM through Cross-Platform Connect (XPConnect).
The terms "marshalling" and "serialization" are not synonymous [1].
To "marshal" an object means to record its state and codebase(s) in such a way that when the marshalled object is "unmarshalled," a copy of the original object is obtained, possibly by automatically loading the class definitions of the object. You can marshal any object that is serializable or remote. Marshalling is like serialization, except marshalling also records codebases. Marshalling is different from serialization in that marshalling treats remote objects specially.
To "serialize" an object means to convert its state into a byte stream in such a way that the byte stream can be converted back into a copy of the object.

Object request broker (ORB)

An object request broker (ORB) is a middleware technology that manages communication and data exchange between objects. ORBs promote interoperability of distributed object systems because they enable users to build systems by piecing together objects- from different vendors- that communicate with each other via the ORB [Wade 94]. The implementation details of the ORB are generally not important to developers building distributed systems. The developers are only concerned with the object interface details. This form of information hiding enhances system maintainability since the object communication details are hidden from the developers and isolated in the ORB [Cobb 95].