encyclopegia.org

Marshalling (computer science)

In computer science, marshalling or marshaling (US spelling) is the process of transforming the memory representation of an object into a data format suitable for storage or transmission, especially between different runtimes.[src] It is typically used when data must be moved between different parts of a computer program or from one program to another.[src] Marshalling simplifies complex communications, because it allows using composite objects instead of being restricted to primitive objects.[src]

In computer science, marshalling or marshaling (US spelling) is the process of transforming the memory representation of an object into a data format suitable for storage or transmission, especially between different runtimes.[src] It is typically used when data must be moved between different parts of a computer program or from one program to another.[src] Marshalling simplifies complex communications, because it allows using composite objects instead of being restricted to primitive objects.[src] ==Usage and examples== Marshalling is used within implementations of different remote procedure call (RPC) mechanisms, where it is necessary to transport data between processes and/or between threads.[src] In Microsoft's Component Object Model (COM), interface pointers must be marshalled when crossing COM apartment boundaries.[src] In the .NET Framework, the conversion between an unmanaged type and a CLR type, as in the P/Invoke process, is also an example of an action that requires marshalling to take place.[src] Additionally, marshalling is used extensively within scripts and applications that use the XPCOM technologies provided within the Mozilla application framework.[src] The Mozilla Firefox browser is a popular application built with this framework, that additionally allows scripting languages to use XPCOM through XPConnect (Cross-Platform Connect).[src] public class Student { private String name; private int id; public String getName() { return this.name; } public int getId() { return this.id; } void setName(String name) { this.name = name; } void setId(int id) { this.id = id; } } XML representation of a specific Student object: Alice Bob Executable representation of that Student object: Student s1 = new Student(); s1.setId(11235813); s1.setName("Alice"); Student s2 = new Student(); s2.setId(21345589); s2.setName("Bob"); Unmarshalling is the process of converting the XML representation to the default executable Java representation, and running that very code to get a consistent, live object back.[src] Had a different format been chosen, the unmarshalling process would have been different, but the end result in the target runtime would be the same.[src] import java.io.File; import jakarta.xml.bind.JAXBContext; import jakarta.xml.bind.Unmarshaller; JAXBContext jcon = JAXBContext.newInstance("com.acme.foo"); Unmarshaller umar = jcon.createUnmarshaller(); Object obj = umar.unmarshal(new File("input.xml"));[src]

14 sentences · 14 cited inline · 0 references stored

References

No reference rows published for this article.

Cite this article

MLA

"Marshalling (computer science)." encyclopegia.org, 2026, https://encyclopegia.org/wiki/marshalling-computer-science. Accessed 26 November 2026.

Chicago

"Marshalling (computer science)." encyclopegia.org. Accessed November 26, 2026. https://encyclopegia.org/wiki/marshalling-computer-science.

APA

encyclopegia.org. (2026). Marshalling (computer science). Retrieved November 26, 2026, from https://encyclopegia.org/wiki/marshalling-computer-science

Accessed November 26, 2026 · CC BY-SA 4.0 · citation page · JSON

Related articles

computer

stub · references available

computer mouse

stub · references available

IBM Personal Computer XT

stub · references available

etymology science

stub · references available

computational science

stub · references available

cognitive science

stub · references available
CC BY-SA 4.0 · share-alike · https://en.wikipedia.org/w/index.php?oldid=1365191168 · 0.5 · snapshot enwiki-001365191168

Cite · JSON · Search

Related services and records

Services

  • Estate — measured countries, lanes and facts
  • Intel — live corroborated events
  • Legal — statutes, cases and citations
  • Encyclopedia — articles with inline sources
  • Space — launches, satellites and orbits
  • Search — federated search and reports
  • Pass — passport account and SSO
  • Corpora — read-only corpus origins
  • e01 — self-hosted corpora and tools

Text and metadata only; each target carries its own sources. Missing data is published as no-data, never estimated.