Object graph: Difference between revisions

Content deleted Content added
m remove Erik9bot category, no longer needed for this article using Project:AWB
No edit summary
Line 2:
{{Inappropriate tone|date=December 2007}}
 
An '''Object Graphgraph''' is a view of an object system at a particular point in time. Whereas a normal [[data model]] such as an [[Uml]] [[Class diagram]] details the relationships between objects, the object graph relates thetheir instances. [[Object diagram|Object diagrams]] are subset of the overall object graph.
Object graph is a term often used with object-oriented applications. Object-oriented applications contain complex webs of interrelated objects. Objects are linked to each other by one object either owning or containing another object or holding a reference to another object. This web of objects is called an object graph and it is the more abstract structure that can be used in discussing an application's state.
 
==Physical representation==
e.g. Instead of a car having a relationship to a wheel, MyCar has four relationships to four different Wheels (FrontLeft, FrontRight, BackLeft, BackRight).
An object graph it's a [[directed graph]], which might be [[Cycle graph|cyclic]]. When stored in [[Random access memory|Ram]], objects occupy different segments of the memory with their attributes and function table, while relationships are represented by [[Pointer_(computing)|pointers]] or a different type of global handlers in higher-level languages.
 
==Examples==
{{Expand|date=March 2007}}
For instance, a Car class can compose a Wheel one. In the object graph a Car instance will have up to four links to its wheels, which can be named frontLeft, frontRight, backLeft and backRight.
Object graph is a term often used with object-oriented applications. Object-oriented applications contain complex webs of interrelated objects. Objects are linked to each other by one object either owning or containing another object or holding a reference to another object. This web of objects is called an object graph.
Example of an [[adjacency list]] representation: c:Car → {frontLeft:Wheel, frontRight:Wheel, backLeft:Wheel, backRight:Wheel}.
 
Example: A → {B, C}, B → {D}, C → {A, D}, D → {B, A}.
 
==See also==
* [[Data model]]
* [[Object diagram]]
 
{{DEFAULTSORT:Object Graph}}