]> git.buserror.net Git - polintos/scott/priv.git/blob - doc/orb/marshalling
Add first draft of marshalling spec
[polintos/scott/priv.git] / doc / orb / marshalling
1 segment 0, byte 0 is a request code.  Codes are:
2  0: Invoke Method
3  1: Get Interface List
4  2: Return Interface List
5
6 Bytes 1-3 (32-bit) and 1-7 (64-bit) are reserved, and must be zero.
7 All offsets described in the rest of this file are relative to the
8 first non-reserved byte (a.k.a. the message payload).  The reserved
9 bytes do not need to be included in the message if the payload is
10 empty.
11
12 Op0: Invoke Method
13 ------------------
14
15 The segment 0 payload contains the method's arguments as if they were
16 a struct, followed by a depth-first traversal of any referenced
17 structs, excluding references which could potentially lead to loops
18 (i.e. references to types that exist in a parent node in the
19 traversal, or their supertypes) or aliases (i.e. references to types
20 that exist elsewhere in the traversal, or their supertypes).  Where
21 loops or aliases are possible, the reference is encoded as a
22 segment/offset pair (a 32-bit word, segment is upper 6 bits), and the
23 data may be placed wherever the sender wishes.  Non-inline arrays are
24 also encoded with segment/offset pairs.  Object references are
25 encoded as 16-bit offsets into the objlist array.
26
27 Op1: Get Interface List
28 -----------------------
29
30 Return a "Return Interface List" message corresponding to the object
31 in objlist[0].  For async requests, objlist[1] is the destination for
32 the return message.
33
34 Op2: Return Interface List
35 --------------------------
36
37 For async requests, objlist[1] is the object whose interfaces were
38 requested.
39
40 The payload consists of a list of GUIDs of interfaces that the object
41 supports.