home *** CD-ROM | disk | FTP | other *** search
open in:
MacOS 8.1
|
Win98
|
DOS
browse contents |
view JSON data
|
view as text
This file was processed as: SHell self-extracting ARchive
(archive/shar).
Confidence | Program | Detection | Match Type | Support
|
---|
100%
| dexvert
| SHell self-extracting ARchive (archive/shar)
| magic
| Supported |
100%
| dexvert
| Texinfo Document (document/texInfo)
| magic
| Supported |
1%
| dexvert
| Texas Instruments Calculator Program (executable/tiCalcProgram)
| magic
| Unsupported |
1%
| dexvert
| Text File (text/txt)
| fallback
| Supported |
100%
| file
| TeX document text
| default
| |
99%
| file
| Lisp/Scheme program, ASCII text
| default
| |
100%
| checkBytes
| Printable ASCII
| default
| |
100%
| perlTextCheck
| Likely Text (Perl)
| default
| |
100%
| siegfried
| fmt/329 Shell Archive Format
| default
| |
100%
| detectItEasy
| Format: plain text[LF]
| default (weak)
|
|
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 4e 65 77 73 67 72 6f 75 | 70 73 3a 20 63 6f 6d 70 |Newsgrou|ps: comp|
|00000010| 2e 73 6f 75 72 63 65 73 | 2e 75 6e 69 78 0a 46 72 |.sources|.unix.Fr|
|00000020| 6f 6d 3a 20 6d 6e 6c 40 | 64 74 72 6f 2e 65 2d 74 |om: mnl@|dtro.e-t|
|00000030| 65 63 68 6e 69 6b 2e 74 | 68 2d 64 61 72 6d 73 74 |echnik.t|h-darmst|
|00000040| 61 64 74 2e 64 65 20 28 | 4d 69 63 68 61 65 6c 20 |adt.de (|Michael |
|00000050| 4c 69 70 70 29 0a 53 75 | 62 6a 65 63 74 3a 20 76 |Lipp).Su|bject: v|
|00000060| 32 36 69 31 38 33 3a 20 | 6d 6e 6c 2d 72 70 63 2b |26i183: |mnl-rpc+|
|00000070| 2b 2d 32 2e 33 2e 31 20 | 2d 20 61 20 43 2b 2b 20 |+-2.3.1 |- a C++ |
|00000080| 69 6e 74 65 72 66 61 63 | 65 20 74 6f 20 53 75 6e |interfac|e to Sun|
|00000090| 20 52 50 43 2c 20 50 61 | 72 74 30 33 2f 30 33 0a | RPC, Pa|rt03/03.|
|000000a0| 53 65 6e 64 65 72 3a 20 | 75 6e 69 78 2d 73 6f 75 |Sender: |unix-sou|
|000000b0| 72 63 65 73 2d 6d 6f 64 | 65 72 61 74 6f 72 40 76 |rces-mod|erator@v|
|000000c0| 69 78 2e 63 6f 6d 0a 41 | 70 70 72 6f 76 65 64 3a |ix.com.A|pproved:|
|000000d0| 20 70 61 75 6c 40 76 69 | 78 2e 63 6f 6d 0a 0a 53 | paul@vi|x.com..S|
|000000e0| 75 62 6d 69 74 74 65 64 | 2d 42 79 3a 20 6d 6e 6c |ubmitted|-By: mnl|
|000000f0| 40 64 74 72 6f 2e 65 2d | 74 65 63 68 6e 69 6b 2e |@dtro.e-|technik.|
|00000100| 74 68 2d 64 61 72 6d 73 | 74 61 64 74 2e 64 65 20 |th-darms|tadt.de |
|00000110| 28 4d 69 63 68 61 65 6c | 20 4c 69 70 70 29 0a 50 |(Michael| Lipp).P|
|00000120| 6f 73 74 69 6e 67 2d 4e | 75 6d 62 65 72 3a 20 56 |osting-N|umber: V|
|00000130| 6f 6c 75 6d 65 20 32 36 | 2c 20 49 73 73 75 65 20 |olume 26|, Issue |
|00000140| 31 38 33 0a 41 72 63 68 | 69 76 65 2d 4e 61 6d 65 |183.Arch|ive-Name|
|00000150| 3a 20 6d 6e 6c 2d 72 70 | 63 2b 2b 2d 32 2e 33 2e |: mnl-rp|c++-2.3.|
|00000160| 31 2f 70 61 72 74 30 33 | 0a 0a 23 21 20 2f 62 69 |1/part03|..#! /bi|
|00000170| 6e 2f 73 68 0a 23 20 54 | 68 69 73 20 69 73 20 61 |n/sh.# T|his is a|
|00000180| 20 73 68 65 6c 6c 20 61 | 72 63 68 69 76 65 2e 20 | shell a|rchive. |
|00000190| 20 52 65 6d 6f 76 65 20 | 61 6e 79 74 68 69 6e 67 | Remove |anything|
|000001a0| 20 62 65 66 6f 72 65 20 | 74 68 69 73 20 6c 69 6e | before |this lin|
|000001b0| 65 2c 20 74 68 65 6e 20 | 75 6e 70 61 63 6b 0a 23 |e, then |unpack.#|
|000001c0| 20 69 74 20 62 79 20 73 | 61 76 69 6e 67 20 69 74 | it by s|aving it|
|000001d0| 20 69 6e 74 6f 20 61 20 | 66 69 6c 65 20 61 6e 64 | into a |file and|
|000001e0| 20 74 79 70 69 6e 67 20 | 22 73 68 20 66 69 6c 65 | typing |"sh file|
|000001f0| 22 2e 20 20 54 6f 20 6f | 76 65 72 77 72 69 74 65 |". To o|verwrite|
|00000200| 20 65 78 69 73 74 69 6e | 67 0a 23 20 66 69 6c 65 | existin|g.# file|
|00000210| 73 2c 20 74 79 70 65 20 | 22 73 68 20 66 69 6c 65 |s, type |"sh file|
|00000220| 20 2d 63 22 2e 20 20 59 | 6f 75 20 63 61 6e 20 61 | -c". Y|ou can a|
|00000230| 6c 73 6f 20 66 65 65 64 | 20 74 68 69 73 20 61 73 |lso feed| this as|
|00000240| 20 73 74 61 6e 64 61 72 | 64 20 69 6e 70 75 74 20 | standar|d input |
|00000250| 76 69 61 0a 23 20 75 6e | 73 68 61 72 2c 20 6f 72 |via.# un|shar, or|
|00000260| 20 62 79 20 74 79 70 69 | 6e 67 20 22 73 68 20 3c | by typi|ng "sh <|
|00000270| 66 69 6c 65 22 2c 20 65 | 2e 67 2e 2e 20 20 49 66 |file", e|.g.. If|
|00000280| 20 74 68 69 73 20 61 72 | 63 68 69 76 65 20 69 73 | this ar|chive is|
|00000290| 20 63 6f 6d 70 6c 65 74 | 65 2c 20 79 6f 75 0a 23 | complet|e, you.#|
|000002a0| 20 77 69 6c 6c 20 73 65 | 65 20 74 68 65 20 66 6f | will se|e the fo|
|000002b0| 6c 6c 6f 77 69 6e 67 20 | 6d 65 73 73 61 67 65 20 |llowing |message |
|000002c0| 61 74 20 74 68 65 20 65 | 6e 64 3a 0a 23 09 09 22 |at the e|nd:.#.."|
|000002d0| 45 6e 64 20 6f 66 20 61 | 72 63 68 69 76 65 20 33 |End of a|rchive 3|
|000002e0| 20 28 6f 66 20 33 29 2e | 22 0a 23 20 43 6f 6e 74 | (of 3).|".# Cont|
|000002f0| 65 6e 74 73 3a 20 20 72 | 70 63 2b 2b 2e 74 65 78 |ents: r|pc++.tex|
|00000300| 69 0a 23 20 57 72 61 70 | 70 65 64 20 62 79 20 76 |i.# Wrap|ped by v|
|00000310| 69 78 69 65 40 67 77 2e | 68 6f 6d 65 2e 76 69 78 |ixie@gw.|home.vix|
|00000320| 2e 63 6f 6d 20 6f 6e 20 | 53 75 6e 20 41 70 72 20 |.com on |Sun Apr |
|00000330| 32 35 20 30 30 3a 34 39 | 3a 34 38 20 31 39 39 33 |25 00:49|:48 1993|
|00000340| 0a 50 41 54 48 3d 2f 62 | 69 6e 3a 2f 75 73 72 2f |.PATH=/b|in:/usr/|
|00000350| 62 69 6e 3a 2f 75 73 72 | 2f 75 63 62 20 3b 20 65 |bin:/usr|/ucb ; e|
|00000360| 78 70 6f 72 74 20 50 41 | 54 48 0a 69 66 20 74 65 |xport PA|TH.if te|
|00000370| 73 74 20 2d 66 20 27 72 | 70 63 2b 2b 2e 74 65 78 |st -f 'r|pc++.tex|
|00000380| 69 27 20 2d 61 20 22 24 | 7b 31 7d 22 20 21 3d 20 |i' -a "$|{1}" != |
|00000390| 22 2d 63 22 20 3b 20 74 | 68 65 6e 20 0a 20 20 65 |"-c" ; t|hen . e|
|000003a0| 63 68 6f 20 73 68 61 72 | 3a 20 57 69 6c 6c 20 6e |cho shar|: Will n|
|000003b0| 6f 74 20 63 6c 6f 62 62 | 65 72 20 65 78 69 73 74 |ot clobb|er exist|
|000003c0| 69 6e 67 20 66 69 6c 65 | 20 5c 22 27 72 70 63 2b |ing file| \"'rpc+|
|000003d0| 2b 2e 74 65 78 69 27 5c | 22 0a 65 6c 73 65 0a 65 |+.texi'\|".else.e|
|000003e0| 63 68 6f 20 73 68 61 72 | 3a 20 45 78 74 72 61 63 |cho shar|: Extrac|
|000003f0| 74 69 6e 67 20 5c 22 27 | 72 70 63 2b 2b 2e 74 65 |ting \"'|rpc++.te|
|00000400| 78 69 27 5c 22 20 5c 28 | 36 35 38 37 35 20 63 68 |xi'\" \(|65875 ch|
|00000410| 61 72 61 63 74 65 72 73 | 5c 29 0a 73 65 64 20 22 |aracters|\).sed "|
|00000420| 73 2f 5e 58 2f 2f 22 20 | 3e 27 72 70 63 2b 2b 2e |s/^X//" |>'rpc++.|
|00000430| 74 65 78 69 27 20 3c 3c | 27 45 4e 44 5f 4f 46 5f |texi' <<|'END_OF_|
|00000440| 46 49 4c 45 27 0a 58 5c | 69 6e 70 75 74 20 74 65 |FILE'.X\|input te|
|00000450| 78 69 6e 66 6f 20 20 20 | 40 63 20 2d 2a 2d 74 65 |xinfo |@c -*-te|
|00000460| 78 69 6e 66 6f 2d 2a 2d | 0a 58 40 74 65 78 0a 58 |xinfo-*-|.X@tex.X|
|00000470| 25 20 54 68 65 79 20 61 | 72 65 20 72 65 64 65 66 |% They a|re redef|
|00000480| 69 6e 65 64 20 69 6e 20 | 74 65 78 69 6e 66 6f 2c |ined in |texinfo,|
|00000490| 20 62 75 74 20 49 20 6e | 65 65 64 20 74 68 65 6d | but I n|eed them|
|000004a0| 0a 58 5c 67 64 65 66 5c | 60 23 31 7b 7b 5c 61 63 |.X\gdef\|`#1{{\ac|
|000004b0| 63 65 6e 74 31 38 20 23 | 31 7d 7d 0a 58 5c 67 64 |cent18 #|1}}.X\gd|
|000004c0| 65 66 5c 27 23 31 7b 7b | 5c 61 63 63 65 6e 74 31 |ef\'#1{{|\accent1|
|000004d0| 39 20 23 31 7d 7d 0a 58 | 5c 67 64 65 66 5c 5b 7b |9 #1}}.X|\gdef\[{|
|000004e0| 7b 5b 7d 7d 0a 58 5c 67 | 64 65 66 5c 5d 7b 7b 5d |{[}}.X\g|def\]{{]|
|000004f0| 7d 7d 0a 58 40 65 6e 64 | 20 74 65 78 0a 58 40 63 |}}.X@end| tex.X@c|
|00000500| 6f 6d 6d 65 6e 74 20 25 | 2a 2a 73 74 61 72 74 20 |omment %|**start |
|00000510| 6f 66 20 68 65 61 64 65 | 72 20 28 54 68 69 73 20 |of heade|r (This |
|00000520| 69 73 20 66 6f 72 20 72 | 75 6e 6e 69 6e 67 20 54 |is for r|unning T|
|00000530| 65 78 69 6e 66 6f 20 6f | 6e 20 61 20 72 65 67 69 |exinfo o|n a regi|
|00000540| 6f 6e 2e 29 0a 58 40 73 | 65 74 66 69 6c 65 6e 61 |on.).X@s|etfilena|
|00000550| 6d 65 20 72 70 63 2b 2b | 2e 69 6e 66 6f 0a 58 40 |me rpc++|.info.X@|
|00000560| 73 65 74 74 69 74 6c 65 | 20 41 20 43 2b 2b 20 49 |settitle| A C++ I|
|00000570| 6e 74 65 72 66 61 63 65 | 20 74 6f 20 52 65 6d 6f |nterface| to Remo|
|00000580| 74 65 20 50 72 6f 63 65 | 64 75 72 65 20 43 61 6c |te Proce|dure Cal|
|00000590| 6c 73 0a 58 40 73 65 74 | 63 68 61 70 74 65 72 6e |ls.X@set|chaptern|
|000005a0| 65 77 70 61 67 65 20 6f | 6e 0a 58 40 63 6f 6d 6d |ewpage o|n.X@comm|
|000005b0| 65 6e 74 20 25 2a 2a 65 | 6e 64 20 6f 66 20 68 65 |ent %**e|nd of he|
|000005c0| 61 64 65 72 20 28 54 68 | 69 73 20 69 73 20 66 6f |ader (Th|is is fo|
|000005d0| 72 20 72 75 6e 6e 69 6e | 67 20 54 65 78 69 6e 66 |r runnin|g Texinf|
|000005e0| 6f 20 6f 6e 20 61 20 72 | 65 67 69 6f 6e 2e 29 0a |o on a r|egion.).|
|000005f0| 58 0a 58 40 63 20 59 6f | 75 27 6c 6c 20 68 61 76 |X.X@c Yo|u'll hav|
|00000600| 65 20 74 6f 20 64 65 66 | 69 6e 65 20 74 68 65 20 |e to def|ine the |
|00000610| 66 6f 6c 6c 6f 77 69 6e | 67 20 61 64 64 69 74 69 |followin|g additi|
|00000620| 6f 6e 61 6c 20 74 65 78 | 69 6e 66 6f 2d 66 6f 72 |onal tex|info-for|
|00000630| 6d 61 74 73 20 74 6f 0a | 58 40 63 20 72 75 6e 20 |mats to.|X@c run |
|00000640| 74 65 78 69 6e 66 6f 20 | 6f 6e 20 74 68 69 73 20 |texinfo |on this |
|00000650| 66 69 6c 65 2e 0a 58 40 | 63 0a 58 40 63 20 20 20 |file..X@|c.X@c |
|00000660| 28 70 75 74 20 27 5c 26 | 20 27 74 65 78 69 6e 66 |(put '\&| 'texinf|
|00000670| 6f 2d 66 6f 72 6d 61 74 | 20 27 74 65 78 69 6e 66 |o-format| 'texinf|
|00000680| 6f 2d 66 6f 72 6d 61 74 | 2d 5c 26 29 0a 58 40 63 |o-format|-\&).X@c|
|00000690| 20 20 20 28 64 65 66 75 | 6e 20 74 65 78 69 6e 66 | (defu|n texinf|
|000006a0| 6f 2d 66 6f 72 6d 61 74 | 2d 5c 26 20 28 29 0a 58 |o-format|-\& ().X|
|000006b0| 40 63 20 20 20 20 20 28 | 74 65 78 69 6e 66 6f 2d |@c (|texinfo-|
|000006c0| 64 69 73 63 61 72 64 2d | 63 6f 6d 6d 61 6e 64 29 |discard-|command)|
|000006d0| 0a 58 40 63 20 20 20 20 | 20 28 69 6e 73 65 72 74 |.X@c | (insert|
|000006e0| 20 22 26 22 29 29 0a 58 | 40 63 0a 58 40 63 20 20 | "&")).X|@c.X@c |
|000006f0| 20 28 70 75 74 20 27 5c | 5b 20 27 74 65 78 69 6e | (put '\|[ 'texin|
|00000700| 66 6f 2d 66 6f 72 6d 61 | 74 20 27 74 65 78 69 6e |fo-forma|t 'texin|
|00000710| 66 6f 2d 66 6f 72 6d 61 | 74 2d 5c 5b 29 0a 58 40 |fo-forma|t-\[).X@|
|00000720| 63 20 20 20 28 64 65 66 | 75 6e 20 74 65 78 69 6e |c (def|un texin|
|00000730| 66 6f 2d 66 6f 72 6d 61 | 74 2d 5c 5b 20 28 29 0a |fo-forma|t-\[ ().|
|00000740| 58 40 63 20 20 20 20 20 | 28 74 65 78 69 6e 66 6f |X@c |(texinfo|
|00000750| 2d 64 69 73 63 61 72 64 | 2d 63 6f 6d 6d 61 6e 64 |-discard|-command|
|00000760| 29 0a 58 40 63 20 20 20 | 20 20 28 69 6e 73 65 72 |).X@c | (inser|
|00000770| 74 20 22 5b 22 29 29 0a | 58 40 63 0a 58 40 63 20 |t "[")).|X@c.X@c |
|00000780| 20 20 28 70 75 74 20 27 | 5c 5d 20 27 74 65 78 69 | (put '|\] 'texi|
|00000790| 6e 66 6f 2d 66 6f 72 6d | 61 74 20 27 74 65 78 69 |nfo-form|at 'texi|
|000007a0| 6e 66 6f 2d 66 6f 72 6d | 61 74 2d 5c 5d 29 0a 58 |nfo-form|at-\]).X|
|000007b0| 40 63 20 20 20 28 64 65 | 66 75 6e 20 74 65 78 69 |@c (de|fun texi|
|000007c0| 6e 66 6f 2d 66 6f 72 6d | 61 74 2d 5c 5d 20 28 29 |nfo-form|at-\] ()|
|000007d0| 0a 58 40 63 20 20 20 20 | 20 28 74 65 78 69 6e 66 |.X@c | (texinf|
|000007e0| 6f 2d 64 69 73 63 61 72 | 64 2d 63 6f 6d 6d 61 6e |o-discar|d-comman|
|000007f0| 64 29 0a 58 40 63 20 20 | 20 20 20 28 69 6e 73 65 |d).X@c | (inse|
|00000800| 72 74 20 22 5d 22 29 29 | 0a 58 0a 58 40 69 66 69 |rt "]"))|.X.X@ifi|
|00000810| 6e 66 6f 0a 54 68 69 73 | 20 66 69 6c 65 20 64 6f |nfo.This| file do|
|00000820| 63 75 6d 65 6e 74 73 20 | 61 20 43 2b 2b 20 69 6e |cuments |a C++ in|
|00000830| 74 65 72 66 61 63 65 20 | 74 6f 20 53 75 6e 20 72 |terface |to Sun r|
|00000840| 65 6d 6f 74 65 20 70 72 | 6f 63 65 64 75 72 65 20 |emote pr|ocedure |
|00000850| 63 61 6c 6c 73 2e 0a 58 | 0a 43 6f 70 79 72 69 67 |calls..X|.Copyrig|
|00000860| 68 74 20 40 63 6f 70 79 | 72 69 67 68 74 7b 7d 20 |ht @copy|right{} |
|00000870| 31 39 39 32 20 4d 69 63 | 68 61 65 6c 20 4e 2e 20 |1992 Mic|hael N. |
|00000880| 4c 69 70 70 0a 50 65 72 | 6d 69 73 73 69 6f 6e 20 |Lipp.Per|mission |
|00000890| 69 73 20 67 72 61 6e 74 | 65 64 20 74 6f 20 6d 61 |is grant|ed to ma|
|000008a0| 6b 65 20 61 6e 64 20 64 | 69 73 74 72 69 62 75 74 |ke and d|istribut|
|000008b0| 65 20 76 65 72 62 61 74 | 69 6d 20 63 6f 70 69 65 |e verbat|im copie|
|000008c0| 73 20 6f 66 0a 74 68 69 | 73 20 6d 61 6e 75 61 6c |s of.thi|s manual|
|000008d0| 20 70 72 6f 76 69 64 65 | 64 20 74 68 65 20 63 6f | provide|d the co|
|000008e0| 70 79 72 69 67 68 74 20 | 6e 6f 74 69 63 65 20 61 |pyright |notice a|
|000008f0| 6e 64 20 74 68 69 73 20 | 70 65 72 6d 69 73 73 69 |nd this |permissi|
|00000900| 6f 6e 20 6e 6f 74 69 63 | 65 0a 61 72 65 20 70 72 |on notic|e.are pr|
|00000910| 65 73 65 72 76 65 64 20 | 6f 6e 20 61 6c 6c 20 63 |eserved |on all c|
|00000920| 6f 70 69 65 73 2e 0a 58 | 0a 58 40 69 67 6e 6f 72 |opies..X|.X@ignor|
|00000930| 65 0a 50 65 72 6d 69 73 | 73 69 6f 6e 20 69 73 20 |e.Permis|sion is |
|00000940| 67 72 61 6e 74 65 64 20 | 74 6f 20 70 72 6f 63 65 |granted |to proce|
|00000950| 73 73 20 74 68 69 73 20 | 66 69 6c 65 20 74 68 72 |ss this |file thr|
|00000960| 6f 75 67 68 20 40 54 65 | 58 7b 7d 20 61 6e 64 20 |ough @Te|X{} and |
|00000970| 70 72 69 6e 74 20 74 68 | 65 0a 72 65 73 75 6c 74 |print th|e.result|
|00000980| 73 2c 20 70 72 6f 76 69 | 64 65 64 20 74 68 65 20 |s, provi|ded the |
|00000990| 70 72 69 6e 74 65 64 20 | 64 6f 63 75 6d 65 6e 74 |printed |document|
|000009a0| 20 63 61 72 72 69 65 73 | 20 63 6f 70 79 69 6e 67 | carries| copying|
|000009b0| 20 70 65 72 6d 69 73 73 | 69 6f 6e 0a 6e 6f 74 69 | permiss|ion.noti|
|000009c0| 63 65 20 69 64 65 6e 74 | 69 63 61 6c 20 74 6f 20 |ce ident|ical to |
|000009d0| 74 68 69 73 20 6f 6e 65 | 20 65 78 63 65 70 74 20 |this one| except |
|000009e0| 66 6f 72 20 74 68 65 20 | 72 65 6d 6f 76 61 6c 20 |for the |removal |
|000009f0| 6f 66 20 74 68 69 73 20 | 70 61 72 61 67 72 61 70 |of this |paragrap|
|00000a00| 68 0a 58 28 74 68 69 73 | 20 70 61 72 61 67 72 61 |h.X(this| paragra|
|00000a10| 70 68 20 6e 6f 74 20 62 | 65 69 6e 67 20 72 65 6c |ph not b|eing rel|
|00000a20| 65 76 61 6e 74 20 74 6f | 20 74 68 65 20 70 72 69 |evant to| the pri|
|00000a30| 6e 74 65 64 20 6d 61 6e | 75 61 6c 29 2e 0a 58 0a |nted man|ual)..X.|
|00000a40| 58 40 65 6e 64 20 69 67 | 6e 6f 72 65 0a 50 65 72 |X@end ig|nore.Per|
|00000a50| 6d 69 73 73 69 6f 6e 20 | 69 73 20 67 72 61 6e 74 |mission |is grant|
|00000a60| 65 64 20 74 6f 20 63 6f | 70 79 20 61 6e 64 20 64 |ed to co|py and d|
|00000a70| 69 73 74 72 69 62 75 74 | 65 20 6d 6f 64 69 66 69 |istribut|e modifi|
|00000a80| 65 64 20 76 65 72 73 69 | 6f 6e 73 20 6f 66 20 74 |ed versi|ons of t|
|00000a90| 68 69 73 0a 6d 61 6e 75 | 61 6c 20 75 6e 64 65 72 |his.manu|al under|
|00000aa0| 20 74 68 65 20 63 6f 6e | 64 69 74 69 6f 6e 73 20 | the con|ditions |
|00000ab0| 66 6f 72 20 76 65 72 62 | 61 74 69 6d 20 63 6f 70 |for verb|atim cop|
|00000ac0| 79 69 6e 67 2c 20 70 72 | 6f 76 69 64 65 64 20 61 |ying, pr|ovided a|
|00000ad0| 6c 73 6f 20 74 68 61 74 | 20 74 68 65 0a 73 65 63 |lso that| the.sec|
|00000ae0| 74 69 6f 6e 20 65 6e 74 | 69 74 6c 65 64 20 60 60 |tion ent|itled ``|
|00000af0| 47 4e 55 20 4c 69 62 72 | 61 72 79 20 47 65 6e 65 |GNU Libr|ary Gene|
|00000b00| 72 61 6c 20 50 75 62 6c | 69 63 20 4c 69 63 65 6e |ral Publ|ic Licen|
|00000b10| 73 65 27 27 20 69 73 20 | 69 6e 63 6c 75 64 65 64 |se'' is |included|
|00000b20| 20 65 78 61 63 74 6c 79 | 20 61 73 0a 69 6e 20 74 | exactly| as.in t|
|00000b30| 68 65 20 6f 72 69 67 69 | 6e 61 6c 2c 20 61 6e 64 |he origi|nal, and|
|00000b40| 20 70 72 6f 76 69 64 65 | 64 20 74 68 61 74 20 74 | provide|d that t|
|00000b50| 68 65 20 65 6e 74 69 72 | 65 20 72 65 73 75 6c 74 |he entir|e result|
|00000b60| 69 6e 67 20 64 65 72 69 | 76 65 64 20 77 6f 72 6b |ing deri|ved work|
|00000b70| 20 69 73 0a 64 69 73 74 | 72 69 62 75 74 65 64 20 | is.dist|ributed |
|00000b80| 75 6e 64 65 72 20 74 68 | 65 20 74 65 72 6d 73 20 |under th|e terms |
|00000b90| 6f 66 20 61 20 70 65 72 | 6d 69 73 73 69 6f 6e 20 |of a per|mission |
|00000ba0| 6e 6f 74 69 63 65 20 69 | 64 65 6e 74 69 63 61 6c |notice i|dentical|
|00000bb0| 20 74 6f 20 74 68 69 73 | 20 6f 6e 65 2e 0a 58 0a | to this| one..X.|
|00000bc0| 50 65 72 6d 69 73 73 69 | 6f 6e 20 69 73 20 67 72 |Permissi|on is gr|
|00000bd0| 61 6e 74 65 64 20 74 6f | 20 63 6f 70 79 20 61 6e |anted to| copy an|
|00000be0| 64 20 64 69 73 74 72 69 | 62 75 74 65 20 74 72 61 |d distri|bute tra|
|00000bf0| 6e 73 6c 61 74 69 6f 6e | 73 20 6f 66 20 74 68 69 |nslation|s of thi|
|00000c00| 73 20 6d 61 6e 75 61 6c | 0a 69 6e 74 6f 20 61 6e |s manual|.into an|
|00000c10| 6f 74 68 65 72 20 6c 61 | 6e 67 75 61 67 65 2c 20 |other la|nguage, |
|00000c20| 75 6e 64 65 72 20 74 68 | 65 20 61 62 6f 76 65 20 |under th|e above |
|00000c30| 63 6f 6e 64 69 74 69 6f | 6e 73 20 66 6f 72 20 6d |conditio|ns for m|
|00000c40| 6f 64 69 66 69 65 64 20 | 76 65 72 73 69 6f 6e 73 |odified |versions|
|00000c50| 2c 0a 65 78 63 65 70 74 | 20 74 68 61 74 20 74 68 |,.except| that th|
|00000c60| 65 20 73 65 63 74 69 6f | 6e 20 65 6e 74 69 74 6c |e sectio|n entitl|
|00000c70| 65 64 20 60 60 47 4e 55 | 20 4c 69 62 72 61 72 79 |ed ``GNU| Library|
|00000c80| 20 47 65 6e 65 72 61 6c | 20 50 75 62 6c 69 63 20 | General| Public |
|00000c90| 4c 69 63 65 6e 73 65 27 | 27 20 61 6e 64 0a 74 68 |License'|' and.th|
|00000ca0| 69 73 20 70 65 72 6d 69 | 73 73 69 6f 6e 20 6e 6f |is permi|ssion no|
|00000cb0| 74 69 63 65 20 6d 61 79 | 20 62 65 20 69 6e 63 6c |tice may| be incl|
|00000cc0| 75 64 65 64 20 69 6e 20 | 74 72 61 6e 73 6c 61 74 |uded in |translat|
|00000cd0| 69 6f 6e 73 20 61 70 70 | 72 6f 76 65 64 20 62 79 |ions app|roved by|
|00000ce0| 20 74 68 65 0a 58 46 72 | 65 65 20 53 6f 66 74 77 | the.XFr|ee Softw|
|00000cf0| 61 72 65 20 46 6f 75 6e | 64 61 74 69 6f 6e 20 69 |are Foun|dation i|
|00000d00| 6e 73 74 65 61 64 20 6f | 66 20 69 6e 20 74 68 65 |nstead o|f in the|
|00000d10| 20 6f 72 69 67 69 6e 61 | 6c 20 45 6e 67 6c 69 73 | origina|l Englis|
|00000d20| 68 2e 0a 58 40 65 6e 64 | 20 69 66 69 6e 66 6f 0a |h..X@end| ifinfo.|
|00000d30| 58 0a 58 40 74 69 74 6c | 65 70 61 67 65 0a 58 0a |X.X@titl|epage.X.|
|00000d40| 58 40 74 69 74 6c 65 20 | 41 20 43 2b 2b 20 49 6e |X@title |A C++ In|
|00000d50| 74 65 72 66 61 63 65 0a | 58 40 74 69 74 6c 65 20 |terface.|X@title |
|00000d60| 74 6f 20 53 75 6e 20 52 | 65 6d 6f 74 65 20 50 72 |to Sun R|emote Pr|
|00000d70| 6f 63 65 64 75 72 65 20 | 43 61 6c 6c 73 0a 58 40 |ocedure |Calls.X@|
|00000d80| 73 70 20 31 0a 58 40 73 | 75 62 74 69 74 6c 65 20 |sp 1.X@s|ubtitle |
|00000d90| 40 61 75 74 68 6f 72 66 | 6f 6e 74 7b 62 79 20 4d |@authorf|ont{by M|
|00000da0| 69 63 68 61 65 6c 20 4e | 2e 20 4c 69 70 70 7d 0a |ichael N|. Lipp}.|
|00000db0| 58 40 73 70 20 32 30 0a | 58 40 73 75 62 74 69 74 |X@sp 20.|X@subtit|
|00000dc0| 6c 65 7b 66 6f 72 20 76 | 65 72 73 69 6f 6e 20 32 |le{for v|ersion 2|
|00000dd0| 2e 32 7d 0a 58 40 73 75 | 62 74 69 74 6c 65 7b 54 |.2}.X@su|btitle{T|
|00000de0| 65 63 68 6e 69 73 63 68 | 65 20 48 6f 63 68 73 63 |echnisch|e Hochsc|
|00000df0| 68 75 6c 65 20 44 61 72 | 6d 73 74 61 64 74 2c 20 |hule Dar|mstadt, |
|00000e00| 49 6e 73 74 69 74 75 74 | 20 66 40 22 75 72 20 44 |Institut| f@"ur D|
|00000e10| 61 74 65 6e 74 65 63 68 | 6e 69 6b 7d 0a 58 0a 58 |atentech|nik}.X.X|
|00000e20| 40 63 6f 6d 6d 65 6e 74 | 20 20 54 68 65 20 66 6f |@comment| The fo|
|00000e30| 6c 6c 6f 77 69 6e 67 20 | 74 77 6f 20 63 6f 6d 6d |llowing |two comm|
|00000e40| 61 6e 64 73 20 73 74 61 | 72 74 20 74 68 65 20 63 |ands sta|rt the c|
|00000e50| 6f 70 79 72 69 67 68 74 | 20 70 61 67 65 2e 0a 58 |opyright| page..X|
|00000e60| 40 70 61 67 65 0a 58 40 | 76 73 6b 69 70 20 30 70 |@page.X@|vskip 0p|
|00000e70| 74 20 70 6c 75 73 20 31 | 66 69 6c 6c 6c 0a 43 6f |t plus 1|filll.Co|
|00000e80| 70 79 72 69 67 68 74 20 | 40 63 6f 70 79 72 69 67 |pyright |@copyrig|
|00000e90| 68 74 7b 7d 20 31 39 39 | 32 20 4d 69 63 68 61 65 |ht{} 199|2 Michae|
|00000ea0| 6c 20 4e 2e 20 4c 69 70 | 70 0a 58 0a 50 65 72 6d |l N. Lip|p.X.Perm|
|00000eb0| 69 73 73 69 6f 6e 20 69 | 73 20 67 72 61 6e 74 65 |ission i|s grante|
|00000ec0| 64 20 74 6f 20 6d 61 6b | 65 20 61 6e 64 20 64 69 |d to mak|e and di|
|00000ed0| 73 74 72 69 62 75 74 65 | 20 76 65 72 62 61 74 69 |stribute| verbati|
|00000ee0| 6d 20 63 6f 70 69 65 73 | 20 6f 66 0a 74 68 69 73 |m copies| of.this|
|00000ef0| 20 6d 61 6e 75 61 6c 20 | 70 72 6f 76 69 64 65 64 | manual |provided|
|00000f00| 20 74 68 65 20 63 6f 70 | 79 72 69 67 68 74 20 6e | the cop|yright n|
|00000f10| 6f 74 69 63 65 20 61 6e | 64 20 74 68 69 73 20 70 |otice an|d this p|
|00000f20| 65 72 6d 69 73 73 69 6f | 6e 20 6e 6f 74 69 63 65 |ermissio|n notice|
|00000f30| 0a 61 72 65 20 70 72 65 | 73 65 72 76 65 64 20 6f |.are pre|served o|
|00000f40| 6e 20 61 6c 6c 20 63 6f | 70 69 65 73 2e 0a 58 0a |n all co|pies..X.|
|00000f50| 50 65 72 6d 69 73 73 69 | 6f 6e 20 69 73 20 67 72 |Permissi|on is gr|
|00000f60| 61 6e 74 65 64 20 74 6f | 20 63 6f 70 79 20 61 6e |anted to| copy an|
|00000f70| 64 20 64 69 73 74 72 69 | 62 75 74 65 20 6d 6f 64 |d distri|bute mod|
|00000f80| 69 66 69 65 64 20 76 65 | 72 73 69 6f 6e 73 20 6f |ified ve|rsions o|
|00000f90| 66 20 74 68 69 73 0a 6d | 61 6e 75 61 6c 20 75 6e |f this.m|anual un|
|00000fa0| 64 65 72 20 74 68 65 20 | 63 6f 6e 64 69 74 69 6f |der the |conditio|
|00000fb0| 6e 73 20 66 6f 72 20 76 | 65 72 62 61 74 69 6d 20 |ns for v|erbatim |
|00000fc0| 63 6f 70 79 69 6e 67 2c | 20 70 72 6f 76 69 64 65 |copying,| provide|
|00000fd0| 64 20 61 6c 73 6f 20 74 | 68 61 74 20 74 68 65 0a |d also t|hat the.|
|00000fe0| 73 65 63 74 69 6f 6e 20 | 65 6e 74 69 74 6c 65 64 |section |entitled|
|00000ff0| 20 60 60 47 4e 55 20 4c | 69 62 72 61 72 79 20 47 | ``GNU L|ibrary G|
|00001000| 65 6e 65 72 61 6c 20 50 | 75 62 6c 69 63 20 4c 69 |eneral P|ublic Li|
|00001010| 63 65 6e 73 65 27 27 20 | 69 73 20 69 6e 63 6c 75 |cense'' |is inclu|
|00001020| 64 65 64 20 65 78 61 63 | 74 6c 79 20 61 73 0a 69 |ded exac|tly as.i|
|00001030| 6e 20 74 68 65 20 6f 72 | 69 67 69 6e 61 6c 2c 20 |n the or|iginal, |
|00001040| 61 6e 64 20 70 72 6f 76 | 69 64 65 64 20 74 68 61 |and prov|ided tha|
|00001050| 74 20 74 68 65 20 65 6e | 74 69 72 65 20 72 65 73 |t the en|tire res|
|00001060| 75 6c 74 69 6e 67 20 64 | 65 72 69 76 65 64 20 77 |ulting d|erived w|
|00001070| 6f 72 6b 20 69 73 0a 64 | 69 73 74 72 69 62 75 74 |ork is.d|istribut|
|00001080| 65 64 20 75 6e 64 65 72 | 20 74 68 65 20 74 65 72 |ed under| the ter|
|00001090| 6d 73 20 6f 66 20 61 20 | 70 65 72 6d 69 73 73 69 |ms of a |permissi|
|000010a0| 6f 6e 20 6e 6f 74 69 63 | 65 20 69 64 65 6e 74 69 |on notic|e identi|
|000010b0| 63 61 6c 20 74 6f 20 74 | 68 69 73 20 6f 6e 65 2e |cal to t|his one.|
|000010c0| 0a 58 0a 50 65 72 6d 69 | 73 73 69 6f 6e 20 69 73 |.X.Permi|ssion is|
|000010d0| 20 67 72 61 6e 74 65 64 | 20 74 6f 20 63 6f 70 79 | granted| to copy|
|000010e0| 20 61 6e 64 20 64 69 73 | 74 72 69 62 75 74 65 20 | and dis|tribute |
|000010f0| 74 72 61 6e 73 6c 61 74 | 69 6f 6e 73 20 6f 66 20 |translat|ions of |
|00001100| 74 68 69 73 20 6d 61 6e | 75 61 6c 0a 69 6e 74 6f |this man|ual.into|
|00001110| 20 61 6e 6f 74 68 65 72 | 20 6c 61 6e 67 75 61 67 | another| languag|
|00001120| 65 2c 20 75 6e 64 65 72 | 20 74 68 65 20 61 62 6f |e, under| the abo|
|00001130| 76 65 20 63 6f 6e 64 69 | 74 69 6f 6e 73 20 66 6f |ve condi|tions fo|
|00001140| 72 20 6d 6f 64 69 66 69 | 65 64 20 76 65 72 73 69 |r modifi|ed versi|
|00001150| 6f 6e 73 2c 0a 65 78 63 | 65 70 74 20 74 68 61 74 |ons,.exc|ept that|
|00001160| 20 74 68 65 20 73 65 63 | 74 69 6f 6e 20 65 6e 74 | the sec|tion ent|
|00001170| 69 74 6c 65 64 20 60 60 | 47 4e 55 20 4c 69 62 72 |itled ``|GNU Libr|
|00001180| 61 72 79 20 47 65 6e 65 | 72 61 6c 20 50 75 62 6c |ary Gene|ral Publ|
|00001190| 69 63 20 4c 69 63 65 6e | 73 65 27 27 20 6d 61 79 |ic Licen|se'' may|
|000011a0| 20 62 65 0a 69 6e 63 6c | 75 64 65 64 20 69 6e 20 | be.incl|uded in |
|000011b0| 61 20 74 72 61 6e 73 6c | 61 74 69 6f 6e 20 61 70 |a transl|ation ap|
|000011c0| 70 72 6f 76 65 64 20 62 | 79 20 74 68 65 20 61 75 |proved b|y the au|
|000011d0| 74 68 6f 72 20 69 6e 73 | 74 65 61 64 20 6f 66 20 |thor ins|tead of |
|000011e0| 69 6e 20 74 68 65 20 6f | 72 69 67 69 6e 61 6c 0a |in the o|riginal.|
|000011f0| 58 45 6e 67 6c 69 73 68 | 2e 0a 58 40 65 6e 64 20 |XEnglish|..X@end |
|00001200| 74 69 74 6c 65 70 61 67 | 65 0a 58 0a 58 40 6e 6f |titlepag|e.X.X@no|
|00001210| 64 65 20 54 6f 70 2c 20 | 4f 76 65 72 76 69 65 77 |de Top, |Overview|
|00001220| 2c 20 28 64 69 72 29 2c | 20 28 64 69 72 29 0a 58 |, (dir),| (dir).X|
|00001230| 0a 58 40 6d 65 6e 75 0a | 58 2a 20 4f 76 65 72 76 |.X@menu.|X* Overv|
|00001240| 69 65 77 3a 3a 20 20 20 | 20 20 20 20 20 20 20 20 |iew:: | |
|00001250| 20 20 20 20 20 20 20 20 | 20 4f 76 65 72 76 69 65 | | Overvie|
|00001260| 77 0a 58 2a 20 49 6e 73 | 74 61 6c 6c 61 74 69 6f |w.X* Ins|tallatio|
|00001270| 6e 3a 3a 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |n:: | |
|00001280| 20 20 20 49 6e 73 74 61 | 6c 6c 61 74 69 6f 6e 0a | Insta|llation.|
|00001290| 58 2a 20 43 6c 61 73 73 | 65 73 3a 3a 20 20 20 20 |X* Class|es:: |
|000012a0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|000012b0| 20 54 68 65 20 43 6c 61 | 73 73 65 73 0a 58 2a 20 | The Cla|sses.X* |
|000012c0| 43 61 76 65 61 74 73 3a | 3a 20 20 20 20 20 20 20 |Caveats:|: |
|000012d0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 43 61 | | Ca|
|000012e0| 76 65 61 74 73 0a 58 2a | 20 52 65 66 65 72 65 6e |veats.X*| Referen|
|000012f0| 63 65 73 3a 3a 20 20 20 | 20 20 20 20 20 20 20 20 |ces:: | |
|00001300| 20 20 20 20 20 20 20 52 | 65 66 65 72 65 6e 63 65 | R|eference|
|00001310| 73 0a 58 2a 20 43 6f 70 | 79 69 6e 67 3a 3a 20 20 |s.X* Cop|ying:: |
|00001320| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00001330| 20 20 20 47 4e 55 20 4c | 49 42 52 41 52 59 20 47 | GNU L|IBRARY G|
|00001340| 45 4e 45 52 41 4c 20 50 | 55 42 4c 49 43 20 4c 49 |ENERAL P|UBLIC LI|
|00001350| 43 45 4e 53 45 0a 58 2a | 20 44 61 74 61 20 54 79 |CENSE.X*| Data Ty|
|00001360| 70 65 20 49 6e 64 65 78 | 3a 3a 20 20 20 20 20 20 |pe Index|:: |
|00001370| 20 20 20 20 20 20 20 44 | 61 74 61 20 54 79 70 65 | D|ata Type|
|00001380| 20 49 6e 64 65 78 0a 58 | 2a 20 46 75 6e 63 74 69 | Index.X|* Functi|
|00001390| 6f 6e 20 49 6e 64 65 78 | 3a 3a 20 20 20 20 20 20 |on Index|:: |
|000013a0| 20 20 20 20 20 20 20 20 | 46 75 6e 63 74 69 6f 6e | |Function|
|000013b0| 20 61 6e 64 20 4d 65 74 | 68 6f 64 20 49 6e 64 65 | and Met|hod Inde|
|000013c0| 78 0a 58 2a 20 43 6f 6e | 63 65 70 74 20 49 6e 64 |x.X* Con|cept Ind|
|000013d0| 65 78 3a 3a 20 20 20 20 | 20 20 20 20 20 20 20 20 |ex:: | |
|000013e0| 20 20 20 43 6f 6e 63 65 | 70 74 20 49 6e 64 65 78 | Conce|pt Index|
|000013f0| 0a 58 0a 58 20 2d 2d 2d | 20 54 68 65 20 44 65 74 |.X.X ---| The Det|
|00001400| 61 69 6c 65 64 20 4e 6f | 64 65 20 4c 69 73 74 69 |ailed No|de Listi|
|00001410| 6e 67 20 2d 2d 2d 0a 58 | 0a 54 68 65 20 63 6c 61 |ng ---.X|.The cla|
|00001420| 73 73 65 73 0a 58 0a 58 | 2a 20 58 64 72 49 6e 66 |sses.X.X|* XdrInf|
|00001430| 6f 3a 3a 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |o:: | |
|00001440| 20 20 20 20 20 20 20 20 | 40 63 6f 64 65 7b 58 64 | |@code{Xd|
|00001450| 72 49 6e 66 6f 7d 0a 58 | 2a 20 52 70 63 52 65 71 |rInfo}.X|* RpcReq|
|00001460| 75 65 73 74 3a 3a 20 20 | 20 20 20 20 20 20 20 20 |uest:: | |
|00001470| 20 20 20 20 20 20 20 20 | 40 63 6f 64 65 7b 52 70 | |@code{Rp|
|00001480| 63 52 65 71 75 65 73 74 | 7d 0a 58 2a 20 43 61 6c |cRequest|}.X* Cal|
|00001490| 6c 62 61 63 6b 73 3a 3a | 20 20 20 20 20 20 20 20 |lbacks::| |
|000014a0| 20 20 20 20 20 20 20 20 | 20 20 20 40 63 6f 64 65 | | @code|
|000014b0| 7b 43 61 6c 6c 62 61 63 | 6b 73 7d 0a 58 2a 20 52 |{Callbac|ks}.X* R|
|000014c0| 70 63 53 65 72 76 69 63 | 65 3a 3a 20 20 20 20 20 |pcServic|e:: |
|000014d0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 40 63 6f | | @co|
|000014e0| 64 65 7b 52 70 63 53 65 | 72 76 69 63 65 7d 0a 58 |de{RpcSe|rvice}.X|
|000014f0| 2a 20 52 70 63 53 74 75 | 62 3a 3a 20 20 20 20 20 |* RpcStu|b:: |
|00001500| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00001510| 40 63 6f 64 65 7b 52 70 | 63 53 74 75 62 7d 0a 58 |@code{Rp|cStub}.X|
|00001520| 0a 43 61 6c 6c 62 61 63 | 6b 73 0a 58 0a 58 2a 20 |.Callbac|ks.X.X* |
|00001530| 52 70 63 43 61 6c 6c 62 | 61 63 6b 3a 3a 20 20 20 |RpcCallb|ack:: |
|00001540| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 40 63 | | @c|
|00001550| 6f 64 65 7b 52 70 63 43 | 61 6c 6c 62 61 63 6b 7d |ode{RpcC|allback}|
|00001560| 0a 58 2a 20 52 70 63 4d | 65 74 68 6f 64 43 61 6c |.X* RpcM|ethodCal|
|00001570| 6c 3a 3a 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |l:: | |
|00001580| 20 20 40 63 6f 64 65 7b | 52 70 63 4d 65 74 68 6f | @code{|RpcMetho|
|00001590| 64 43 61 6c 6c 7d 0a 58 | 2a 20 43 61 6c 6c 69 6e |dCall}.X|* Callin|
|000015a0| 67 20 43 6f 6e 76 65 6e | 74 69 6f 6e 73 3a 3a 20 |g Conven|tions:: |
|000015b0| 20 20 20 20 20 20 20 20 | 40 63 6f 64 65 7b 43 61 | |@code{Ca|
|000015c0| 6c 6c 69 6e 67 20 43 6f | 6e 76 65 6e 74 69 6f 6e |lling Co|nvention|
|000015d0| 73 7d 0a 58 0a 43 61 76 | 65 61 74 73 0a 58 0a 58 |s}.X.Cav|eats.X.X|
|000015e0| 2a 20 47 6c 6f 62 61 6c | 20 6f 62 6a 65 63 74 73 |* Global| objects|
|000015f0| 3a 3a 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |:: | |
|00001600| 47 6c 6f 62 61 6c 20 6f | 62 6a 65 63 74 73 0a 58 |Global o|bjects.X|
|00001610| 2a 20 44 65 73 74 72 75 | 63 74 69 6f 6e 20 72 75 |* Destru|ction ru|
|00001620| 6c 65 73 3a 3a 20 20 20 | 20 20 20 20 20 20 20 20 |les:: | |
|00001630| 44 65 73 74 72 75 63 74 | 69 6f 6e 20 72 75 6c 65 |Destruct|ion rule|
|00001640| 73 0a 58 2a 20 4d 61 74 | 63 68 69 6e 67 20 73 65 |s.X* Mat|ching se|
|00001650| 72 76 65 72 20 61 6e 64 | 20 63 6c 69 65 6e 74 73 |rver and| clients|
|00001660| 3a 3a 20 20 4d 61 74 63 | 68 69 6e 67 20 73 65 72 |:: Matc|hing ser|
|00001670| 76 65 72 20 61 6e 64 20 | 63 6c 69 65 6e 74 73 0a |ver and |clients.|
|00001680| 58 40 65 6e 64 20 6d 65 | 6e 75 0a 58 0a 58 40 6e |X@end me|nu.X.X@n|
|00001690| 6f 64 65 20 20 20 20 4f | 76 65 72 76 69 65 77 2c |ode O|verview,|
|000016a0| 20 49 6e 73 74 61 6c 6c | 61 74 69 6f 6e 2c 20 54 | Install|ation, T|
|000016b0| 6f 70 2c 20 54 6f 70 0a | 58 40 63 6f 6d 6d 65 6e |op, Top.|X@commen|
|000016c0| 74 20 6e 6f 64 65 2d 6e | 61 6d 65 2c 20 20 20 20 |t node-n|ame, |
|000016d0| 20 6e 65 78 74 2c 20 20 | 20 20 20 20 20 20 20 20 | next, | |
|000016e0| 20 70 72 65 76 69 6f 75 | 73 2c 20 75 70 0a 58 40 | previou|s, up.X@|
|000016f0| 63 68 61 70 74 65 72 20 | 4f 76 65 72 76 69 65 77 |chapter |Overview|
|00001700| 0a 58 40 63 69 6e 64 65 | 78 20 4f 76 65 72 76 69 |.X@cinde|x Overvi|
|00001710| 65 77 0a 58 0a 54 68 69 | 73 20 64 6f 63 75 6d 65 |ew.X.Thi|s docume|
|00001720| 6e 74 20 64 65 73 63 72 | 69 62 65 73 20 6d 79 20 |nt descr|ibes my |
|00001730| 43 2b 2b 20 69 6e 74 65 | 72 66 61 63 65 20 74 6f |C++ inte|rface to|
|00001740| 20 53 75 6e 20 52 65 6d | 6f 74 65 20 50 72 6f 63 | Sun Rem|ote Proc|
|00001750| 65 64 75 72 65 20 43 61 | 6c 6c 73 2e 0a 49 74 20 |edure Ca|lls..It |
|00001760| 69 73 20 62 61 73 65 64 | 20 6f 6e 20 73 6f 75 72 |is based| on sour|
|00001770| 63 65 73 20 66 72 6f 6d | 20 50 65 74 65 72 20 42 |ces from| Peter B|
|00001780| 65 72 73 65 6e 20 74 68 | 61 74 20 49 20 67 6f 74 |ersen th|at I got|
|00001790| 20 66 72 6f 6d 20 73 6f | 6d 65 20 6e 65 77 73 67 | from so|me newsg|
|000017a0| 72 6f 75 70 2c 0a 74 68 | 6f 75 67 68 20 49 20 64 |roup,.th|ough I d|
|000017b0| 6f 6e 27 74 20 72 65 6d | 65 6d 62 65 72 20 77 68 |on't rem|ember wh|
|000017c0| 69 63 68 20 6f 6e 65 2e | 20 49 20 6c 69 6b 65 64 |ich one.| I liked|
|000017d0| 20 74 68 65 20 62 61 73 | 69 63 20 69 64 65 61 20 | the bas|ic idea |
|000017e0| 62 75 74 20 64 69 73 6c | 69 6b 65 64 0a 73 65 76 |but disl|iked.sev|
|000017f0| 65 72 61 6c 20 61 73 70 | 65 63 74 73 20 6f 66 20 |eral asp|ects of |
|00001800| 74 68 65 20 69 6e 74 65 | 72 66 61 63 65 20 64 65 |the inte|rface de|
|00001810| 74 61 69 6c 73 2e 20 53 | 6f 20 49 20 61 64 61 70 |tails. S|o I adap|
|00001820| 74 65 64 20 69 74 20 74 | 6f 20 6d 79 20 6c 69 6b |ted it t|o my lik|
|00001830| 65 73 2e 20 49 0a 69 6e | 74 65 6e 64 65 64 20 73 |es. I.in|tended s|
|00001840| 6f 6d 65 20 6d 69 6e 6f | 72 20 63 68 61 6e 67 65 |ome mino|r change|
|00001850| 73 20 62 75 74 20 73 6f | 6f 6e 20 66 6f 75 6e 64 |s but so|on found|
|00001860| 20 6d 79 73 65 6c 66 20 | 72 65 6e 61 6d 69 6e 67 | myself |renaming|
|00001870| 20 63 6c 61 73 73 65 73 | 2c 0a 63 68 61 6e 67 69 | classes|,.changi|
|00001880| 6e 67 20 6d 65 74 68 6f | 64 20 70 61 72 61 6d 65 |ng metho|d parame|
|00001890| 74 65 72 73 2c 20 69 6e | 74 72 6f 64 75 63 69 6e |ters, in|troducin|
|000018a0| 67 20 6e 65 77 20 63 6c | 61 73 73 65 73 2c 20 65 |g new cl|asses, e|
|000018b0| 74 63 2e 20 54 68 65 20 | 72 65 73 75 6c 74 20 69 |tc. The |result i|
|000018c0| 73 0a 62 79 20 6e 6f 20 | 77 61 79 20 63 6f 6d 70 |s.by no |way comp|
|000018d0| 61 74 69 62 6c 65 20 77 | 69 74 68 20 74 68 65 20 |atible w|ith the |
|000018e0| 6f 72 69 67 69 6e 61 6c | 20 76 65 72 73 69 6f 6e |original| version|
|000018f0| 2e 20 49 74 20 69 73 2c | 20 49 20 68 6f 70 65 2c |. It is,| I hope,|
|00001900| 0a 6e 65 76 65 72 74 68 | 65 6c 65 73 73 20 75 73 |.neverth|eless us|
|00001910| 65 66 75 6c 2e 0a 58 0a | 42 61 73 69 63 61 6c 6c |eful..X.|Basicall|
|00001920| 79 2c 20 74 68 65 20 69 | 6e 74 65 72 66 61 63 65 |y, the i|nterface|
|00001930| 20 64 65 66 69 6e 65 73 | 20 73 69 78 20 63 6c 61 | defines| six cla|
|00001940| 73 73 3a 20 40 63 6f 64 | 65 7b 58 64 72 49 6e 66 |ss: @cod|e{XdrInf|
|00001950| 6f 7d 2c 0a 58 40 63 6f | 64 65 7b 52 70 63 52 65 |o},.X@co|de{RpcRe|
|00001960| 71 75 65 73 74 7d 2c 20 | 40 63 6f 64 65 7b 52 70 |quest}, |@code{Rp|
|00001970| 63 43 61 6c 6c 62 61 63 | 6b 7d 2f 40 63 6f 64 65 |cCallbac|k}/@code|
|00001980| 7b 52 70 63 4d 65 74 68 | 6f 64 43 61 6c 6c 7d 2c |{RpcMeth|odCall},|
|00001990| 0a 58 40 63 6f 64 65 7b | 52 70 63 53 65 72 76 69 |.X@code{|RpcServi|
|000019a0| 63 65 7d 20 61 6e 64 20 | 40 63 6f 64 65 7b 52 70 |ce} and |@code{Rp|
|000019b0| 63 53 74 75 62 7d 2e 0a | 58 0a 58 40 63 6f 64 65 |cStub}..|X.X@code|
|000019c0| 7b 58 64 72 49 6e 66 6f | 7d 20 6f 62 6a 65 63 74 |{XdrInfo|} object|
|000019d0| 73 20 64 65 73 63 72 69 | 62 65 20 74 68 65 20 65 |s descri|be the e|
|000019e0| 78 74 65 72 6e 61 6c 20 | 64 61 74 61 20 72 65 70 |xternal |data rep|
|000019f0| 72 65 73 65 6e 74 61 74 | 69 6f 6e 20 6f 66 20 61 |resentat|ion of a|
|00001a00| 0a 74 79 70 65 2e 20 54 | 68 65 72 65 20 61 72 65 |.type. T|here are|
|00001a10| 20 70 72 65 64 65 66 69 | 6e 65 64 20 40 63 6f 64 | predefi|ned @cod|
|00001a20| 65 7b 58 64 72 49 6e 66 | 6f 7d 73 20 66 6f 72 20 |e{XdrInf|o}s for |
|00001a30| 74 68 65 20 62 61 73 69 | 63 20 74 79 70 65 73 2e |the basi|c types.|
|00001a40| 0a 58 40 63 6f 64 65 7b | 52 70 63 52 65 71 75 65 |.X@code{|RpcReque|
|00001a50| 73 74 7d 20 6f 62 6a 65 | 63 74 73 20 64 65 73 63 |st} obje|cts desc|
|00001a60| 72 69 62 65 20 74 68 65 | 20 61 76 61 69 6c 61 62 |ribe the| availab|
|00001a70| 6c 65 20 70 72 6f 63 65 | 64 75 72 65 20 63 61 6c |le proce|dure cal|
|00001a80| 6c 73 2e 20 54 68 65 79 | 0a 61 72 65 20 63 6f 6e |ls. They|.are con|
|00001a90| 73 74 72 75 63 74 65 64 | 20 66 72 6f 6d 20 61 20 |structed| from a |
|00001aa0| 75 6e 69 71 75 65 20 72 | 65 71 75 65 73 74 20 6e |unique r|equest n|
|00001ab0| 75 6d 62 65 72 2c 20 74 | 68 65 20 40 63 6f 64 65 |umber, t|he @code|
|00001ac0| 7b 58 64 72 49 6e 66 6f | 7d 73 20 6f 66 20 74 68 |{XdrInfo|}s of th|
|00001ad0| 65 0a 70 72 6f 63 65 64 | 75 72 65 27 73 20 61 72 |e.proced|ure's ar|
|00001ae0| 67 75 6d 65 6e 74 73 20 | 61 6e 64 20 69 74 73 20 |guments |and its |
|00001af0| 72 65 74 75 72 6e 20 74 | 79 70 65 2e 20 40 63 6f |return t|ype. @co|
|00001b00| 64 65 7b 52 70 63 43 61 | 6c 6c 62 61 63 6b 7d 20 |de{RpcCa|llback} |
|00001b10| 69 73 20 61 6e 0a 6f 62 | 6a 65 63 74 20 74 68 61 |is an.ob|ject tha|
|00001b20| 74 20 68 6f 6c 64 73 20 | 61 20 70 6f 69 6e 74 65 |t holds |a pointe|
|00001b30| 72 20 74 6f 20 61 20 66 | 75 6e 63 74 69 6f 6e 20 |r to a f|unction |
|00001b40| 61 6e 64 20 69 6e 66 6f | 72 6d 61 74 69 6f 6e 20 |and info|rmation |
|00001b50| 61 62 6f 75 74 20 74 68 | 65 0a 6e 75 6d 62 65 72 |about th|e.number|
|00001b60| 20 6f 66 20 69 74 73 20 | 61 72 67 75 6d 65 6e 74 | of its |argument|
|00001b70| 73 2e 20 40 63 6f 64 65 | 7b 52 70 63 4d 65 74 68 |s. @code|{RpcMeth|
|00001b80| 6f 64 43 61 6c 6c 7d 20 | 69 73 20 61 20 74 65 6d |odCall} |is a tem|
|00001b90| 70 6c 61 74 65 20 74 68 | 61 74 20 69 6e 20 61 0a |plate th|at in a.|
|00001ba0| 73 69 6d 69 6c 61 72 20 | 77 61 79 20 68 6f 6c 64 |similar |way hold|
|00001bb0| 73 20 61 20 70 6f 69 6e | 74 65 72 20 74 6f 20 61 |s a poin|ter to a|
|00001bc0| 6e 20 6f 62 6a 65 63 74 | 20 61 6e 64 20 6f 6e 65 |n object| and one|
|00001bd0| 20 6f 66 20 69 74 73 20 | 6d 65 74 68 6f 64 73 20 | of its |methods |
|00001be0| 61 6e 64 0a 49 6e 66 6f | 72 6d 61 74 69 6f 6e 20 |and.Info|rmation |
|00001bf0| 61 62 6f 75 74 20 74 68 | 65 20 6e 75 6d 62 65 72 |about th|e number|
|00001c00| 20 6f 66 20 69 74 73 20 | 61 72 67 75 6d 65 6e 74 | of its |argument|
|00001c10| 73 2e 0a 58 0a 41 6e 20 | 40 63 6f 64 65 7b 52 70 |s..X.An |@code{Rp|
|00001c20| 63 52 65 71 75 65 73 74 | 7d 20 61 6e 64 20 69 74 |cRequest|} and it|
|00001c30| 73 20 6d 61 74 63 68 69 | 6e 67 20 40 63 6f 64 65 |s matchi|ng @code|
|00001c40| 7b 52 70 63 43 61 6c 6c | 62 61 63 6b 7d 20 6f 72 |{RpcCall|back} or|
|00001c50| 0a 58 40 63 6f 64 65 7b | 52 70 63 4d 65 74 68 6f |.X@code{|RpcMetho|
|00001c60| 64 43 61 6c 6c 7d 20 6d | 61 79 20 62 65 20 72 65 |dCall} m|ay be re|
|00001c70| 67 69 73 74 65 72 65 64 | 20 77 69 74 68 20 61 6e |gistered| with an|
|00001c80| 20 40 63 6f 64 65 7b 52 | 70 63 53 65 72 76 69 63 | @code{R|pcServic|
|00001c90| 65 7d 2e 0a 58 45 78 61 | 63 74 6c 79 20 6f 6e 65 |e}..XExa|ctly one|
|00001ca0| 20 6f 62 6a 65 63 74 20 | 6f 66 20 74 79 70 65 20 | object |of type |
|00001cb0| 40 63 6f 64 65 7b 52 70 | 63 53 65 72 76 69 63 65 |@code{Rp|cService|
|00001cc0| 7d 20 6d 61 79 20 62 65 | 20 69 6e 73 74 61 6e 74 |} may be| instant|
|00001cd0| 69 61 74 65 64 20 69 6e | 20 61 0a 70 72 6f 67 72 |iated in| a.progr|
|00001ce0| 61 6d 20 74 68 61 74 20 | 69 6d 70 6c 65 6d 65 6e |am that |implemen|
|00001cf0| 74 73 20 61 6e 20 52 50 | 43 20 73 65 72 76 65 72 |ts an RP|C server|
|00001d00| 2e 20 4d 65 74 68 6f 64 | 20 40 63 6f 64 65 7b 50 |. Method| @code{P|
|00001d10| 72 6f 76 69 64 65 20 28 | 29 7d 20 69 73 20 61 0a |rovide (|)} is a.|
|00001d20| 6c 6f 6f 70 20 74 68 61 | 74 20 77 61 69 74 73 20 |loop tha|t waits |
|00001d30| 66 6f 72 20 72 65 71 75 | 65 73 74 73 20 61 6e 64 |for requ|ests and|
|00001d40| 20 64 69 73 70 61 74 63 | 68 65 73 20 74 68 65 6d | dispatc|hes them|
|00001d50| 2e 0a 58 0a 41 20 63 6c | 69 65 6e 74 20 70 72 6f |..X.A cl|ient pro|
|00001d60| 67 72 61 6d 20 69 6e 73 | 74 61 6e 74 69 61 74 65 |gram ins|tantiate|
|00001d70| 73 20 61 6e 20 6f 62 6a | 65 63 74 20 6f 66 20 74 |s an obj|ect of t|
|00001d80| 79 70 65 20 40 63 6f 64 | 65 7b 52 70 63 53 74 75 |ype @cod|e{RpcStu|
|00001d90| 62 7d 2e 20 20 54 68 65 | 0a 63 6f 6e 73 74 72 75 |b}. The|.constru|
|00001da0| 63 74 6f 72 20 65 73 74 | 61 62 6c 69 73 68 65 73 |ctor est|ablishes|
|00001db0| 20 61 20 63 6f 6e 6e 65 | 63 74 69 6f 6e 20 74 6f | a conne|ction to|
|00001dc0| 20 74 68 65 20 73 65 72 | 76 65 72 20 73 70 65 63 | the ser|ver spec|
|00001dd0| 69 66 69 65 64 20 62 79 | 20 69 74 73 0a 61 72 67 |ified by| its.arg|
|00001de0| 75 6d 65 6e 74 73 2e 20 | 50 72 6f 63 65 64 75 72 |uments. |Procedur|
|00001df0| 65 73 20 6f 66 20 74 68 | 65 20 73 65 72 76 65 72 |es of th|e server|
|00001e00| 20 6d 61 79 20 62 65 20 | 69 6e 76 6f 6b 65 64 20 | may be |invoked |
|00001e10| 75 73 69 6e 67 20 6d 65 | 74 68 6f 64 0a 58 40 63 |using me|thod.X@c|
|00001e20| 6f 64 65 7b 43 61 6c 6c | 20 28 40 64 6f 74 73 7b |ode{Call| (@dots{|
|00001e30| 7d 29 7d 2e 0a 58 0a 58 | 40 6e 6f 64 65 20 20 20 |})}..X.X|@node |
|00001e40| 20 49 6e 73 74 61 6c 6c | 61 74 69 6f 6e 2c 20 43 | Install|ation, C|
|00001e50| 6c 61 73 73 65 73 2c 20 | 4f 76 65 72 76 69 65 77 |lasses, |Overview|
|00001e60| 2c 20 54 6f 70 0a 58 40 | 63 6f 6d 6d 65 6e 74 20 |, Top.X@|comment |
|00001e70| 6e 6f 64 65 2d 6e 61 6d | 65 2c 20 20 20 20 20 6e |node-nam|e, n|
|00001e80| 65 78 74 2c 20 20 20 20 | 20 20 20 20 20 20 20 70 |ext, | p|
|00001e90| 72 65 76 69 6f 75 73 2c | 20 75 70 0a 58 40 63 68 |revious,| up.X@ch|
|00001ea0| 61 70 74 65 72 20 49 6e | 73 74 61 6c 6c 61 74 69 |apter In|stallati|
|00001eb0| 6f 6e 0a 58 40 63 69 6e | 64 65 78 20 49 6e 73 74 |on.X@cin|dex Inst|
|00001ec0| 61 6c 6c 61 74 69 6f 6e | 0a 58 0a 54 68 65 20 72 |allation|.X.The r|
|00001ed0| 70 63 2b 2b 20 6c 69 62 | 72 61 72 79 20 68 61 73 |pc++ lib|rary has|
|00001ee0| 20 73 75 63 63 65 73 73 | 66 75 6c 6c 79 20 62 65 | success|fully be|
|00001ef0| 65 6e 20 74 65 73 74 65 | 64 20 75 73 69 6e 67 20 |en teste|d using |
|00001f00| 61 20 70 61 74 63 68 65 | 64 20 67 63 63 2d 32 2e |a patche|d gcc-2.|
|00001f10| 32 2e 32 0a 6f 6e 20 61 | 20 53 70 61 72 63 53 74 |2.2.on a| SparcSt|
|00001f20| 61 74 69 6f 6e 20 72 75 | 6e 6e 69 6e 67 20 53 75 |ation ru|nning Su|
|00001f30| 6e 4f 53 20 34 2e 31 2e | 5b 31 32 5d 20 61 6e 64 |nOS 4.1.|[12] and|
|00001f40| 20 61 20 33 38 36 20 73 | 79 73 74 65 6d 20 72 75 | a 386 s|ystem ru|
|00001f50| 6e 6e 69 6e 67 0a 49 6e | 74 65 72 61 63 74 69 76 |nning.In|teractiv|
|00001f60| 65 20 55 6e 69 78 20 28 | 61 20 53 59 53 56 20 33 |e Unix (|a SYSV 3|
|00001f70| 2e 32 29 2e 20 50 61 74 | 63 68 69 6e 67 20 67 63 |.2). Pat|ching gc|
|00001f80| 63 2d 32 2e 32 2e 32 20 | 77 61 73 20 6e 65 63 65 |c-2.2.2 |was nece|
|00001f90| 73 73 61 72 79 20 62 65 | 63 61 75 73 65 0a 74 68 |ssary be|cause.th|
|00001fa0| 65 20 75 6e 70 61 74 63 | 68 65 64 20 76 65 72 73 |e unpatc|hed vers|
|00001fb0| 69 6f 6e 20 63 61 6e 27 | 74 20 68 61 6e 64 6c 65 |ion can'|t handle|
|00001fc0| 20 74 79 70 65 64 65 66 | 73 20 74 68 61 74 20 61 | typedef|s that a|
|00001fd0| 72 65 20 6c 6f 63 61 6c | 20 74 6f 20 74 65 6d 70 |re local| to temp|
|00001fe0| 6c 61 74 65 73 2e 0a 54 | 68 65 20 62 75 67 20 72 |lates..T|he bug r|
|00001ff0| 65 70 6f 72 74 20 77 69 | 74 68 20 70 61 74 63 68 |eport wi|th patch|
|00002000| 65 73 20 63 61 6e 20 62 | 65 20 66 6f 75 6e 64 20 |es can b|e found |
|00002010| 69 6e 20 74 68 65 20 73 | 6f 75 72 63 65 20 64 69 |in the s|ource di|
|00002020| 72 65 63 74 6f 72 79 20 | 69 6e 20 66 69 6c 65 0a |rectory |in file.|
|00002030| 58 40 63 6f 64 65 7b 67 | 63 63 2d 32 2e 32 2e 32 |X@code{g|cc-2.2.2|
|00002040| 2e 66 69 78 7d 2e 0a 58 | 0a 41 73 20 61 20 70 72 |.fix}..X|.As a pr|
|00002050| 65 72 65 71 75 69 73 69 | 74 65 20 74 6f 20 75 73 |erequisi|te to us|
|00002060| 69 6e 67 20 52 50 43 73 | 20 77 69 74 68 20 43 2b |ing RPCs| with C+|
|00002070| 2b 20 79 6f 75 20 6e 65 | 65 64 20 41 4e 53 49 2d |+ you ne|ed ANSI-|
|00002080| 43 2f 43 2b 2b 20 63 6f | 6e 66 6f 72 6d 61 6e 74 |C/C++ co|nformant|
|00002090| 0a 68 65 61 64 65 72 20 | 66 69 6c 65 73 20 66 6f |.header |files fo|
|000020a0| 72 20 52 50 43 2e 20 49 | 20 68 61 76 65 20 70 72 |r RPC. I| have pr|
|000020b0| 6f 76 69 64 65 64 20 73 | 75 63 68 20 66 69 6c 65 |ovided s|uch file|
|000020c0| 73 20 69 6e 20 74 68 65 | 20 64 69 72 65 63 74 6f |s in the| directo|
|000020d0| 72 79 0a 58 40 63 6f 64 | 65 7b 53 74 64 48 64 72 |ry.X@cod|e{StdHdr|
|000020e0| 73 2f 72 70 63 7d 20 6f | 66 20 74 68 65 20 73 6f |s/rpc} o|f the so|
|000020f0| 75 72 63 65 20 74 72 65 | 65 2e 20 54 6f 20 61 76 |urce tre|e. To av|
|00002100| 6f 69 64 20 61 6e 79 20 | 63 6f 70 79 72 69 67 68 |oid any |copyrigh|
|00002110| 74 20 63 6f 6e 66 6c 69 | 63 74 73 2c 0a 74 68 65 |t confli|cts,.the|
|00002120| 79 20 61 72 65 20 64 65 | 72 69 76 65 64 20 66 72 |y are de|rived fr|
|00002130| 6f 6d 20 74 68 65 20 70 | 75 62 6c 69 63 20 61 76 |om the p|ublic av|
|00002140| 61 69 6c 61 62 6c 65 20 | 52 50 43 20 73 6f 75 72 |ailable |RPC sour|
|00002150| 63 65 20 63 6f 64 65 20 | 72 61 74 68 65 72 20 74 |ce code |rather t|
|00002160| 68 61 6e 0a 66 72 6f 6d | 20 74 68 65 20 66 69 6c |han.from| the fil|
|00002170| 65 73 20 74 68 61 74 20 | 63 6f 6d 65 20 77 69 74 |es that |come wit|
|00002180| 68 20 53 75 6e 4f 53 20 | 34 2e 31 2e 58 2e 20 54 |h SunOS |4.1.X. T|
|00002190| 68 65 20 64 69 66 66 65 | 72 65 6e 63 65 73 20 61 |he diffe|rences a|
|000021a0| 72 65 20 6d 69 6e 6f 72 | 2e 0a 54 68 65 20 53 75 |re minor|..The Su|
|000021b0| 6e 4f 53 20 34 2e 31 2e | 58 20 66 69 6c 65 73 20 |nOS 4.1.|X files |
|000021c0| 64 65 66 69 6e 65 20 73 | 6f 6d 65 20 61 64 64 69 |define s|ome addi|
|000021d0| 74 69 6f 6e 61 6c 20 66 | 75 6e 63 74 69 6f 6e 73 |tional f|unctions|
|000021e0| 2e 20 59 6f 75 20 68 61 | 76 65 20 74 6f 0a 65 69 |. You ha|ve to.ei|
|000021f0| 74 68 65 72 20 63 6f 70 | 79 20 74 68 65 20 66 69 |ther cop|y the fi|
|00002200| 6c 65 73 20 66 72 6f 6d | 20 40 63 6f 64 65 7b 53 |les from| @code{S|
|00002210| 74 64 48 64 72 73 2f 72 | 70 63 7d 20 6f 72 20 70 |tdHdrs/r|pc} or p|
|00002220| 61 74 63 68 65 64 20 66 | 69 6c 65 73 20 66 72 6f |atched f|iles fro|
|00002230| 6d 20 79 6f 75 72 0a 58 | 40 63 6f 64 65 7b 2f 75 |m your.X|@code{/u|
|00002240| 73 72 2f 69 6e 63 6c 75 | 64 65 2f 72 70 63 7d 20 |sr/inclu|de/rpc} |
|00002250| 74 6f 20 61 20 64 69 72 | 65 63 74 6f 72 79 20 77 |to a dir|ectory w|
|00002260| 68 65 72 65 20 67 63 63 | 20 63 61 6e 20 66 69 6e |here gcc| can fin|
|00002270| 64 20 74 68 65 6d 2e 20 | 49 66 20 79 6f 75 0a 64 |d them. |If you.d|
|00002280| 6f 6e 27 74 20 77 61 6e | 74 20 74 6f 20 69 6e 73 |on't wan|t to ins|
|00002290| 74 61 6c 6c 20 74 68 65 | 6d 20 67 6c 6f 62 61 6c |tall the|m global|
|000022a0| 6c 79 20 69 6e 20 67 63 | 63 27 73 20 69 6e 63 6c |ly in gc|c's incl|
|000022b0| 75 64 65 20 64 69 72 65 | 63 74 6f 72 79 2c 20 79 |ude dire|ctory, y|
|000022c0| 6f 75 20 63 61 6e 0a 69 | 6e 63 6c 75 64 65 20 74 |ou can.i|nclude t|
|000022d0| 68 65 6d 20 62 79 20 75 | 73 69 6e 67 20 61 6e 20 |hem by u|sing an |
|000022e0| 61 64 64 69 74 69 6f 6e | 61 6c 20 60 60 40 63 6f |addition|al ``@co|
|000022f0| 64 65 7b 2d 49 7d 27 27 | 20 66 6c 61 67 20 64 75 |de{-I}''| flag du|
|00002300| 72 69 6e 67 0a 63 6f 6d | 70 69 6c 61 74 69 6f 6e |ring.com|pilation|
|00002310| 2e 0a 58 0a 49 6e 20 53 | 75 6e 4f 53 20 79 6f 75 |..X.In S|unOS you|
|00002320| 20 63 61 6e 20 73 69 6d | 70 6c 79 20 74 79 70 65 | can sim|ply type|
|00002330| 20 60 40 63 6f 64 65 7b | 6d 61 6b 65 20 69 6e 73 | `@code{|make ins|
|00002340| 74 61 6c 6c 20 49 4e 53 | 54 52 4f 4f 54 3d 40 64 |tall INS|TROOT=@d|
|00002350| 6f 74 73 7b 7d 7d 27 0a | 77 68 69 63 68 20 77 69 |ots{}}'.|which wi|
|00002360| 6c 6c 20 6d 61 6b 65 20 | 74 68 65 20 6c 69 62 72 |ll make |the libr|
|00002370| 61 72 79 20 61 6e 64 20 | 69 6e 73 74 61 6c 6c 20 |ary and |install |
|00002380| 69 74 20 69 6e 20 40 63 | 6f 64 65 7b 49 4e 53 54 |it in @c|ode{INST|
|00002390| 52 4f 4f 54 2f 6c 69 62 | 7d 20 61 6e 64 0a 74 68 |ROOT/lib|} and.th|
|000023a0| 65 20 68 65 61 64 65 72 | 20 66 69 6c 65 73 20 69 |e header| files i|
|000023b0| 6e 20 40 63 6f 64 65 7b | 49 4e 53 54 52 4f 4f 54 |n @code{|INSTROOT|
|000023c0| 2f 69 6e 63 6c 75 64 65 | 2f 72 70 63 2b 2b 7d 2e |/include|/rpc++}.|
|000023d0| 20 20 4f 74 68 65 72 20 | 55 6e 69 63 65 73 20 77 | Other |Unices w|
|000023e0| 69 6c 6c 0a 70 72 6f 62 | 61 62 6c 79 20 68 61 76 |ill.prob|ably hav|
|000023f0| 65 20 70 72 6f 62 6c 65 | 6d 73 20 77 69 74 68 20 |e proble|ms with |
|00002400| 74 68 65 20 60 69 6e 73 | 74 61 6c 6c 27 20 63 6f |the `ins|tall' co|
|00002410| 6d 6d 61 6e 64 2e 20 54 | 79 70 65 20 6f 6e 6c 79 |mmand. T|ype only|
|00002420| 20 60 6d 61 6b 65 27 20 | 61 6e 64 0a 63 6f 70 79 | `make' |and.copy|
|00002430| 20 74 68 65 20 72 65 73 | 75 6c 74 69 6e 67 20 40 | the res|ulting @|
|00002440| 63 6f 64 65 7b 6c 69 62 | 72 70 63 2b 2b 2e 61 7d |code{lib|rpc++.a}|
|00002450| 20 74 6f 20 79 6f 75 72 | 20 6c 6f 63 61 6c 20 6c | to your| local l|
|00002460| 69 62 72 61 72 79 20 64 | 69 72 65 63 74 6f 72 79 |ibrary d|irectory|
|00002470| 20 61 6e 64 0a 74 68 65 | 20 66 69 6c 65 73 20 40 | and.the| files @|
|00002480| 63 6f 64 65 7b 72 70 63 | 2b 2b 2f 2a 7d 20 74 6f |code{rpc|++/*} to|
|00002490| 20 61 6e 20 40 63 6f 64 | 65 7b 72 70 63 2b 2b 7d | an @cod|e{rpc++}|
|000024a0| 2d 73 75 62 64 69 72 65 | 63 74 6f 72 79 20 6f 66 |-subdire|ctory of|
|000024b0| 20 79 6f 75 72 20 6c 6f | 63 61 6c 0a 69 6e 63 6c | your lo|cal.incl|
|000024c0| 75 64 65 20 64 69 72 65 | 63 74 6f 72 79 2e 0a 58 |ude dire|ctory..X|
|000024d0| 0a 58 40 6e 6f 64 65 20 | 20 20 20 43 6c 61 73 73 |.X@node | Class|
|000024e0| 65 73 2c 20 43 61 76 65 | 61 74 73 2c 20 49 6e 73 |es, Cave|ats, Ins|
|000024f0| 74 61 6c 6c 61 74 69 6f | 6e 2c 20 54 6f 70 0a 58 |tallatio|n, Top.X|
|00002500| 40 63 6f 6d 6d 65 6e 74 | 20 6e 6f 64 65 2d 6e 61 |@comment| node-na|
|00002510| 6d 65 2c 20 20 20 20 20 | 6e 65 78 74 2c 20 20 20 |me, |next, |
|00002520| 20 20 20 20 20 20 20 20 | 70 72 65 76 69 6f 75 73 | |previous|
|00002530| 2c 09 75 70 0a 58 40 63 | 68 61 70 74 65 72 20 54 |,.up.X@c|hapter T|
|00002540| 68 65 20 63 6c 61 73 73 | 65 73 0a 58 0a 58 40 6d |he class|es.X.X@m|
|00002550| 65 6e 75 0a 58 2a 20 58 | 64 72 49 6e 66 6f 3a 3a |enu.X* X|drInfo::|
|00002560| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00002570| 20 20 20 20 20 40 63 6f | 64 65 7b 58 64 72 49 6e | @co|de{XdrIn|
|00002580| 66 6f 7d 0a 58 2a 20 52 | 70 63 52 65 71 75 65 73 |fo}.X* R|pcReques|
|00002590| 74 3a 3a 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |t:: | |
|000025a0| 20 20 20 20 20 40 63 6f | 64 65 7b 52 70 63 52 65 | @co|de{RpcRe|
|000025b0| 71 75 65 73 74 7d 0a 58 | 2a 20 43 61 6c 6c 62 61 |quest}.X|* Callba|
|000025c0| 63 6b 73 3a 3a 20 20 20 | 20 20 20 20 20 20 20 20 |cks:: | |
|000025d0| 20 20 20 20 20 20 20 20 | 40 63 6f 64 65 7b 43 61 | |@code{Ca|
|000025e0| 6c 6c 62 61 63 6b 73 7d | 0a 58 2a 20 52 70 63 53 |llbacks}|.X* RpcS|
|000025f0| 65 72 76 69 63 65 3a 3a | 20 20 20 20 20 20 20 20 |ervice::| |
|00002600| 20 20 20 20 20 20 20 20 | 20 20 40 63 6f 64 65 7b | | @code{|
|00002610| 52 70 63 53 65 72 76 69 | 63 65 7d 0a 58 2a 20 52 |RpcServi|ce}.X* R|
|00002620| 70 63 53 74 75 62 3a 3a | 20 20 20 20 20 20 20 20 |pcStub::| |
|00002630| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 40 63 6f | | @co|
|00002640| 64 65 7b 52 70 63 53 74 | 75 62 7d 0a 58 40 65 6e |de{RpcSt|ub}.X@en|
|00002650| 64 20 6d 65 6e 75 0a 58 | 0a 58 40 6e 6f 64 65 20 |d menu.X|.X@node |
|00002660| 20 20 20 58 64 72 49 6e | 66 6f 2c 20 52 70 63 52 | XdrIn|fo, RpcR|
|00002670| 65 71 75 65 73 74 2c 20 | 20 2c 20 43 6c 61 73 73 |equest, | , Class|
|00002680| 65 73 0a 58 40 63 6f 6d | 6d 65 6e 74 20 6e 6f 64 |es.X@com|ment nod|
|00002690| 65 2d 6e 61 6d 65 2c 20 | 20 20 20 20 6e 65 78 74 |e-name, | next|
|000026a0| 2c 20 20 20 20 20 20 20 | 20 20 20 20 70 72 65 76 |, | prev|
|000026b0| 69 6f 75 73 2c 20 75 70 | 0a 58 40 73 65 63 74 69 |ious, up|.X@secti|
|000026c0| 6f 6e 20 40 63 6f 64 65 | 7b 58 64 72 49 6e 66 6f |on @code|{XdrInfo|
|000026d0| 7d 0a 58 40 63 69 6e 64 | 65 78 20 40 63 6f 64 65 |}.X@cind|ex @code|
|000026e0| 7b 58 64 72 49 6e 66 6f | 7d 0a 58 0a 44 65 63 6c |{XdrInfo|}.X.Decl|
|000026f0| 61 72 65 64 20 69 6e 3a | 20 40 63 6f 64 65 7b 22 |ared in:| @code{"|
|00002700| 72 70 63 2b 2b 2f 78 64 | 72 2b 2b 2e 68 22 7d 0a |rpc++/xd|r++.h"}.|
|00002710| 58 0a 58 40 64 65 66 74 | 70 20 43 6c 61 73 73 20 |X.X@deft|p Class |
|00002720| 58 64 72 49 6e 66 6f 0a | 43 6c 61 73 73 20 58 64 |XdrInfo.|Class Xd|
|00002730| 72 49 6e 66 6f 20 64 65 | 73 63 72 69 62 65 73 20 |rInfo de|scribes |
|00002740| 73 65 72 69 61 6c 69 7a | 65 72 73 2e 20 49 74 20 |serializ|ers. It |
|00002750| 63 6f 6d 62 69 6e 65 73 | 20 74 68 65 20 78 64 72 |combines| the xdr|
|00002760| 70 72 6f 63 5f 74 20 77 | 69 74 68 20 74 68 65 0a |proc_t w|ith the.|
|00002770| 73 69 7a 65 20 69 6e 66 | 6f 20 28 74 68 65 20 73 |size inf|o (the s|
|00002780| 69 7a 65 20 6f 66 20 74 | 68 65 20 64 61 74 61 20 |ize of t|he data |
|00002790| 74 6f 20 62 65 20 63 6f | 6e 76 65 72 74 65 64 29 |to be co|nverted)|
|000027a0| 20 75 73 75 61 6c 6c 79 | 20 6e 65 65 64 65 64 20 | usually| needed |
|000027b0| 69 66 20 79 6f 75 0a 77 | 61 6e 74 20 74 6f 20 61 |if you.w|ant to a|
|000027c0| 70 70 6c 79 20 61 20 73 | 65 72 69 61 6c 69 7a 65 |pply a s|erialize|
|000027d0| 72 2e 0a 58 40 65 6e 64 | 20 64 65 66 74 70 0a 58 |r..X@end| deftp.X|
|000027e0| 0a 54 68 65 72 65 20 69 | 73 20 6f 6e 6c 79 20 6f |.There i|s only o|
|000027f0| 6e 65 20 63 6f 6e 73 74 | 72 75 63 74 6f 72 20 66 |ne const|ructor f|
|00002800| 6f 72 20 40 63 6f 64 65 | 7b 58 64 72 49 6e 66 6f |or @code|{XdrInfo|
|00002810| 7d 3a 0a 58 0a 58 40 64 | 65 66 74 79 70 65 66 6e |}:.X.X@d|eftypefn|
|00002820| 20 43 6f 6e 73 74 72 75 | 63 74 6f 72 20 7b 7d 20 | Constru|ctor {} |
|00002830| 58 64 72 49 6e 66 6f 20 | 28 78 64 72 70 72 6f 63 |XdrInfo |(xdrproc|
|00002840| 5f 74 20 40 76 61 72 7b | 74 7d 2c 20 73 69 7a 65 |_t @var{|t}, size|
|00002850| 5f 74 20 40 76 61 72 7b | 73 7d 29 0a 43 6f 6e 73 |_t @var{|s}).Cons|
|00002860| 74 72 75 63 74 20 61 6e | 20 40 63 6f 64 65 7b 58 |truct an| @code{X|
|00002870| 64 72 49 6e 66 6f 7d 20 | 66 6f 72 20 61 20 74 79 |drInfo} |for a ty|
|00002880| 70 65 2e 20 54 68 65 20 | 74 79 70 65 20 63 61 6e |pe. The |type can|
|00002890| 20 62 65 20 63 6f 6e 76 | 65 72 74 65 64 20 74 6f | be conv|erted to|
|000028a0| 20 61 6e 0a 65 78 74 65 | 72 6e 61 6c 20 64 61 74 | an.exte|rnal dat|
|000028b0| 61 20 72 65 70 72 65 73 | 65 6e 74 61 74 69 6f 6e |a repres|entation|
|000028c0| 20 28 73 65 72 69 65 6c | 69 7a 65 64 29 20 77 69 | (seriel|ized) wi|
|000028d0| 74 68 20 66 75 6e 63 74 | 69 6f 6e 20 40 76 61 72 |th funct|ion @var|
|000028e0| 7b 74 7d 2e 20 49 74 73 | 0a 73 69 7a 65 20 28 69 |{t}. Its|.size (i|
|000028f0| 6e 20 62 79 74 65 73 2c | 20 66 72 6f 6d 20 40 63 |n bytes,| from @c|
|00002900| 6f 64 65 7b 73 69 7a 65 | 6f 66 20 28 74 79 70 65 |ode{size|of (type|
|00002910| 29 7d 29 2c 20 69 73 20 | 40 76 61 72 7b 73 7d 2e |)}), is |@var{s}.|
|00002920| 0a 58 40 65 6e 64 20 64 | 65 66 74 79 70 65 66 6e |.X@end d|eftypefn|
|00002930| 0a 58 0a 54 68 65 20 6d | 65 74 68 6f 64 73 20 71 |.X.The m|ethods q|
|00002940| 75 65 72 79 20 74 68 65 | 20 69 6e 66 6f 72 6d 61 |uery the| informa|
|00002950| 74 69 6f 6e 20 67 69 76 | 65 6e 20 74 6f 20 74 68 |tion giv|en to th|
|00002960| 65 20 63 6f 6e 73 74 72 | 75 63 74 6f 72 3a 0a 58 |e constr|uctor:.X|
|00002970| 0a 58 40 64 65 66 74 79 | 70 65 66 6e 20 4d 65 74 |.X@defty|pefn Met|
|00002980| 68 6f 64 20 78 64 72 70 | 72 6f 63 5f 74 20 50 72 |hod xdrp|roc_t Pr|
|00002990| 6f 63 20 28 29 20 63 6f | 6e 73 74 0a 52 65 74 75 |oc () co|nst.Retu|
|000029a0| 72 6e 20 74 68 65 20 63 | 6f 6e 76 65 72 73 69 6f |rn the c|onversio|
|000029b0| 6e 20 66 75 6e 63 74 69 | 6f 6e 20 73 74 6f 72 65 |n functi|on store|
|000029c0| 64 20 69 6e 20 61 6e 20 | 40 63 6f 64 65 7b 58 64 |d in an |@code{Xd|
|000029d0| 72 49 6e 66 6f 7d 2e 0a | 58 40 65 6e 64 20 64 65 |rInfo}..|X@end de|
|000029e0| 66 74 79 70 65 66 6e 0a | 58 0a 58 40 64 65 66 74 |ftypefn.|X.X@deft|
|000029f0| 79 70 65 66 6e 20 4d 65 | 74 68 6f 64 20 73 69 7a |ypefn Me|thod siz|
|00002a00| 65 5f 74 20 53 69 7a 65 | 20 28 29 20 63 6f 6e 73 |e_t Size| () cons|
|00002a10| 74 0a 52 65 74 75 72 6e | 20 74 68 65 20 73 69 7a |t.Return| the siz|
|00002a20| 65 20 6f 66 20 74 68 65 | 20 74 79 70 65 20 64 65 |e of the| type de|
|00002a30| 73 63 72 69 62 65 64 20 | 62 79 20 74 68 65 20 40 |scribed |by the @|
|00002a40| 63 6f 64 65 7b 58 64 72 | 49 6e 66 6f 7d 2e 0a 58 |code{Xdr|Info}..X|
|00002a50| 40 65 6e 64 20 64 65 66 | 74 79 70 65 66 6e 0a 58 |@end def|typefn.X|
|00002a60| 0a 54 68 65 72 65 20 61 | 72 65 20 61 20 6e 75 6d |.There a|re a num|
|00002a70| 62 65 72 20 6f 66 20 70 | 72 65 64 65 66 69 6e 65 |ber of p|redefine|
|00002a80| 64 20 40 63 6f 64 65 7b | 58 64 72 49 6e 66 6f 7d |d @code{|XdrInfo}|
|00002a90| 73 2e 20 54 68 65 79 20 | 61 72 65 20 64 65 66 69 |s. They |are defi|
|00002aa0| 6e 65 64 20 61 73 0a 73 | 74 61 74 69 63 20 6d 65 |ned as.s|tatic me|
|00002ab0| 6d 62 65 72 73 20 6f 66 | 20 61 20 63 6c 61 73 73 |mbers of| a class|
|00002ac0| 20 40 63 6f 64 65 7b 58 | 64 72 7d 20 66 6f 72 20 | @code{X|dr} for |
|00002ad0| 73 63 6f 70 69 6e 67 20 | 72 65 61 73 6f 6e 73 2e |scoping |reasons.|
|00002ae0| 0a 58 0a 58 40 64 65 66 | 76 72 20 58 64 72 49 6e |.X.X@def|vr XdrIn|
|00002af0| 66 6f 20 58 64 72 3a 3a | 58 63 68 61 72 0a 54 68 |fo Xdr::|Xchar.Th|
|00002b00| 65 20 63 6f 6e 76 65 72 | 73 69 6f 6e 20 61 6e 64 |e conver|sion and|
|00002b10| 20 73 69 7a 65 20 69 6e | 66 6f 72 6d 61 74 69 6f | size in|formatio|
|00002b20| 6e 20 66 6f 72 20 61 20 | 63 68 61 72 61 63 74 65 |n for a |characte|
|00002b30| 72 2e 0a 58 40 65 6e 64 | 20 64 65 66 76 72 0a 58 |r..X@end| defvr.X|
|00002b40| 0a 58 40 64 65 66 76 72 | 20 58 64 72 49 6e 66 6f |.X@defvr| XdrInfo|
|00002b50| 20 58 64 72 3a 3a 58 73 | 68 6f 72 74 0a 54 68 65 | Xdr::Xs|hort.The|
|00002b60| 20 63 6f 6e 76 65 72 73 | 69 6f 6e 20 61 6e 64 20 | convers|ion and |
|00002b70| 73 69 7a 65 20 69 6e 66 | 6f 72 6d 61 74 69 6f 6e |size inf|ormation|
|00002b80| 20 66 6f 72 20 61 20 73 | 68 6f 72 74 20 69 6e 74 | for a s|hort int|
|00002b90| 65 67 65 72 2e 0a 58 40 | 65 6e 64 20 64 65 66 76 |eger..X@|end defv|
|00002ba0| 72 0a 58 0a 58 40 64 65 | 66 76 72 20 58 64 72 49 |r.X.X@de|fvr XdrI|
|00002bb0| 6e 66 6f 20 58 64 72 3a | 3a 58 69 6e 74 0a 54 68 |nfo Xdr:|:Xint.Th|
|00002bc0| 65 20 63 6f 6e 76 65 72 | 73 69 6f 6e 20 61 6e 64 |e conver|sion and|
|00002bd0| 20 73 69 7a 65 20 69 6e | 66 6f 72 6d 61 74 69 6f | size in|formatio|
|00002be0| 6e 20 66 6f 72 20 61 6e | 20 69 6e 74 65 67 65 72 |n for an| integer|
|00002bf0| 2e 0a 58 40 65 6e 64 20 | 64 65 66 76 72 0a 58 0a |..X@end |defvr.X.|
|00002c00| 58 40 64 65 66 76 72 20 | 58 64 72 49 6e 66 6f 20 |X@defvr |XdrInfo |
|00002c10| 58 64 72 3a 3a 58 6c 6f | 6e 67 0a 54 68 65 20 63 |Xdr::Xlo|ng.The c|
|00002c20| 6f 6e 76 65 72 73 69 6f | 6e 20 61 6e 64 20 73 69 |onversio|n and si|
|00002c30| 7a 65 20 69 6e 66 6f 72 | 6d 61 74 69 6f 6e 20 66 |ze infor|mation f|
|00002c40| 6f 72 20 61 20 6c 6f 6e | 67 20 69 6e 74 65 67 65 |or a lon|g intege|
|00002c50| 72 2e 0a 58 40 65 6e 64 | 20 64 65 66 76 72 0a 58 |r..X@end| defvr.X|
|00002c60| 0a 58 40 64 65 66 76 72 | 20 58 64 72 49 6e 66 6f |.X@defvr| XdrInfo|
|00002c70| 20 58 64 72 3a 3a 58 75 | 63 68 61 72 0a 54 68 65 | Xdr::Xu|char.The|
|00002c80| 20 63 6f 6e 76 65 72 73 | 69 6f 6e 20 61 6e 64 20 | convers|ion and |
|00002c90| 73 69 7a 65 20 69 6e 66 | 6f 72 6d 61 74 69 6f 6e |size inf|ormation|
|00002ca0| 20 66 6f 72 20 61 6e 20 | 75 6e 73 69 67 6e 65 64 | for an |unsigned|
|00002cb0| 20 63 68 61 72 61 63 74 | 65 72 2e 0a 58 40 65 6e | charact|er..X@en|
|00002cc0| 64 20 64 65 66 76 72 0a | 58 0a 58 40 64 65 66 76 |d defvr.|X.X@defv|
|00002cd0| 72 20 58 64 72 49 6e 66 | 6f 20 58 64 72 3a 3a 58 |r XdrInf|o Xdr::X|
|00002ce0| 75 73 68 6f 72 74 0a 54 | 68 65 20 63 6f 6e 76 65 |ushort.T|he conve|
|00002cf0| 72 73 69 6f 6e 20 61 6e | 64 20 73 69 7a 65 20 69 |rsion an|d size i|
|00002d00| 6e 66 6f 72 6d 61 74 69 | 6f 6e 20 66 6f 72 20 61 |nformati|on for a|
|00002d10| 6e 20 75 6e 73 69 67 6e | 65 64 20 73 68 6f 72 74 |n unsign|ed short|
|00002d20| 20 69 6e 74 65 67 65 72 | 2e 0a 58 40 65 6e 64 20 | integer|..X@end |
|00002d30| 64 65 66 76 72 0a 58 0a | 58 40 64 65 66 76 72 20 |defvr.X.|X@defvr |
|00002d40| 58 64 72 49 6e 66 6f 20 | 58 64 72 3a 3a 58 75 6c |XdrInfo |Xdr::Xul|
|00002d50| 6f 6e 67 0a 54 68 65 20 | 63 6f 6e 76 65 72 73 69 |ong.The |conversi|
|00002d60| 6f 6e 20 61 6e 64 20 73 | 69 7a 65 20 69 6e 66 6f |on and s|ize info|
|00002d70| 72 6d 61 74 69 6f 6e 20 | 66 6f 72 20 61 6e 20 75 |rmation |for an u|
|00002d80| 6e 73 69 67 6e 65 64 20 | 6c 6f 6e 67 20 69 6e 74 |nsigned |long int|
|00002d90| 65 67 65 72 2e 0a 58 40 | 65 6e 64 20 64 65 66 76 |eger..X@|end defv|
|00002da0| 72 0a 58 0a 58 40 64 65 | 66 76 72 20 58 64 72 49 |r.X.X@de|fvr XdrI|
|00002db0| 6e 66 6f 20 58 64 72 3a | 3a 58 66 6c 6f 61 74 0a |nfo Xdr:|:Xfloat.|
|00002dc0| 54 68 65 20 63 6f 6e 76 | 65 72 73 69 6f 6e 20 61 |The conv|ersion a|
|00002dd0| 6e 64 20 73 69 7a 65 20 | 69 6e 66 6f 72 6d 61 74 |nd size |informat|
|00002de0| 69 6f 6e 20 66 6f 72 20 | 61 20 66 6c 6f 61 74 2e |ion for |a float.|
|00002df0| 0a 58 40 65 6e 64 20 64 | 65 66 76 72 0a 58 0a 58 |.X@end d|efvr.X.X|
|00002e00| 40 64 65 66 76 72 20 58 | 64 72 49 6e 66 6f 20 58 |@defvr X|drInfo X|
|00002e10| 64 72 3a 3a 58 64 6f 75 | 62 6c 65 0a 54 68 65 20 |dr::Xdou|ble.The |
|00002e20| 63 6f 6e 76 65 72 73 69 | 6f 6e 20 61 6e 64 20 73 |conversi|on and s|
|00002e30| 69 7a 65 20 69 6e 66 6f | 72 6d 61 74 69 6f 6e 20 |ize info|rmation |
|00002e40| 66 6f 72 20 61 20 64 6f | 75 62 6c 65 2e 0a 58 40 |for a do|uble..X@|
|00002e50| 65 6e 64 20 64 65 66 76 | 72 0a 58 0a 58 40 64 65 |end defv|r.X.X@de|
|00002e60| 66 76 72 20 58 64 72 49 | 6e 66 6f 20 58 64 72 3a |fvr XdrI|nfo Xdr:|
|00002e70| 3a 58 65 6e 75 6d 5f 74 | 0a 54 68 65 20 63 6f 6e |:Xenum_t|.The con|
|00002e80| 76 65 72 73 69 6f 6e 20 | 61 6e 64 20 73 69 7a 65 |version |and size|
|00002e90| 20 69 6e 66 6f 72 6d 61 | 74 69 6f 6e 20 66 6f 72 | informa|tion for|
|00002ea0| 20 61 6e 79 20 65 6e 75 | 6d 65 72 61 74 69 6f 6e | any enu|meration|
|00002eb0| 20 74 79 70 65 2e 0a 58 | 40 65 6e 64 20 64 65 66 | type..X|@end def|
|00002ec0| 76 72 0a 58 0a 58 40 64 | 65 66 76 72 20 58 64 72 |vr.X.X@d|efvr Xdr|
|00002ed0| 49 6e 66 6f 20 58 64 72 | 3a 3a 58 62 6f 6f 6c 5f |Info Xdr|::Xbool_|
|00002ee0| 74 0a 54 68 65 20 63 6f | 6e 76 65 72 73 69 6f 6e |t.The co|nversion|
|00002ef0| 20 61 6e 64 20 73 69 7a | 65 20 69 6e 66 6f 72 6d | and siz|e inform|
|00002f00| 61 74 69 6f 6e 20 66 6f | 72 20 61 20 62 6f 6f 6c |ation fo|r a bool|
|00002f10| 2e 0a 58 40 65 6e 64 20 | 64 65 66 76 72 0a 58 0a |..X@end |defvr.X.|
|00002f20| 58 40 64 65 66 76 72 20 | 58 64 72 49 6e 66 6f 20 |X@defvr |XdrInfo |
|00002f30| 58 64 72 3a 3a 58 76 6f | 69 64 0a 41 20 73 70 65 |Xdr::Xvo|id.A spe|
|00002f40| 63 69 61 6c 20 40 63 6f | 64 65 7b 58 64 72 49 6e |cial @co|de{XdrIn|
|00002f50| 66 6f 7d 20 66 6f 72 20 | 74 68 65 20 72 65 74 75 |fo} for |the retu|
|00002f60| 72 6e 20 74 79 70 65 20 | 6f 66 20 61 20 70 72 6f |rn type |of a pro|
|00002f70| 63 65 64 75 72 65 20 74 | 68 61 74 20 72 65 74 75 |cedure t|hat retu|
|00002f80| 72 6e 73 0a 6e 6f 74 68 | 69 6e 67 2e 0a 58 40 65 |rns.noth|ing..X@e|
|00002f90| 6e 64 20 64 65 66 76 72 | 0a 58 0a 58 40 64 65 66 |nd defvr|.X.X@def|
|00002fa0| 76 72 20 58 64 72 49 6e | 66 6f 20 58 64 72 3a 3a |vr XdrIn|fo Xdr::|
|00002fb0| 58 6e 75 6c 6c 0a 41 20 | 73 70 65 63 69 61 6c 20 |Xnull.A |special |
|00002fc0| 40 63 6f 64 65 7b 58 64 | 72 49 6e 66 6f 7d 20 66 |@code{Xd|rInfo} f|
|00002fd0| 6f 72 20 74 68 65 20 72 | 65 74 75 72 6e 20 74 79 |or the r|eturn ty|
|00002fe0| 70 65 20 6f 66 20 61 20 | 70 72 6f 63 65 64 75 72 |pe of a |procedur|
|00002ff0| 65 20 74 68 61 74 20 69 | 73 20 74 6f 0a 62 65 20 |e that i|s to.be |
|00003000| 65 78 65 63 75 74 65 64 | 20 62 61 74 63 68 65 64 |executed| batched|
|00003010| 20 6f 72 20 61 73 79 6e | 63 68 72 6f 6e 6f 75 73 | or asyn|chronous|
|00003020| 6c 79 20 28 40 70 78 72 | 65 66 7b 52 70 63 52 65 |ly (@pxr|ef{RpcRe|
|00003030| 71 75 65 73 74 7d 29 2e | 0a 58 40 65 6e 64 20 64 |quest}).|.X@end d|
|00003040| 65 66 76 72 0a 58 0a 58 | 40 70 61 67 65 0a 58 40 |efvr.X.X|@page.X@|
|00003050| 6e 6f 64 65 20 20 20 20 | 52 70 63 52 65 71 75 65 |node |RpcReque|
|00003060| 73 74 2c 20 43 61 6c 6c | 62 61 63 6b 73 2c 20 58 |st, Call|backs, X|
|00003070| 64 72 49 6e 66 6f 2c 20 | 43 6c 61 73 73 65 73 0a |drInfo, |Classes.|
|00003080| 58 40 63 6f 6d 6d 65 6e | 74 20 6e 6f 64 65 2d 6e |X@commen|t node-n|
|00003090| 61 6d 65 2c 20 20 20 20 | 20 6e 65 78 74 2c 20 20 |ame, | next, |
|000030a0| 20 20 20 20 20 20 20 20 | 20 70 72 65 76 69 6f 75 | | previou|
|000030b0| 73 2c 20 75 70 0a 58 40 | 73 65 63 74 69 6f 6e 20 |s, up.X@|section |
|000030c0| 40 63 6f 64 65 7b 52 70 | 63 52 65 71 75 65 73 74 |@code{Rp|cRequest|
|000030d0| 7d 0a 58 40 63 69 6e 64 | 65 78 20 40 63 6f 64 65 |}.X@cind|ex @code|
|000030e0| 7b 52 70 63 52 65 71 75 | 65 73 74 7d 0a 58 0a 44 |{RpcRequ|est}.X.D|
|000030f0| 65 63 6c 61 72 65 64 20 | 69 6e 3a 20 40 63 6f 64 |eclared |in: @cod|
|00003100| 65 7b 22 72 70 63 2b 2b | 2f 72 65 71 75 65 73 74 |e{"rpc++|/request|
|00003110| 2e 68 22 7d 0a 58 0a 58 | 40 64 65 66 74 70 20 43 |.h"}.X.X|@deftp C|
|00003120| 6c 61 73 73 20 52 70 63 | 52 65 71 75 65 73 74 0a |lass Rpc|Request.|
|00003130| 52 70 63 52 65 71 75 65 | 73 74 20 69 73 20 61 20 |RpcReque|st is a |
|00003140| 63 6c 61 73 73 20 74 68 | 61 74 20 73 70 65 63 69 |class th|at speci|
|00003150| 66 69 65 73 20 61 20 72 | 65 71 75 65 73 74 20 66 |fies a r|equest f|
|00003160| 6f 72 20 61 20 70 72 6f | 63 65 64 75 72 65 20 74 |or a pro|cedure t|
|00003170| 68 61 74 20 69 73 0a 70 | 61 72 74 20 6f 66 20 28 |hat is.p|art of (|
|00003180| 72 65 67 69 73 74 65 72 | 65 64 20 77 69 74 68 29 |register|ed with)|
|00003190| 20 61 20 73 65 72 76 69 | 63 65 2e 0a 58 40 65 6e | a servi|ce..X@en|
|000031a0| 64 20 64 65 66 74 70 0a | 58 0a 54 68 65 72 65 20 |d deftp.|X.There |
|000031b0| 61 72 65 20 73 65 76 65 | 72 61 6c 20 63 6f 6e 73 |are seve|ral cons|
|000031c0| 74 72 75 63 74 6f 72 73 | 20 66 6f 72 20 40 63 6f |tructors| for @co|
|000031d0| 64 65 7b 52 70 63 52 65 | 71 75 65 73 74 7d 2e 20 |de{RpcRe|quest}. |
|000031e0| 54 68 65 79 20 76 61 72 | 79 20 69 6e 20 74 68 65 |They var|y in the|
|000031f0| 0a 6e 75 6d 62 65 72 20 | 6f 66 20 40 63 6f 64 65 |.number |of @code|
|00003200| 7b 58 64 72 49 6e 66 6f | 7d 73 20 75 73 65 64 20 |{XdrInfo|}s used |
|00003210| 74 6f 20 64 65 73 63 72 | 69 62 65 20 74 68 65 20 |to descr|ibe the |
|00003220| 69 6e 70 75 74 20 70 61 | 72 61 6d 65 74 65 72 73 |input pa|rameters|
|00003230| 20 6f 66 20 74 68 65 0a | 70 72 6f 63 65 64 75 72 | of the.|procedur|
|00003240| 65 2e 0a 58 0a 58 40 64 | 65 66 74 79 70 65 66 6e |e..X.X@d|eftypefn|
|00003250| 20 43 6f 6e 73 74 72 75 | 63 74 6f 72 20 7b 7d 20 | Constru|ctor {} |
|00003260| 52 70 63 52 65 71 75 65 | 73 74 20 28 75 5f 6c 6f |RpcReque|st (u_lo|
|00003270| 6e 67 20 40 76 61 72 7b | 72 65 71 69 64 7d 2c 20 |ng @var{|reqid}, |
|00003280| 63 6f 6e 73 74 20 58 64 | 72 49 6e 66 6f 2a 20 40 |const Xd|rInfo* @|
|00003290| 76 61 72 7b 6f 75 74 7d | 2c 20 52 65 71 54 79 70 |var{out}|, ReqTyp|
|000032a0| 65 20 40 76 61 72 7b 74 | 7d 3d 6e 6f 72 6d 61 6c |e @var{t|}=normal|
|000032b0| 29 0a 58 40 65 6e 64 20 | 64 65 66 74 79 70 65 66 |).X@end |deftypef|
|000032c0| 6e 0a 58 40 64 65 66 74 | 79 70 65 66 6e 20 43 6f |n.X@deft|ypefn Co|
|000032d0| 6e 73 74 72 75 63 74 6f | 72 20 7b 7d 20 52 70 63 |nstructo|r {} Rpc|
|000032e0| 52 65 71 75 65 73 74 20 | 28 75 5f 6c 6f 6e 67 20 |Request |(u_long |
|000032f0| 40 76 61 72 7b 72 65 71 | 69 64 7d 2c 20 63 6f 6e |@var{req|id}, con|
|00003300| 73 74 20 58 64 72 49 6e | 66 6f 2a 20 40 76 61 72 |st XdrIn|fo* @var|
|00003310| 7b 6f 75 74 7d 2c 20 63 | 6f 6e 73 74 20 58 64 72 |{out}, c|onst Xdr|
|00003320| 49 6e 66 6f 2a 20 40 76 | 61 72 7b 69 6e 31 7d 2c |Info* @v|ar{in1},|
|00003330| 20 52 65 71 54 79 70 65 | 20 40 76 61 72 7b 74 7d | ReqType| @var{t}|
|00003340| 3d 6e 6f 72 6d 61 6c 29 | 0a 58 40 65 6e 64 20 64 |=normal)|.X@end d|
|00003350| 65 66 74 79 70 65 66 6e | 0a 58 40 64 65 66 74 79 |eftypefn|.X@defty|
|00003360| 70 65 66 6e 20 43 6f 6e | 73 74 72 75 63 74 6f 72 |pefn Con|structor|
|00003370| 20 7b 7d 20 52 70 63 52 | 65 71 75 65 73 74 20 28 | {} RpcR|equest (|
|00003380| 75 5f 6c 6f 6e 67 20 40 | 76 61 72 7b 72 65 71 69 |u_long @|var{reqi|
|00003390| 64 7d 2c 20 63 6f 6e 73 | 74 20 58 64 72 49 6e 66 |d}, cons|t XdrInf|
|000033a0| 6f 2a 20 40 76 61 72 7b | 6f 75 74 7d 2c 20 63 6f |o* @var{|out}, co|
|000033b0| 6e 73 74 20 58 64 72 49 | 6e 66 6f 2a 20 40 76 61 |nst XdrI|nfo* @va|
|000033c0| 72 7b 69 6e 31 7d 2c 20 | 63 6f 6e 73 74 20 58 64 |r{in1}, |const Xd|
|000033d0| 72 49 6e 66 6f 2a 20 40 | 76 61 72 7b 69 6e 32 7d |rInfo* @|var{in2}|
|000033e0| 2c 20 52 65 71 54 79 70 | 65 20 40 76 61 72 7b 74 |, ReqTyp|e @var{t|
|000033f0| 7d 3d 6e 6f 72 6d 61 6c | 29 0a 54 68 65 73 65 20 |}=normal|).These |
|00003400| 63 6f 6e 73 74 72 75 63 | 74 6f 72 73 20 63 6f 6e |construc|tors con|
|00003410| 73 74 72 75 63 74 20 61 | 6e 20 40 63 6f 64 65 7b |struct a|n @code{|
|00003420| 52 70 63 52 65 71 75 65 | 73 74 7d 20 66 6f 72 20 |RpcReque|st} for |
|00003430| 61 20 70 72 6f 63 65 64 | 75 72 65 20 77 69 74 68 |a proced|ure with|
|00003440| 0a 7a 65 72 6f 2c 20 6f | 6e 65 20 6f 72 20 74 77 |.zero, o|ne or tw|
|00003450| 6f 20 61 72 67 75 6d 65 | 6e 74 73 2e 20 41 64 64 |o argume|nts. Add|
|00003460| 69 74 69 6f 6e 61 6c 20 | 73 69 6d 69 6c 61 72 20 |itional |similar |
|00003470| 63 6f 6e 73 74 72 75 63 | 74 6f 72 73 20 61 72 65 |construc|tors are|
|00003480| 20 64 65 66 69 6e 65 64 | 0a 66 6f 72 20 70 72 6f | defined|.for pro|
|00003490| 63 65 64 75 72 65 73 20 | 77 69 74 68 20 75 70 20 |cedures |with up |
|000034a0| 74 6f 20 73 65 76 65 6e | 20 61 72 67 75 6d 65 6e |to seven| argumen|
|000034b0| 74 73 2e 20 40 76 61 72 | 7b 72 65 71 69 64 7d 20 |ts. @var|{reqid} |
|000034c0| 75 6e 69 71 75 65 6c 79 | 0a 69 64 65 6e 74 69 66 |uniquely|.identif|
|000034d0| 69 65 73 20 74 68 65 20 | 72 65 71 75 65 73 74 20 |ies the |request |
|000034e0| 28 74 68 65 20 70 72 6f | 63 65 64 75 72 65 20 6f |(the pro|cedure o|
|000034f0| 66 20 74 68 65 20 73 65 | 72 76 65 72 29 2e 20 40 |f the se|rver). @|
|00003500| 76 61 72 7b 72 65 71 69 | 64 7d 20 6d 61 79 0a 6e |var{reqi|d} may.n|
|00003510| 6f 74 20 62 65 20 30 2e | 20 54 68 65 20 40 63 6f |ot be 0.| The @co|
|00003520| 64 65 7b 58 64 72 49 6e | 66 6f 2a 7d 73 20 66 6f |de{XdrIn|fo*}s fo|
|00003530| 6c 6c 6f 77 69 6e 67 20 | 40 76 61 72 7b 72 65 71 |llowing |@var{req|
|00003540| 69 64 7d 20 73 70 65 63 | 69 66 79 20 74 68 65 20 |id} spec|ify the |
|00003550| 74 79 70 65 73 20 6f 66 | 0a 74 68 65 20 69 6e 70 |types of|.the inp|
|00003560| 75 74 20 70 61 72 61 6d | 65 74 65 72 73 2e 20 54 |ut param|eters. T|
|00003570| 68 65 79 20 61 72 65 20 | 66 6f 6c 6c 6f 77 65 64 |hey are |followed|
|00003580| 20 62 79 20 74 68 65 20 | 40 63 6f 64 65 7b 58 64 | by the |@code{Xd|
|00003590| 72 49 6e 66 6f 2a 7d 20 | 74 68 61 74 0a 64 65 73 |rInfo*} |that.des|
|000035a0| 63 72 69 62 65 73 20 74 | 68 65 20 74 79 70 65 20 |cribes t|he type |
|000035b0| 6f 66 20 74 68 65 20 76 | 61 6c 75 65 20 72 65 74 |of the v|alue ret|
|000035c0| 75 72 6e 65 64 20 62 79 | 20 74 68 65 20 52 50 43 |urned by| the RPC|
|000035d0| 2e 20 49 66 20 6e 6f 20 | 76 61 6c 75 65 20 69 73 |. If no |value is|
|000035e0| 0a 72 65 74 75 72 6e 65 | 64 2c 20 40 63 6f 64 65 |.returne|d, @code|
|000035f0| 7b 26 58 64 72 3a 3a 58 | 76 6f 69 64 7d 20 6d 75 |{&Xdr::X|void} mu|
|00003600| 73 74 20 62 65 20 67 69 | 76 65 6e 20 61 73 20 61 |st be gi|ven as a|
|00003610| 72 67 75 6d 65 6e 74 0a | 58 28 40 70 78 72 65 66 |rgument.|X(@pxref|
|00003620| 7b 58 64 72 49 6e 66 6f | 7d 29 2e 20 54 68 65 20 |{XdrInfo|}). The |
|00003630| 66 69 6e 61 6c 20 6f 70 | 74 69 6f 6e 61 6c 20 61 |final op|tional a|
|00003640| 72 67 75 6d 65 6e 74 20 | 40 76 61 72 7b 74 7d 20 |rgument |@var{t} |
|00003650| 73 70 65 63 69 66 69 65 | 73 20 74 68 65 0a 63 61 |specifie|s the.ca|
|00003660| 6c 6c 20 6d 6f 64 65 3a | 20 40 63 6f 64 65 7b 52 |ll mode:| @code{R|
|00003670| 70 63 52 65 71 75 65 73 | 74 3a 3a 6e 6f 72 6d 61 |pcReques|t::norma|
|00003680| 6c 7d 2c 20 40 63 6f 64 | 65 7b 52 70 63 52 65 71 |l}, @cod|e{RpcReq|
|00003690| 75 65 73 74 3a 3a 62 61 | 74 63 68 65 64 7d 20 6f |uest::ba|tched} o|
|000036a0| 72 0a 58 40 63 6f 64 65 | 7b 52 70 63 52 65 71 75 |r.X@code|{RpcRequ|
|000036b0| 65 73 74 3a 3a 61 73 79 | 6e 63 7d 20 28 73 65 65 |est::asy|nc} (see|
|000036c0| 20 62 65 6c 6f 77 29 2e | 0a 58 40 65 6e 64 20 64 | below).|.X@end d|
|000036d0| 65 66 74 79 70 65 66 6e | 0a 58 0a 58 40 64 65 66 |eftypefn|.X.X@def|
|000036e0| 74 79 70 65 66 6e 20 43 | 6f 6e 73 74 72 75 63 74 |typefn C|onstruct|
|000036f0| 6f 72 20 7b 7d 20 52 70 | 63 52 65 71 75 65 73 74 |or {} Rp|cRequest|
|00003700| 20 28 75 5f 6c 6f 6e 67 | 20 40 76 61 72 7b 72 65 | (u_long| @var{re|
|00003710| 71 69 64 7d 2c 20 63 6f | 6e 73 74 20 58 64 72 49 |qid}, co|nst XdrI|
|00003720| 6e 66 6f 2a 20 40 76 61 | 72 7b 6f 75 74 7d 2c 20 |nfo* @va|r{out}, |
|00003730| 63 6f 6e 73 74 20 58 64 | 72 49 6e 66 6f 2a 2a 20 |const Xd|rInfo** |
|00003740| 40 76 61 72 7b 69 6e 74 | 79 70 65 73 7d 2c 20 52 |@var{int|ypes}, R|
|00003750| 65 71 54 79 70 65 20 40 | 76 61 72 7b 74 7d 3d 6e |eqType @|var{t}=n|
|00003760| 6f 72 6d 61 6c 29 0a 54 | 68 69 73 20 63 6f 6e 73 |ormal).T|his cons|
|00003770| 74 72 75 63 74 6f 72 20 | 63 61 6e 20 62 65 20 75 |tructor |can be u|
|00003780| 73 65 64 20 74 6f 20 63 | 6f 6e 73 74 72 75 63 74 |sed to c|onstruct|
|00003790| 20 61 6e 20 40 63 6f 64 | 65 7b 52 70 63 52 65 71 | an @cod|e{RpcReq|
|000037a0| 75 65 73 74 7d 20 77 69 | 74 68 20 61 6e 0a 61 72 |uest} wi|th an.ar|
|000037b0| 62 69 74 72 61 72 79 20 | 6e 75 6d 62 65 72 20 6f |bitrary |number o|
|000037c0| 66 20 61 72 67 75 6d 65 | 6e 74 73 2e 20 54 68 65 |f argume|nts. The|
|000037d0| 20 70 6f 69 6e 74 65 72 | 73 20 74 6f 20 40 63 6f | pointer|s to @co|
|000037e0| 64 65 7b 58 64 72 49 6e | 66 6f 7d 20 61 72 65 20 |de{XdrIn|fo} are |
|000037f0| 70 61 73 73 65 64 0a 69 | 6e 20 61 6e 20 61 72 72 |passed.i|n an arr|
|00003800| 61 79 2e 20 54 68 65 20 | 6e 75 6d 62 65 72 20 6f |ay. The |number o|
|00003810| 66 20 65 6c 65 6d 65 6e | 74 73 20 69 6e 20 74 68 |f elemen|ts in th|
|00003820| 65 20 61 72 72 61 79 20 | 6d 75 73 74 20 62 65 20 |e array |must be |
|00003830| 6f 6e 65 20 6d 6f 72 65 | 20 74 68 61 6e 0a 74 68 |one more| than.th|
|00003840| 65 20 6e 75 6d 62 65 72 | 20 6f 66 20 70 61 72 61 |e number| of para|
|00003850| 6d 65 74 65 72 73 20 61 | 6e 64 20 74 68 65 20 6c |meters a|nd the l|
|00003860| 61 73 74 20 65 6c 65 6d | 65 6e 74 20 6d 75 73 74 |ast elem|ent must|
|00003870| 20 62 65 20 7a 65 72 6f | 2e 0a 58 40 65 6e 64 20 | be zero|..X@end |
|00003880| 64 65 66 74 79 70 65 66 | 6e 0a 58 0a 49 66 20 74 |deftypef|n.X.If t|
|00003890| 68 65 20 72 65 71 75 65 | 73 74 20 74 79 70 65 20 |he reque|st type |
|000038a0| 40 76 61 72 7b 74 7d 20 | 69 73 20 40 63 6f 64 65 |@var{t} |is @code|
|000038b0| 7b 52 70 63 52 65 71 75 | 65 73 74 3a 3a 6e 6f 72 |{RpcRequ|est::nor|
|000038c0| 6d 61 6c 7d 2c 20 6d 65 | 74 68 6f 64 0a 58 40 63 |mal}, me|thod.X@c|
|000038d0| 6f 64 65 7b 43 61 6c 6c | 7d 20 28 40 70 78 72 65 |ode{Call|} (@pxre|
|000038e0| 66 7b 52 70 63 53 74 75 | 62 7d 29 20 61 73 73 65 |f{RpcStu|b}) asse|
|000038f0| 6d 62 6c 65 73 20 74 68 | 65 20 6d 65 73 73 61 67 |mbles th|e messag|
|00003900| 65 20 74 6f 20 74 68 65 | 20 73 65 72 76 65 72 2c |e to the| server,|
|00003910| 20 73 65 6e 64 73 0a 69 | 74 2c 20 77 61 69 74 73 | sends.i|t, waits|
|00003920| 20 66 6f 72 20 61 20 72 | 65 70 6c 79 20 61 6e 64 | for a r|eply and|
|00003930| 20 72 65 74 75 72 6e 73 | 20 74 68 65 20 72 65 73 | returns| the res|
|00003940| 75 6c 74 2e 0a 58 0a 49 | 66 20 74 68 65 20 72 65 |ult..X.I|f the re|
|00003950| 71 75 65 73 74 20 74 79 | 70 65 20 69 73 20 40 63 |quest ty|pe is @c|
|00003960| 6f 64 65 7b 52 70 63 52 | 65 71 75 65 73 74 3a 3a |ode{RpcR|equest::|
|00003970| 62 61 74 63 68 65 64 7d | 2c 20 6d 65 74 68 6f 64 |batched}|, method|
|00003980| 0a 58 40 63 6f 64 65 7b | 52 70 63 53 74 75 62 3a |.X@code{|RpcStub:|
|00003990| 3a 43 61 6c 6c 7d 20 61 | 73 73 65 6d 62 6c 65 73 |:Call} a|ssembles|
|000039a0| 20 74 68 65 20 6d 65 73 | 73 61 67 65 20 74 6f 20 | the mes|sage to |
|000039b0| 74 68 65 20 73 65 72 76 | 65 72 20 61 6e 64 20 70 |the serv|er and p|
|000039c0| 75 74 73 20 69 74 20 69 | 6e 0a 61 20 62 75 66 66 |uts it i|n.a buff|
|000039d0| 65 72 2e 20 4d 65 73 73 | 61 67 65 73 20 61 72 65 |er. Mess|ages are|
|000039e0| 20 6f 6e 6c 79 20 66 6c | 75 73 68 65 64 20 69 66 | only fl|ushed if|
|000039f0| 20 74 68 65 20 62 75 66 | 66 65 72 20 69 73 20 66 | the buf|fer is f|
|00003a00| 75 6c 6c 20 6f 72 0a 58 | 40 63 6f 64 65 7b 52 70 |ull or.X|@code{Rp|
|00003a10| 63 53 74 75 62 3a 3a 43 | 61 6c 6c 7d 20 69 73 20 |cStub::C|all} is |
|00003a20| 75 73 65 64 20 77 69 74 | 68 20 61 20 40 63 6f 64 |used wit|h a @cod|
|00003a30| 65 7b 6e 6f 72 6d 61 6c | 7d 20 6f 72 20 40 63 6f |e{normal|} or @co|
|00003a40| 64 65 7b 61 73 79 6e 63 | 7d 0a 72 65 71 75 65 73 |de{async|}.reques|
|00003a50| 74 2e 0a 58 0a 49 66 20 | 74 68 65 20 72 65 71 75 |t..X.If |the requ|
|00003a60| 65 73 74 20 74 79 70 65 | 20 69 73 20 40 63 6f 64 |est type| is @cod|
|00003a70| 65 7b 52 70 63 52 65 71 | 75 65 73 74 3a 3a 61 73 |e{RpcReq|uest::as|
|00003a80| 79 6e 63 7d 2c 20 6d 65 | 74 68 6f 64 0a 58 40 63 |ync}, me|thod.X@c|
|00003a90| 6f 64 65 7b 52 70 63 53 | 74 75 62 3a 3a 43 61 6c |ode{RpcS|tub::Cal|
|00003aa0| 6c 7d 20 28 40 70 78 72 | 65 66 7b 52 70 63 53 74 |l} (@pxr|ef{RpcSt|
|00003ab0| 75 62 7d 29 20 61 73 73 | 65 6d 62 6c 65 73 20 74 |ub}) ass|embles t|
|00003ac0| 68 65 20 6d 65 73 73 61 | 67 65 20 74 6f 20 74 68 |he messa|ge to th|
|00003ad0| 65 0a 73 65 72 76 65 72 | 20 61 6e 64 20 73 65 6e |e.server| and sen|
|00003ae0| 64 73 20 69 74 2c 20 61 | 73 20 77 69 74 68 20 40 |ds it, a|s with @|
|00003af0| 63 6f 64 65 7b 6e 6f 72 | 6d 61 6c 7d 2e 20 49 74 |code{nor|mal}. It|
|00003b00| 20 64 6f 65 73 2c 20 68 | 6f 77 65 76 65 72 2c 20 | does, h|owever, |
|00003b10| 6e 6f 74 20 77 61 69 74 | 0a 66 6f 72 20 61 20 72 |not wait|.for a r|
|00003b20| 65 73 75 6c 74 2e 20 4d | 6f 64 65 20 40 63 6f 64 |esult. M|ode @cod|
|00003b30| 65 7b 61 73 79 6e 63 7d | 20 69 73 20 69 6d 70 6c |e{async}| is impl|
|00003b40| 65 6d 65 6e 74 65 64 20 | 62 79 20 63 61 6c 6c 69 |emented |by calli|
|00003b50| 6e 67 20 74 68 65 20 75 | 6e 64 65 72 6c 79 69 6e |ng the u|nderlyin|
|00003b60| 67 0a 52 50 43 2d 2d 66 | 75 6e 63 74 69 6f 6e 20 |g.RPC--f|unction |
|00003b70| 40 63 6f 64 65 7b 63 6c | 6e 74 5f 63 61 6c 6c 7d |@code{cl|nt_call}|
|00003b80| 20 77 69 74 68 20 61 20 | 74 69 6d 65 6f 75 74 20 | with a |timeout |
|00003b90| 6f 66 20 7a 65 72 6f 2e | 0a 58 0a 41 73 20 69 6e |of zero.|.X.As in|
|00003ba0| 20 62 6f 74 68 20 6e 6f | 6e 2d 2d 6e 6f 72 6d 61 | both no|n--norma|
|00003bb0| 6c 20 63 61 73 65 73 20 | 28 40 63 6f 64 65 7b 62 |l cases |(@code{b|
|00003bc0| 61 74 63 68 65 64 7d 20 | 61 6e 64 20 40 63 6f 64 |atched} |and @cod|
|00003bd0| 65 7b 61 73 79 6e 63 7d | 29 0a 58 40 63 6f 64 65 |e{async}|).X@code|
|00003be0| 7b 52 70 63 53 74 75 62 | 3a 3a 43 61 6c 6c 7d 20 |{RpcStub|::Call} |
|00003bf0| 64 6f 65 73 20 6e 6f 74 | 20 77 61 69 74 20 66 6f |does not| wait fo|
|00003c00| 72 20 61 20 72 65 74 75 | 72 6e 20 76 61 6c 75 65 |r a retu|rn value|
|00003c10| 20 66 72 6f 6d 20 74 68 | 65 20 73 65 72 76 65 72 | from th|e server|
|00003c20| 2c 0a 74 68 65 20 72 65 | 74 75 72 6e 20 74 79 70 |,.the re|turn typ|
|00003c30| 65 20 6f 66 20 74 68 65 | 20 40 63 6f 64 65 7b 52 |e of the| @code{R|
|00003c40| 70 63 52 65 71 75 65 73 | 74 7d 20 6d 75 73 74 20 |pcReques|t} must |
|00003c50| 62 65 20 73 70 65 63 69 | 66 69 65 64 20 61 73 0a |be speci|fied as.|
|00003c60| 58 40 63 6f 64 65 7b 26 | 58 64 72 3a 3a 58 6e 75 |X@code{&|Xdr::Xnu|
|00003c70| 6c 6c 7d 2e 0a 58 0a 4e | 6f 74 65 20 74 68 61 74 |ll}..X.N|ote that|
|00003c80| 20 72 65 71 75 65 73 74 | 73 20 74 68 61 74 20 61 | request|s that a|
|00003c90| 72 65 20 72 65 67 69 73 | 74 65 72 65 64 20 66 6f |re regis|tered fo|
|00003ca0| 72 20 61 20 73 65 72 76 | 69 63 65 20 61 72 65 20 |r a serv|ice are |
|00003cb0| 73 74 6f 72 65 64 20 69 | 6e 20 61 6e 0a 61 72 72 |stored i|n an.arr|
|00003cc0| 61 79 20 75 73 69 6e 67 | 20 74 68 65 20 72 65 71 |ay using| the req|
|00003cd0| 75 65 73 74 20 69 64 65 | 6e 74 69 66 69 63 61 74 |uest ide|ntificat|
|00003ce0| 69 6f 6e 20 61 73 20 74 | 68 65 20 69 6e 64 65 78 |ion as t|he index|
|00003cf0| 2c 20 73 6f 20 6b 65 65 | 70 20 69 64 73 20 73 6d |, so kee|p ids sm|
|00003d00| 61 6c 6c 2e 0a 58 0a 4e | 6f 72 6d 61 6c 6c 79 2c |all..X.N|ormally,|
|00003d10| 20 72 65 71 75 65 73 74 | 73 20 73 68 6f 75 6c 64 | request|s should|
|00003d20| 20 62 65 20 73 70 65 63 | 69 66 69 65 64 20 69 6e | be spec|ified in|
|00003d30| 20 61 20 68 65 61 64 65 | 72 20 66 69 6c 65 20 69 | a heade|r file i|
|00003d40| 6e 63 6c 75 64 65 64 20 | 62 79 20 62 6f 74 68 0a |ncluded |by both.|
|00003d50| 74 68 65 20 73 65 72 76 | 65 72 20 61 6e 64 20 74 |the serv|er and t|
|00003d60| 68 65 20 63 6c 69 65 6e | 74 20 70 72 6f 67 72 61 |he clien|t progra|
|00003d70| 6d 20 28 40 70 78 72 65 | 66 7b 4d 61 74 63 68 69 |m (@pxre|f{Matchi|
|00003d80| 6e 67 20 73 65 72 76 65 | 72 20 61 6e 64 20 63 6c |ng serve|r and cl|
|00003d90| 69 65 6e 74 73 7d 29 2e | 0a 58 0a 58 40 70 61 67 |ients}).|.X.X@pag|
|00003da0| 65 0a 58 40 6e 6f 64 65 | 20 20 20 20 43 61 6c 6c |e.X@node| Call|
|00003db0| 62 61 63 6b 73 2c 20 52 | 70 63 53 65 72 76 69 63 |backs, R|pcServic|
|00003dc0| 65 2c 20 52 70 63 52 65 | 71 75 65 73 74 2c 20 43 |e, RpcRe|quest, C|
|00003dd0| 6c 61 73 73 65 73 0a 58 | 40 63 6f 6d 6d 65 6e 74 |lasses.X|@comment|
|00003de0| 20 6e 6f 64 65 2d 6e 61 | 6d 65 2c 20 20 20 20 20 | node-na|me, |
|00003df0| 6e 65 78 74 2c 20 20 20 | 20 20 20 20 20 20 20 20 |next, | |
|00003e00| 70 72 65 76 69 6f 75 73 | 2c 20 75 70 0a 58 40 73 |previous|, up.X@s|
|00003e10| 65 63 74 69 6f 6e 20 43 | 61 6c 6c 62 61 63 6b 73 |ection C|allbacks|
|00003e20| 0a 58 40 63 69 6e 64 65 | 78 20 43 61 6c 6c 62 61 |.X@cinde|x Callba|
|00003e30| 63 6b 73 0a 58 0a 49 66 | 20 61 20 73 65 72 76 65 |cks.X.If| a serve|
|00003e40| 72 20 72 65 63 65 69 76 | 65 73 20 61 20 72 65 71 |r receiv|es a req|
|00003e50| 75 65 73 74 20 66 72 6f | 6d 20 61 20 63 6c 69 65 |uest fro|m a clie|
|00003e60| 6e 74 2c 20 69 74 20 6e | 65 65 64 73 20 74 6f 20 |nt, it n|eeds to |
|00003e70| 6b 6e 6f 77 20 68 6f 77 | 20 61 0a 70 61 72 74 69 |know how| a.parti|
|00003e80| 63 75 6c 61 72 20 70 72 | 6f 63 65 64 75 72 65 20 |cular pr|ocedure |
|00003e90| 69 73 20 74 6f 20 62 65 | 20 69 6e 76 6f 6b 65 64 |is to be| invoked|
|00003ea0| 2e 20 54 68 69 73 20 69 | 6e 66 6f 72 6d 61 74 69 |. This i|nformati|
|00003eb0| 6f 6e 20 69 73 20 73 70 | 65 63 69 66 69 65 64 0a |on is sp|ecified.|
|00003ec0| 75 73 69 6e 67 20 6f 62 | 6a 65 63 74 73 20 40 63 |using ob|jects @c|
|00003ed0| 6f 64 65 7b 52 70 63 43 | 61 6c 6c 62 61 63 6b 7d |ode{RpcC|allback}|
|00003ee0| 20 6f 72 20 40 63 6f 64 | 65 7b 52 70 63 4d 65 74 | or @cod|e{RpcMet|
|00003ef0| 68 6f 64 43 61 6c 6c 7d | 20 77 68 65 6e 20 74 68 |hodCall}| when th|
|00003f00| 65 0a 70 72 6f 63 65 64 | 75 72 65 20 72 65 73 70 |e.proced|ure resp|
|00003f10| 2e 40 20 6d 65 74 68 6f | 64 20 69 73 20 73 70 65 |.@ metho|d is spe|
|00003f20| 63 69 66 69 65 64 2e 0a | 58 0a 54 68 65 20 63 6c |cified..|X.The cl|
|00003f30| 61 73 73 0a 58 40 64 65 | 66 74 70 20 43 6c 61 73 |ass.X@de|ftp Clas|
|00003f40| 73 20 41 6e 79 52 70 63 | 43 61 6c 6c 62 61 63 6b |s AnyRpc|Callback|
|00003f50| 0a 58 40 65 6e 64 20 64 | 65 66 74 70 0a 73 65 72 |.X@end d|eftp.ser|
|00003f60| 76 65 73 20 61 73 20 61 | 6e 20 61 62 73 74 72 61 |ves as a|n abstra|
|00003f70| 63 74 20 62 61 73 65 20 | 63 6c 61 73 73 20 66 6f |ct base |class fo|
|00003f80| 72 20 74 68 65 20 74 77 | 6f 20 6b 69 6e 64 73 20 |r the tw|o kinds |
|00003f90| 6f 66 20 63 61 6c 6c 62 | 61 63 6b 73 2e 0a 58 0a |of callb|acks..X.|
|00003fa0| 54 68 65 20 66 6f 6c 6c | 6f 77 69 6e 67 20 73 65 |The foll|owing se|
|00003fb0| 63 74 69 6f 6e 73 20 64 | 65 73 63 72 69 62 65 20 |ctions d|escribe |
|00003fc0| 74 68 65 20 63 6f 6e 73 | 74 72 75 63 74 6f 72 73 |the cons|tructors|
|00003fd0| 20 66 6f 72 20 40 63 6f | 64 65 7b 52 70 63 43 61 | for @co|de{RpcCa|
|00003fe0| 6c 6c 62 61 63 6b 7d 0a | 61 6e 64 20 40 63 6f 64 |llback}.|and @cod|
|00003ff0| 65 7b 52 70 63 4d 65 74 | 68 6f 64 43 61 6c 6c 7d |e{RpcMet|hodCall}|
|00004000| 20 61 6e 64 20 74 68 65 | 20 63 61 6c 6c 69 6e 67 | and the| calling|
|00004010| 20 63 6f 6e 76 65 6e 74 | 69 6f 6e 73 20 66 6f 72 | convent|ions for|
|00004020| 20 74 68 65 20 66 75 6e | 63 74 69 6f 6e 73 0a 6f | the fun|ctions.o|
|00004030| 72 20 6d 65 74 68 6f 64 | 73 20 63 61 6c 6c 65 64 |r method|s called|
|00004040| 20 62 61 63 6b 2e 0a 58 | 0a 58 40 6d 65 6e 75 0a | back..X|.X@menu.|
|00004050| 58 2a 20 52 70 63 43 61 | 6c 6c 62 61 63 6b 3a 3a |X* RpcCa|llback::|
|00004060| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00004070| 20 40 63 6f 64 65 7b 52 | 70 63 43 61 6c 6c 62 61 | @code{R|pcCallba|
|00004080| 63 6b 7d 0a 58 2a 20 52 | 70 63 4d 65 74 68 6f 64 |ck}.X* R|pcMethod|
|00004090| 43 61 6c 6c 3a 3a 20 20 | 20 20 20 20 20 20 20 20 |Call:: | |
|000040a0| 20 20 20 20 20 40 63 6f | 64 65 7b 52 70 63 4d 65 | @co|de{RpcMe|
|000040b0| 74 68 6f 64 43 61 6c 6c | 7d 0a 58 2a 20 43 61 6c |thodCall|}.X* Cal|
|000040c0| 6c 69 6e 67 20 43 6f 6e | 76 65 6e 74 69 6f 6e 73 |ling Con|ventions|
|000040d0| 3a 3a 20 20 20 20 20 20 | 20 20 20 40 63 6f 64 65 |:: | @code|
|000040e0| 7b 43 61 6c 6c 69 6e 67 | 20 43 6f 6e 76 65 6e 74 |{Calling| Convent|
|000040f0| 69 6f 6e 73 7d 0a 58 40 | 65 6e 64 20 6d 65 6e 75 |ions}.X@|end menu|
|00004100| 0a 58 0a 58 40 6e 6f 64 | 65 20 20 20 20 52 70 63 |.X.X@nod|e Rpc|
|00004110| 43 61 6c 6c 62 61 63 6b | 2c 20 52 70 63 4d 65 74 |Callback|, RpcMet|
|00004120| 68 6f 64 43 61 6c 6c 2c | 20 20 2c 20 43 61 6c 6c |hodCall,| , Call|
|00004130| 62 61 63 6b 73 0a 58 40 | 63 6f 6d 6d 65 6e 74 20 |backs.X@|comment |
|00004140| 6e 6f 64 65 2d 6e 61 6d | 65 2c 20 20 20 20 20 6e |node-nam|e, n|
|00004150| 65 78 74 2c 20 20 20 20 | 20 20 20 20 20 20 20 70 |ext, | p|
|00004160| 72 65 76 69 6f 75 73 2c | 20 75 70 0a 58 40 73 75 |revious,| up.X@su|
|00004170| 62 73 65 63 74 69 6f 6e | 20 40 63 6f 64 65 7b 52 |bsection| @code{R|
|00004180| 70 63 43 61 6c 6c 62 61 | 63 6b 7d 0a 58 40 63 69 |pcCallba|ck}.X@ci|
|00004190| 6e 64 65 78 20 40 63 6f | 64 65 7b 52 70 63 43 61 |ndex @co|de{RpcCa|
|000041a0| 6c 6c 62 61 63 6b 7d 0a | 58 0a 44 65 63 6c 61 72 |llback}.|X.Declar|
|000041b0| 65 64 20 69 6e 3a 20 40 | 63 6f 64 65 7b 22 72 70 |ed in: @|code{"rp|
|000041c0| 63 2b 2b 2f 63 61 6c 6c | 62 61 63 6b 2e 68 22 7d |c++/call|back.h"}|
|000041d0| 0a 58 0a 58 40 64 65 66 | 74 70 20 43 6c 61 73 73 |.X.X@def|tp Class|
|000041e0| 20 52 70 63 43 61 6c 6c | 62 61 63 6b 0a 41 6e 20 | RpcCall|back.An |
|000041f0| 40 63 6f 64 65 7b 52 70 | 63 43 61 6c 6c 62 61 63 |@code{Rp|cCallbac|
|00004200| 6b 7d 20 64 65 73 63 72 | 69 62 65 73 20 61 20 66 |k} descr|ibes a f|
|00004210| 75 6e 63 74 69 6f 6e 20 | 74 68 61 74 20 69 73 20 |unction |that is |
|00004220| 74 6f 20 62 65 20 63 61 | 6c 6c 65 64 20 62 79 20 |to be ca|lled by |
|00004230| 74 68 65 0a 73 65 72 76 | 65 72 20 6f 6e 20 72 65 |the.serv|er on re|
|00004240| 71 75 65 73 74 20 66 72 | 6f 6d 20 74 68 65 20 63 |quest fr|om the c|
|00004250| 6c 69 65 6e 74 2e 0a 58 | 40 65 6e 64 20 64 65 66 |lient..X|@end def|
|00004260| 74 70 0a 58 0a 58 40 64 | 65 66 74 79 70 65 66 6e |tp.X.X@d|eftypefn|
|00004270| 20 43 6f 6e 73 74 72 75 | 63 74 6f 72 20 7b 7d 20 | Constru|ctor {} |
|00004280| 52 70 63 43 61 6c 6c 62 | 61 63 6b 20 28 76 6f 69 |RpcCallb|ack (voi|
|00004290| 64 2a 20 28 2a 29 28 29 | 20 40 76 61 72 7b 70 72 |d* (*)()| @var{pr|
|000042a0| 6f 63 7d 29 0a 58 40 65 | 6e 64 20 64 65 66 74 79 |oc}).X@e|nd defty|
|000042b0| 70 65 66 6e 0a 58 40 64 | 65 66 74 79 70 65 66 6e |pefn.X@d|eftypefn|
|000042c0| 20 43 6f 6e 73 74 72 75 | 63 74 6f 72 20 7b 7d 20 | Constru|ctor {} |
|000042d0| 52 70 63 43 61 6c 6c 62 | 61 63 6b 20 28 76 6f 69 |RpcCallb|ack (voi|
|000042e0| 64 2a 20 28 2a 29 28 76 | 6f 69 64 2a 29 20 40 76 |d* (*)(v|oid*) @v|
|000042f0| 61 72 7b 70 72 6f 63 7d | 29 0a 58 40 65 6e 64 20 |ar{proc}|).X@end |
|00004300| 64 65 66 74 79 70 65 66 | 6e 0a 58 40 64 65 66 74 |deftypef|n.X@deft|
|00004310| 79 70 65 66 6e 20 43 6f | 6e 73 74 72 75 63 74 6f |ypefn Co|nstructo|
|00004320| 72 20 7b 7d 20 52 70 63 | 43 61 6c 6c 62 61 63 6b |r {} Rpc|Callback|
|00004330| 20 28 76 6f 69 64 2a 20 | 28 2a 29 28 76 6f 69 64 | (void* |(*)(void|
|00004340| 2a 2c 20 76 6f 69 64 2a | 29 20 40 76 61 72 7b 70 |*, void*|) @var{p|
|00004350| 72 6f 63 7d 29 0a 43 6f | 6e 73 74 72 75 63 74 20 |roc}).Co|nstruct |
|00004360| 61 6e 20 40 63 6f 64 65 | 7b 52 70 63 43 61 6c 6c |an @code|{RpcCall|
|00004370| 62 61 63 6b 7d 20 66 6f | 72 20 61 20 66 75 6e 63 |back} fo|r a func|
|00004380| 74 69 6f 6e 20 74 68 61 | 74 20 74 61 6b 65 73 20 |tion tha|t takes |
|00004390| 7a 65 72 6f 2c 20 6f 6e | 65 20 6f 72 0a 74 77 6f |zero, on|e or.two|
|000043a0| 20 61 72 67 75 6d 65 6e | 74 73 20 61 6e 64 20 72 | argumen|ts and r|
|000043b0| 65 74 75 72 6e 73 20 61 | 20 72 65 73 75 6c 74 2e |eturns a| result.|
|000043c0| 20 43 6f 6e 73 74 72 75 | 63 74 6f 72 73 20 66 6f | Constru|ctors fo|
|000043d0| 72 20 66 75 6e 63 74 69 | 6f 6e 73 20 77 69 74 68 |r functi|ons with|
|000043e0| 0a 75 70 20 74 6f 20 73 | 65 76 65 6e 20 61 72 67 |.up to s|even arg|
|000043f0| 75 6d 65 6e 74 73 20 61 | 72 65 20 64 65 66 69 6e |uments a|re defin|
|00004400| 65 64 2e 0a 58 40 65 6e | 64 20 64 65 66 74 79 70 |ed..X@en|d deftyp|
|00004410| 65 66 6e 0a 58 40 64 65 | 66 74 79 70 65 66 6e 20 |efn.X@de|ftypefn |
|00004420| 43 6f 6e 73 74 72 75 63 | 74 6f 72 20 7b 7d 20 52 |Construc|tor {} R|
|00004430| 70 63 43 61 6c 6c 62 61 | 63 6b 20 28 76 6f 69 64 |pcCallba|ck (void|
|00004440| 2a 20 28 2a 29 28 76 6f | 69 64 2a 2a 29 20 40 76 |* (*)(vo|id**) @v|
|00004450| 61 72 7b 70 72 6f 63 7d | 29 0a 43 6f 6e 73 74 72 |ar{proc}|).Constr|
|00004460| 75 63 74 20 61 6e 20 40 | 63 6f 64 65 7b 52 70 63 |uct an @|code{Rpc|
|00004470| 43 61 6c 6c 62 61 63 6b | 7d 20 66 6f 72 20 61 20 |Callback|} for a |
|00004480| 66 75 6e 63 74 69 6f 6e | 20 74 68 61 74 20 74 61 |function| that ta|
|00004490| 6b 65 73 20 61 6e 20 61 | 72 62 69 74 72 61 72 79 |kes an a|rbitrary|
|000044a0| 0a 6e 75 6d 62 65 72 20 | 6f 66 20 61 72 67 75 6d |.number |of argum|
|000044b0| 65 6e 74 73 20 61 6e 64 | 20 72 65 74 75 72 6e 73 |ents and| returns|
|000044c0| 20 61 20 72 65 73 75 6c | 74 2e 0a 58 40 65 6e 64 | a resul|t..X@end|
|000044d0| 20 64 65 66 74 79 70 65 | 66 6e 0a 58 0a 58 40 64 | deftype|fn.X.X@d|
|000044e0| 65 66 74 79 70 65 66 6e | 20 43 6f 6e 73 74 72 75 |eftypefn| Constru|
|000044f0| 63 74 6f 72 20 7b 7d 20 | 52 70 63 43 61 6c 6c 62 |ctor {} |RpcCallb|
|00004500| 61 63 6b 20 28 76 6f 69 | 64 20 28 2a 29 28 29 20 |ack (voi|d (*)() |
|00004510| 40 76 61 72 7b 70 72 6f | 63 7d 29 0a 58 40 65 6e |@var{pro|c}).X@en|
|00004520| 64 20 64 65 66 74 79 70 | 65 66 6e 0a 58 40 64 65 |d deftyp|efn.X@de|
|00004530| 66 74 79 70 65 66 6e 20 | 43 6f 6e 73 74 72 75 63 |ftypefn |Construc|
|00004540| 74 6f 72 20 7b 7d 20 52 | 70 63 43 61 6c 6c 62 61 |tor {} R|pcCallba|
|00004550| 63 6b 20 28 76 6f 69 64 | 20 28 2a 29 28 76 6f 69 |ck (void| (*)(voi|
|00004560| 64 2a 29 20 40 76 61 72 | 7b 70 72 6f 63 7d 29 0a |d*) @var|{proc}).|
|00004570| 58 40 65 6e 64 20 64 65 | 66 74 79 70 65 66 6e 0a |X@end de|ftypefn.|
|00004580| 58 40 64 65 66 74 79 70 | 65 66 6e 20 43 6f 6e 73 |X@deftyp|efn Cons|
|00004590| 74 72 75 63 74 6f 72 20 | 7b 7d 20 52 70 63 43 61 |tructor |{} RpcCa|
|000045a0| 6c 6c 62 61 63 6b 20 28 | 76 6f 69 64 20 28 2a 29 |llback (|void (*)|
|000045b0| 28 76 6f 69 64 2a 2c 20 | 76 6f 69 64 2a 29 20 40 |(void*, |void*) @|
|000045c0| 76 61 72 7b 70 72 6f 63 | 7d 29 0a 43 6f 6e 73 74 |var{proc|}).Const|
|000045d0| 72 75 63 74 20 61 6e 20 | 40 63 6f 64 65 7b 52 70 |ruct an |@code{Rp|
|000045e0| 63 43 61 6c 6c 62 61 63 | 6b 7d 20 66 6f 72 20 61 |cCallbac|k} for a|
|000045f0| 20 66 75 6e 63 74 69 6f | 6e 20 74 68 61 74 20 74 | functio|n that t|
|00004600| 61 6b 65 73 20 7a 65 72 | 6f 2c 20 6f 6e 65 20 6f |akes zer|o, one o|
|00004610| 72 0a 74 77 6f 20 61 72 | 67 75 6d 65 6e 74 73 20 |r.two ar|guments |
|00004620| 61 6e 64 20 72 65 74 75 | 72 6e 73 20 6e 6f 20 72 |and retu|rns no r|
|00004630| 65 73 75 6c 74 2e 20 43 | 6f 6e 73 74 72 75 63 74 |esult. C|onstruct|
|00004640| 6f 72 73 20 66 6f 72 20 | 66 75 6e 63 74 69 6f 6e |ors for |function|
|00004650| 73 20 77 69 74 68 0a 75 | 70 20 74 6f 20 73 65 76 |s with.u|p to sev|
|00004660| 65 6e 20 61 72 67 75 6d | 65 6e 74 73 20 61 72 65 |en argum|ents are|
|00004670| 20 64 65 66 69 6e 65 64 | 2e 0a 58 40 65 6e 64 20 | defined|..X@end |
|00004680| 64 65 66 74 79 70 65 66 | 6e 0a 58 40 64 65 66 74 |deftypef|n.X@deft|
|00004690| 79 70 65 66 6e 20 43 6f | 6e 73 74 72 75 63 74 6f |ypefn Co|nstructo|
|000046a0| 72 20 7b 7d 20 52 70 63 | 43 61 6c 6c 62 61 63 6b |r {} Rpc|Callback|
|000046b0| 20 28 76 6f 69 64 20 28 | 2a 29 28 76 6f 69 64 2a | (void (|*)(void*|
|000046c0| 2a 29 20 40 76 61 72 7b | 70 72 6f 63 7d 29 0a 43 |*) @var{|proc}).C|
|000046d0| 6f 6e 73 74 72 75 63 74 | 20 61 6e 20 40 63 6f 64 |onstruct| an @cod|
|000046e0| 65 7b 52 70 63 43 61 6c | 6c 62 61 63 6b 7d 20 66 |e{RpcCal|lback} f|
|000046f0| 6f 72 20 61 20 66 75 6e | 63 74 69 6f 6e 20 74 68 |or a fun|ction th|
|00004700| 61 74 20 74 61 6b 65 73 | 20 61 6e 20 61 72 62 69 |at takes| an arbi|
|00004710| 74 72 61 72 79 0a 6e 75 | 6d 62 65 72 20 6f 66 20 |trary.nu|mber of |
|00004720| 61 72 67 75 6d 65 6e 74 | 73 20 61 6e 64 20 72 65 |argument|s and re|
|00004730| 74 75 72 6e 20 6e 6f 20 | 72 65 73 75 6c 74 2e 0a |turn no |result..|
|00004740| 58 40 65 6e 64 20 64 65 | 66 74 79 70 65 66 6e 0a |X@end de|ftypefn.|
|00004750| 58 0a 58 40 64 65 66 74 | 79 70 65 66 6e 20 43 6f |X.X@deft|ypefn Co|
|00004760| 6e 73 74 72 75 63 74 6f | 72 20 7b 7d 20 52 70 63 |nstructo|r {} Rpc|
|00004770| 43 61 6c 6c 62 61 63 6b | 20 28 76 6f 69 64 2a 20 |Callback| (void* |
|00004780| 28 2a 29 28 52 70 63 53 | 65 72 76 69 63 65 2a 29 |(*)(RpcS|ervice*)|
|00004790| 20 40 76 61 72 7b 70 72 | 6f 63 7d 29 0a 58 40 65 | @var{pr|oc}).X@e|
|000047a0| 6e 64 20 64 65 66 74 79 | 70 65 66 6e 0a 58 40 64 |nd defty|pefn.X@d|
|000047b0| 65 66 74 79 70 65 66 6e | 20 43 6f 6e 73 74 72 75 |eftypefn| Constru|
|000047c0| 63 74 6f 72 20 7b 7d 20 | 52 70 63 43 61 6c 6c 62 |ctor {} |RpcCallb|
|000047d0| 61 63 6b 20 28 76 6f 69 | 64 2a 20 28 2a 29 28 76 |ack (voi|d* (*)(v|
|000047e0| 6f 69 64 2a 2c 20 52 70 | 63 53 65 72 76 69 63 65 |oid*, Rp|cService|
|000047f0| 2a 29 20 40 76 61 72 7b | 70 72 6f 63 7d 29 0a 58 |*) @var{|proc}).X|
|00004800| 40 65 6e 64 20 64 65 66 | 74 79 70 65 66 6e 0a 58 |@end def|typefn.X|
|00004810| 40 64 65 66 74 79 70 65 | 66 6e 20 43 6f 6e 73 74 |@deftype|fn Const|
|00004820| 72 75 63 74 6f 72 20 7b | 7d 20 52 70 63 43 61 6c |ructor {|} RpcCal|
|00004830| 6c 62 61 63 6b 20 28 76 | 6f 69 64 2a 20 28 2a 29 |lback (v|oid* (*)|
|00004840| 28 76 6f 69 64 2a 2c 20 | 76 6f 69 64 2a 2c 20 52 |(void*, |void*, R|
|00004850| 70 63 53 65 72 76 69 63 | 65 2a 29 20 40 76 61 72 |pcServic|e*) @var|
|00004860| 7b 70 72 6f 63 7d 29 0a | 43 6f 6e 73 74 72 75 63 |{proc}).|Construc|
|00004870| 74 20 61 6e 20 40 63 6f | 64 65 7b 52 70 63 43 61 |t an @co|de{RpcCa|
|00004880| 6c 6c 62 61 63 6b 7d 20 | 66 6f 72 20 61 20 66 75 |llback} |for a fu|
|00004890| 6e 63 74 69 6f 6e 20 74 | 68 61 74 20 74 61 6b 65 |nction t|hat take|
|000048a0| 73 20 7a 65 72 6f 2c 20 | 6f 6e 65 20 6f 72 0a 74 |s zero, |one or.t|
|000048b0| 77 6f 20 61 72 67 75 6d | 65 6e 74 73 20 61 6e 64 |wo argum|ents and|
|000048c0| 20 72 65 74 75 72 6e 73 | 20 61 20 72 65 73 75 6c | returns| a resul|
|000048d0| 74 2e 20 43 6f 6e 73 74 | 72 75 63 74 6f 72 73 20 |t. Const|ructors |
|000048e0| 66 6f 72 20 66 75 6e 63 | 74 69 6f 6e 73 20 77 69 |for func|tions wi|
|000048f0| 74 68 0a 75 70 20 74 6f | 20 73 65 76 65 6e 20 61 |th.up to| seven a|
|00004900| 72 67 75 6d 65 6e 74 73 | 20 61 72 65 20 64 65 66 |rguments| are def|
|00004910| 69 6e 65 64 2e 20 55 70 | 6f 6e 20 69 6e 76 6f 63 |ined. Up|on invoc|
|00004920| 61 74 69 6f 6e 2c 20 61 | 20 70 6f 69 6e 74 65 72 |ation, a| pointer|
|00004930| 20 74 6f 20 74 68 65 0a | 6f 62 6a 65 63 74 20 6f | to the.|object o|
|00004940| 66 20 74 79 70 65 20 40 | 63 6f 64 65 7b 52 70 63 |f type @|code{Rpc|
|00004950| 53 65 72 76 69 63 65 7d | 20 74 68 61 74 20 72 65 |Service}| that re|
|00004960| 63 65 69 76 65 64 20 74 | 68 65 20 72 65 71 75 65 |ceived t|he reque|
|00004970| 73 74 20 61 6e 64 20 63 | 61 6c 6c 65 64 0a 74 68 |st and c|alled.th|
|00004980| 65 20 66 75 6e 63 74 69 | 6f 6e 20 69 73 20 70 61 |e functi|on is pa|
|00004990| 73 73 65 64 20 61 73 20 | 61 6e 20 61 64 64 69 74 |ssed as |an addit|
|000049a0| 69 6f 6e 61 6c 20 61 72 | 67 75 6d 65 6e 74 2e 0a |ional ar|gument..|
|000049b0| 58 40 65 6e 64 20 64 65 | 66 74 79 70 65 66 6e 0a |X@end de|ftypefn.|
|000049c0| 58 40 64 65 66 74 79 70 | 65 66 6e 20 43 6f 6e 73 |X@deftyp|efn Cons|
|000049d0| 74 72 75 63 74 6f 72 20 | 7b 7d 20 52 70 63 43 61 |tructor |{} RpcCa|
|000049e0| 6c 6c 62 61 63 6b 20 28 | 76 6f 69 64 2a 20 28 2a |llback (|void* (*|
|000049f0| 29 28 76 6f 69 64 2a 2a | 29 20 40 76 61 72 7b 70 |)(void**|) @var{p|
|00004a00| 72 6f 63 7d 29 0a 43 6f | 6e 73 74 72 75 63 74 20 |roc}).Co|nstruct |
|00004a10| 61 6e 20 40 63 6f 64 65 | 7b 52 70 63 43 61 6c 6c |an @code|{RpcCall|
|00004a20| 62 61 63 6b 7d 20 66 6f | 72 20 61 20 66 75 6e 63 |back} fo|r a func|
|00004a30| 74 69 6f 6e 20 74 68 61 | 74 20 74 61 6b 65 73 20 |tion tha|t takes |
|00004a40| 61 6e 20 61 72 62 69 74 | 72 61 72 79 0a 6e 75 6d |an arbit|rary.num|
|00004a50| 62 65 72 20 6f 66 20 61 | 72 67 75 6d 65 6e 74 73 |ber of a|rguments|
|00004a60| 20 61 6e 64 20 72 65 74 | 75 72 6e 73 20 61 20 72 | and ret|urns a r|
|00004a70| 65 73 75 6c 74 2e 20 55 | 70 6f 6e 20 69 6e 76 6f |esult. U|pon invo|
|00004a80| 63 61 74 69 6f 6e 2c 20 | 61 20 70 6f 69 6e 74 65 |cation, |a pointe|
|00004a90| 72 20 74 6f 20 74 68 65 | 0a 6f 62 6a 65 63 74 20 |r to the|.object |
|00004aa0| 6f 66 20 74 79 70 65 20 | 40 63 6f 64 65 7b 52 70 |of type |@code{Rp|
|00004ab0| 63 53 65 72 76 69 63 65 | 7d 20 74 68 61 74 20 72 |cService|} that r|
|00004ac0| 65 63 65 69 76 65 64 20 | 74 68 65 20 72 65 71 75 |eceived |the requ|
|00004ad0| 65 73 74 20 61 6e 64 20 | 63 61 6c 6c 65 64 0a 74 |est and |called.t|
|00004ae0| 68 65 20 66 75 6e 63 74 | 69 6f 6e 20 69 73 20 70 |he funct|ion is p|
|00004af0| 61 73 73 65 64 20 61 73 | 20 61 6e 20 61 64 64 69 |assed as| an addi|
|00004b00| 74 69 6f 6e 61 6c 20 61 | 72 67 75 6d 65 6e 74 2e |tional a|rgument.|
|00004b10| 0a 58 40 65 6e 64 20 64 | 65 66 74 79 70 65 66 6e |.X@end d|eftypefn|
|00004b20| 0a 58 0a 58 40 64 65 66 | 74 79 70 65 66 6e 20 43 |.X.X@def|typefn C|
|00004b30| 6f 6e 73 74 72 75 63 74 | 6f 72 20 7b 7d 20 52 70 |onstruct|or {} Rp|
|00004b40| 63 43 61 6c 6c 62 61 63 | 6b 20 28 76 6f 69 64 20 |cCallbac|k (void |
|00004b50| 28 2a 29 28 52 70 63 53 | 65 72 76 69 63 65 2a 29 |(*)(RpcS|ervice*)|
|00004b60| 20 40 76 61 72 7b 70 72 | 6f 63 7d 29 0a 58 40 65 | @var{pr|oc}).X@e|
|00004b70| 6e 64 20 64 65 66 74 79 | 70 65 66 6e 0a 58 40 64 |nd defty|pefn.X@d|
|00004b80| 65 66 74 79 70 65 66 6e | 20 43 6f 6e 73 74 72 75 |eftypefn| Constru|
|00004b90| 63 74 6f 72 20 7b 7d 20 | 52 70 63 43 61 6c 6c 62 |ctor {} |RpcCallb|
|00004ba0| 61 63 6b 20 28 76 6f 69 | 64 20 28 2a 29 28 76 6f |ack (voi|d (*)(vo|
|00004bb0| 69 64 2a 2c 20 52 70 63 | 53 65 72 76 69 63 65 2a |id*, Rpc|Service*|
|00004bc0| 29 20 40 76 61 72 7b 70 | 72 6f 63 7d 29 0a 58 40 |) @var{p|roc}).X@|
|00004bd0| 65 6e 64 20 64 65 66 74 | 79 70 65 66 6e 0a 58 40 |end deft|ypefn.X@|
|00004be0| 64 65 66 74 79 70 65 66 | 6e 20 43 6f 6e 73 74 72 |deftypef|n Constr|
|00004bf0| 75 63 74 6f 72 20 7b 7d | 20 52 70 63 43 61 6c 6c |uctor {}| RpcCall|
|00004c00| 62 61 63 6b 20 28 76 6f | 69 64 20 28 2a 29 28 76 |back (vo|id (*)(v|
|00004c10| 6f 69 64 2a 2c 20 76 6f | 69 64 2a 2c 20 52 70 63 |oid*, vo|id*, Rpc|
|00004c20| 53 65 72 76 69 63 65 2a | 29 20 40 76 61 72 7b 70 |Service*|) @var{p|
|00004c30| 72 6f 63 7d 29 0a 43 6f | 6e 73 74 72 75 63 74 20 |roc}).Co|nstruct |
|00004c40| 61 6e 20 40 63 6f 64 65 | 7b 52 70 63 43 61 6c 6c |an @code|{RpcCall|
|00004c50| 62 61 63 6b 7d 20 66 6f | 72 20 61 20 66 75 6e 63 |back} fo|r a func|
|00004c60| 74 69 6f 6e 20 74 68 61 | 74 20 74 61 6b 65 73 20 |tion tha|t takes |
|00004c70| 7a 65 72 6f 2c 20 6f 6e | 65 20 6f 72 0a 74 77 6f |zero, on|e or.two|
|00004c80| 20 61 72 67 75 6d 65 6e | 74 73 20 61 6e 64 20 72 | argumen|ts and r|
|00004c90| 65 74 75 72 6e 73 20 61 | 20 72 65 73 75 6c 74 2e |eturns a| result.|
|00004ca0| 20 43 6f 6e 73 74 72 75 | 63 74 6f 72 73 20 66 6f | Constru|ctors fo|
|00004cb0| 72 20 66 75 6e 63 74 69 | 6f 6e 73 20 77 69 74 68 |r functi|ons with|
|00004cc0| 0a 75 70 20 74 6f 20 73 | 65 76 65 6e 20 61 72 67 |.up to s|even arg|
|00004cd0| 75 6d 65 6e 74 73 20 61 | 72 65 20 64 65 66 69 6e |uments a|re defin|
|00004ce0| 65 64 2e 20 55 70 6f 6e | 20 69 6e 76 6f 63 61 74 |ed. Upon| invocat|
|00004cf0| 69 6f 6e 2c 20 61 20 70 | 6f 69 6e 74 65 72 20 74 |ion, a p|ointer t|
|00004d00| 6f 20 74 68 65 0a 6f 62 | 6a 65 63 74 20 6f 66 20 |o the.ob|ject of |
|00004d10| 74 79 70 65 20 40 63 6f | 64 65 7b 52 70 63 53 65 |type @co|de{RpcSe|
|00004d20| 72 76 69 63 65 7d 20 74 | 68 61 74 20 72 65 63 65 |rvice} t|hat rece|
|00004d30| 69 76 65 64 20 74 68 65 | 20 72 65 71 75 65 73 74 |ived the| request|
|00004d40| 20 61 6e 64 20 63 61 6c | 6c 65 64 0a 74 68 65 20 | and cal|led.the |
|00004d50| 66 75 6e 63 74 69 6f 6e | 20 69 73 20 70 61 73 73 |function| is pass|
|00004d60| 65 64 20 61 73 20 61 6e | 20 61 64 64 69 74 69 6f |ed as an| additio|
|00004d70| 6e 61 6c 20 61 72 67 75 | 6d 65 6e 74 2e 0a 58 40 |nal argu|ment..X@|
|00004d80| 65 6e 64 20 64 65 66 74 | 79 70 65 66 6e 0a 58 40 |end deft|ypefn.X@|
|00004d90| 64 65 66 74 79 70 65 66 | 6e 20 43 6f 6e 73 74 72 |deftypef|n Constr|
|00004da0| 75 63 74 6f 72 20 7b 7d | 20 52 70 63 43 61 6c 6c |uctor {}| RpcCall|
|00004db0| 62 61 63 6b 20 28 76 6f | 69 64 20 28 2a 29 28 76 |back (vo|id (*)(v|
|00004dc0| 6f 69 64 2a 2a 29 20 40 | 76 61 72 7b 70 72 6f 63 |oid**) @|var{proc|
|00004dd0| 7d 29 0a 43 6f 6e 73 74 | 72 75 63 74 20 61 6e 20 |}).Const|ruct an |
|00004de0| 40 63 6f 64 65 7b 52 70 | 63 43 61 6c 6c 62 61 63 |@code{Rp|cCallbac|
|00004df0| 6b 7d 20 66 6f 72 20 61 | 20 66 75 6e 63 74 69 6f |k} for a| functio|
|00004e00| 6e 20 74 68 61 74 20 74 | 61 6b 65 73 20 61 6e 20 |n that t|akes an |
|00004e10| 61 72 62 69 74 72 61 72 | 79 0a 6e 75 6d 62 65 72 |arbitrar|y.number|
|00004e20| 20 6f 66 20 61 72 67 75 | 6d 65 6e 74 73 20 61 6e | of argu|ments an|
|00004e30| 64 20 72 65 74 75 72 6e | 73 20 61 20 72 65 73 75 |d return|s a resu|
|00004e40| 6c 74 2e 20 55 70 6f 6e | 20 69 6e 76 6f 63 61 74 |lt. Upon| invocat|
|00004e50| 69 6f 6e 2c 20 61 20 70 | 6f 69 6e 74 65 72 20 74 |ion, a p|ointer t|
|00004e60| 6f 20 74 68 65 0a 6f 62 | 6a 65 63 74 20 6f 66 20 |o the.ob|ject of |
|00004e70| 74 79 70 65 20 40 63 6f | 64 65 7b 52 70 63 53 65 |type @co|de{RpcSe|
|00004e80| 72 76 69 63 65 7d 20 74 | 68 61 74 20 72 65 63 65 |rvice} t|hat rece|
|00004e90| 69 76 65 64 20 74 68 65 | 20 72 65 71 75 65 73 74 |ived the| request|
|00004ea0| 20 61 6e 64 20 63 61 6c | 6c 65 64 0a 74 68 65 20 | and cal|led.the |
|00004eb0| 66 75 6e 63 74 69 6f 6e | 20 69 73 20 70 61 73 73 |function| is pass|
|00004ec0| 65 64 20 61 73 20 61 6e | 20 61 64 64 69 74 69 6f |ed as an| additio|
|00004ed0| 6e 61 6c 20 61 72 67 75 | 6d 65 6e 74 2e 0a 58 40 |nal argu|ment..X@|
|00004ee0| 65 6e 64 20 64 65 66 74 | 79 70 65 66 6e 0a 58 0a |end deft|ypefn.X.|
|00004ef0| 58 40 6e 6f 64 65 20 20 | 20 20 52 70 63 4d 65 74 |X@node | RpcMet|
|00004f00| 68 6f 64 43 61 6c 6c 2c | 20 43 61 6c 6c 69 6e 67 |hodCall,| Calling|
|00004f10| 20 43 6f 6e 76 65 6e 74 | 69 6f 6e 73 2c 20 52 70 | Convent|ions, Rp|
|00004f20| 63 43 61 6c 6c 62 61 63 | 6b 2c 20 43 61 6c 6c 62 |cCallbac|k, Callb|
|00004f30| 61 63 6b 73 0a 58 40 63 | 6f 6d 6d 65 6e 74 20 6e |acks.X@c|omment n|
|00004f40| 6f 64 65 2d 6e 61 6d 65 | 2c 20 20 20 20 20 6e 65 |ode-name|, ne|
|00004f50| 78 74 2c 20 20 20 20 20 | 20 20 20 20 20 20 70 72 |xt, | pr|
|00004f60| 65 76 69 6f 75 73 2c 20 | 75 70 0a 58 40 73 75 62 |evious, |up.X@sub|
|00004f70| 73 65 63 74 69 6f 6e 20 | 40 63 6f 64 65 7b 52 70 |section |@code{Rp|
|00004f80| 63 4d 65 74 68 6f 64 43 | 61 6c 6c 7d 0a 58 40 63 |cMethodC|all}.X@c|
|00004f90| 69 6e 64 65 78 20 40 63 | 6f 64 65 7b 52 70 63 4d |index @c|ode{RpcM|
|00004fa0| 65 74 68 6f 64 43 61 6c | 6c 7d 0a 58 0a 44 65 63 |ethodCal|l}.X.Dec|
|00004fb0| 6c 61 72 65 64 20 69 6e | 3a 20 40 63 6f 64 65 7b |lared in|: @code{|
|00004fc0| 22 72 70 63 2b 2b 2f 63 | 61 6c 6c 62 61 63 6b 2e |"rpc++/c|allback.|
|00004fd0| 68 22 7d 0a 58 0a 58 40 | 64 65 66 74 70 20 43 6c |h"}.X.X@|deftp Cl|
|00004fe0| 61 73 73 20 52 70 63 4d | 65 74 68 6f 64 43 61 6c |ass RpcM|ethodCal|
|00004ff0| 6c 0a 41 6e 20 40 63 6f | 64 65 7b 52 70 63 4d 65 |l.An @co|de{RpcMe|
|00005000| 74 68 6f 64 43 61 6c 6c | 7d 20 64 65 73 63 72 69 |thodCall|} descri|
|00005010| 62 65 73 20 61 20 6d 65 | 74 68 6f 64 20 6f 66 20 |bes a me|thod of |
|00005020| 61 6e 20 6f 62 6a 65 63 | 74 20 74 68 61 74 20 69 |an objec|t that i|
|00005030| 73 20 74 6f 20 62 65 0a | 63 61 6c 6c 65 64 20 62 |s to be.|called b|
|00005040| 79 20 74 68 65 20 73 65 | 72 76 65 72 20 6f 6e 20 |y the se|rver on |
|00005050| 72 65 71 75 65 73 74 20 | 66 72 6f 6d 20 74 68 65 |request |from the|
|00005060| 20 63 6c 69 65 6e 74 2e | 0a 58 40 65 6e 64 20 64 | client.|.X@end d|
|00005070| 65 66 74 70 0a 58 0a 58 | 40 64 65 66 74 79 70 65 |eftp.X.X|@deftype|
|00005080| 66 6e 20 43 6f 6e 73 74 | 72 75 63 74 6f 72 20 7b |fn Const|ructor {|
|00005090| 7d 20 52 70 63 4d 65 74 | 68 6f 64 43 61 6c 6c 20 |} RpcMet|hodCall |
|000050a0| 3c 63 6c 61 73 73 20 54 | 3e 20 28 76 6f 69 64 2a |<class T|> (void*|
|000050b0| 20 28 54 3a 3a 2a 29 28 | 29 20 40 76 61 72 7b 70 | (T::*)(|) @var{p|
|000050c0| 72 6f 63 7d 29 0a 58 40 | 65 6e 64 20 64 65 66 74 |roc}).X@|end deft|
|000050d0| 79 70 65 66 6e 0a 58 40 | 64 65 66 74 79 70 65 66 |ypefn.X@|deftypef|
|000050e0| 6e 20 43 6f 6e 73 74 72 | 75 63 74 6f 72 20 7b 7d |n Constr|uctor {}|
|000050f0| 20 52 70 63 4d 65 74 68 | 6f 64 43 61 6c 6c 20 3c | RpcMeth|odCall <|
|00005100| 63 6c 61 73 73 20 54 3e | 20 28 76 6f 69 64 2a 20 |class T>| (void* |
|00005110| 28 54 3a 3a 2a 29 28 76 | 6f 69 64 2a 29 20 40 76 |(T::*)(v|oid*) @v|
|00005120| 61 72 7b 70 72 6f 63 7d | 29 0a 58 40 65 6e 64 20 |ar{proc}|).X@end |
|00005130| 64 65 66 74 79 70 65 66 | 6e 0a 58 40 64 65 66 74 |deftypef|n.X@deft|
|00005140| 79 70 65 66 6e 20 43 6f | 6e 73 74 72 75 63 74 6f |ypefn Co|nstructo|
|00005150| 72 20 7b 7d 20 52 70 63 | 4d 65 74 68 6f 64 43 61 |r {} Rpc|MethodCa|
|00005160| 6c 6c 20 3c 63 6c 61 73 | 73 20 54 3e 20 28 76 6f |ll <clas|s T> (vo|
|00005170| 69 64 2a 20 28 54 3a 3a | 2a 29 28 76 6f 69 64 2a |id* (T::|*)(void*|
|00005180| 2c 20 76 6f 69 64 2a 29 | 20 40 76 61 72 7b 70 72 |, void*)| @var{pr|
|00005190| 6f 63 7d 29 0a 43 6f 6e | 73 74 72 75 63 74 20 61 |oc}).Con|struct a|
|000051a0| 6e 20 40 63 6f 64 65 7b | 52 70 63 4d 65 74 68 6f |n @code{|RpcMetho|
|000051b0| 64 43 61 6c 6c 7d 20 66 | 6f 72 20 61 6e 20 6f 62 |dCall} f|or an ob|
|000051c0| 6a 65 63 74 20 61 6e 64 | 20 6f 6e 65 20 6f 66 20 |ject and| one of |
|000051d0| 69 74 73 20 6d 65 74 68 | 6f 64 73 20 74 68 61 74 |its meth|ods that|
|000051e0| 0a 74 61 6b 65 73 20 7a | 65 72 6f 2c 20 6f 6e 65 |.takes z|ero, one|
|000051f0| 20 6f 72 20 74 77 6f 20 | 61 72 67 75 6d 65 6e 74 | or two |argument|
|00005200| 73 20 61 6e 64 20 72 65 | 74 75 72 6e 73 20 61 20 |s and re|turns a |
|00005210| 72 65 73 75 6c 74 2e 20 | 43 6f 6e 73 74 72 75 63 |result. |Construc|
|00005220| 74 6f 72 73 20 66 6f 72 | 0a 6d 65 74 68 6f 64 73 |tors for|.methods|
|00005230| 20 77 69 74 68 20 75 70 | 20 74 6f 20 73 65 76 65 | with up| to seve|
|00005240| 6e 20 61 72 67 75 6d 65 | 6e 74 73 20 61 72 65 20 |n argume|nts are |
|00005250| 64 65 66 69 6e 65 64 2e | 0a 58 40 65 6e 64 20 64 |defined.|.X@end d|
|00005260| 65 66 74 79 70 65 66 6e | 0a 58 40 64 65 66 74 79 |eftypefn|.X@defty|
|00005270| 70 65 66 6e 20 43 6f 6e | 73 74 72 75 63 74 6f 72 |pefn Con|structor|
|00005280| 20 7b 7d 20 52 70 63 4d | 65 74 68 6f 64 43 61 6c | {} RpcM|ethodCal|
|00005290| 6c 20 3c 63 6c 61 73 73 | 20 54 3e 20 28 76 6f 69 |l <class| T> (voi|
|000052a0| 64 2a 20 28 54 3a 3a 2a | 29 28 76 6f 69 64 2a 2a |d* (T::*|)(void**|
|000052b0| 29 20 40 76 61 72 7b 70 | 72 6f 63 7d 29 0a 43 6f |) @var{p|roc}).Co|
|000052c0| 6e 73 74 72 75 63 74 20 | 61 6e 20 40 63 6f 64 65 |nstruct |an @code|
|000052d0| 7b 52 70 63 4d 65 74 68 | 6f 64 43 61 6c 6c 7d 20 |{RpcMeth|odCall} |
|000052e0| 66 6f 72 20 61 6e 20 6f | 62 6a 65 63 74 20 61 6e |for an o|bject an|
|000052f0| 64 20 6f 6e 65 20 6f 66 | 20 69 74 73 20 6d 65 74 |d one of| its met|
|00005300| 68 6f 64 73 0a 74 68 61 | 74 20 74 61 6b 65 73 20 |hods.tha|t takes |
|00005310| 61 6e 20 61 72 62 69 74 | 72 61 72 79 20 6e 75 6d |an arbit|rary num|
|00005320| 62 65 72 20 6f 66 20 61 | 72 67 75 6d 65 6e 74 73 |ber of a|rguments|
|00005330| 20 61 6e 64 20 72 65 74 | 75 72 6e 73 20 61 20 72 | and ret|urns a r|
|00005340| 65 73 75 6c 74 2e 0a 58 | 40 65 6e 64 20 64 65 66 |esult..X|@end def|
|00005350| 74 79 70 65 66 6e 0a 58 | 0a 58 40 64 65 66 74 79 |typefn.X|.X@defty|
|00005360| 70 65 66 6e 20 43 6f 6e | 73 74 72 75 63 74 6f 72 |pefn Con|structor|
|00005370| 20 7b 7d 20 52 70 63 4d | 65 74 68 6f 64 43 61 6c | {} RpcM|ethodCal|
|00005380| 6c 20 3c 63 6c 61 73 73 | 20 54 3e 20 28 76 6f 69 |l <class| T> (voi|
|00005390| 64 20 28 54 3a 3a 2a 29 | 28 29 20 40 76 61 72 7b |d (T::*)|() @var{|
|000053a0| 70 72 6f 63 7d 29 0a 58 | 40 65 6e 64 20 64 65 66 |proc}).X|@end def|
|000053b0| 74 79 70 65 66 6e 0a 58 | 40 64 65 66 74 79 70 65 |typefn.X|@deftype|
|000053c0| 66 6e 20 43 6f 6e 73 74 | 72 75 63 74 6f 72 20 7b |fn Const|ructor {|
|000053d0| 7d 20 52 70 63 4d 65 74 | 68 6f 64 43 61 6c 6c 20 |} RpcMet|hodCall |
|000053e0| 3c 63 6c 61 73 73 20 54 | 3e 20 28 76 6f 69 64 20 |<class T|> (void |
|000053f0| 28 54 3a 3a 2a 29 28 76 | 6f 69 64 2a 29 20 40 76 |(T::*)(v|oid*) @v|
|00005400| 61 72 7b 70 72 6f 63 7d | 29 0a 58 40 65 6e 64 20 |ar{proc}|).X@end |
|00005410| 64 65 66 74 79 70 65 66 | 6e 0a 58 40 64 65 66 74 |deftypef|n.X@deft|
|00005420| 79 70 65 66 6e 20 43 6f | 6e 73 74 72 75 63 74 6f |ypefn Co|nstructo|
|00005430| 72 20 7b 7d 20 52 70 63 | 4d 65 74 68 6f 64 43 61 |r {} Rpc|MethodCa|
|00005440| 6c 6c 20 3c 63 6c 61 73 | 73 20 54 3e 20 28 76 6f |ll <clas|s T> (vo|
|00005450| 69 64 20 28 54 3a 3a 2a | 29 28 76 6f 69 64 2a 2c |id (T::*|)(void*,|
|00005460| 20 76 6f 69 64 2a 29 20 | 40 76 61 72 7b 70 72 6f | void*) |@var{pro|
|00005470| 63 7d 29 0a 43 6f 6e 73 | 74 72 75 63 74 20 61 6e |c}).Cons|truct an|
|00005480| 20 40 63 6f 64 65 7b 52 | 70 63 4d 65 74 68 6f 64 | @code{R|pcMethod|
|00005490| 43 61 6c 6c 7d 20 66 6f | 72 20 61 6e 20 6f 62 6a |Call} fo|r an obj|
|000054a0| 65 63 74 20 61 6e 64 20 | 6f 6e 65 20 6f 66 20 69 |ect and |one of i|
|000054b0| 74 73 20 6d 65 74 68 6f | 64 73 0a 74 68 61 74 20 |ts metho|ds.that |
|000054c0| 74 61 6b 65 73 20 7a 65 | 72 6f 2c 20 6f 6e 65 20 |takes ze|ro, one |
|000054d0| 6f 72 20 74 77 6f 20 61 | 72 67 75 6d 65 6e 74 73 |or two a|rguments|
|000054e0| 20 61 6e 64 20 72 65 74 | 75 72 6e 73 20 6e 6f 20 | and ret|urns no |
|000054f0| 72 65 73 75 6c 74 2e 0a | 43 6f 6e 73 74 72 75 63 |result..|Construc|
|00005500| 74 6f 72 73 20 66 6f 72 | 20 6d 65 74 68 6f 64 73 |tors for| methods|
|00005510| 20 77 69 74 68 20 75 70 | 20 74 6f 20 73 65 76 65 | with up| to seve|
|00005520| 6e 20 61 72 67 75 6d 65 | 6e 74 73 20 61 72 65 20 |n argume|nts are |
|00005530| 64 65 66 69 6e 65 64 2e | 0a 58 40 65 6e 64 20 64 |defined.|.X@end d|
|00005540| 65 66 74 79 70 65 66 6e | 0a 58 40 64 65 66 74 79 |eftypefn|.X@defty|
|00005550| 70 65 66 6e 20 43 6f 6e | 73 74 72 75 63 74 6f 72 |pefn Con|structor|
|00005560| 20 7b 7d 20 52 70 63 4d | 65 74 68 6f 64 43 61 6c | {} RpcM|ethodCal|
|00005570| 6c 20 3c 63 6c 61 73 73 | 20 54 3e 20 28 76 6f 69 |l <class| T> (voi|
|00005580| 64 20 28 54 3a 3a 2a 29 | 28 76 6f 69 64 2a 2a 29 |d (T::*)|(void**)|
|00005590| 20 40 76 61 72 7b 70 72 | 6f 63 7d 29 0a 43 6f 6e | @var{pr|oc}).Con|
|000055a0| 73 74 72 75 63 74 20 61 | 6e 20 40 63 6f 64 65 7b |struct a|n @code{|
|000055b0| 52 70 63 4d 65 74 68 6f | 64 43 61 6c 6c 7d 20 66 |RpcMetho|dCall} f|
|000055c0| 6f 72 20 61 6e 20 6f 62 | 6a 65 63 74 20 61 6e 64 |or an ob|ject and|
|000055d0| 20 6f 6e 65 20 6f 66 20 | 69 74 73 20 6d 65 74 68 | one of |its meth|
|000055e0| 6f 64 73 0a 74 68 61 74 | 20 74 61 6b 65 73 20 61 |ods.that| takes a|
|000055f0| 6e 20 61 72 62 69 74 72 | 61 72 79 20 6e 75 6d 62 |n arbitr|ary numb|
|00005600| 65 72 20 6f 66 20 61 72 | 67 75 6d 65 6e 74 73 20 |er of ar|guments |
|00005610| 61 6e 64 20 72 65 74 75 | 72 6e 20 6e 6f 20 72 65 |and retu|rn no re|
|00005620| 73 75 6c 74 2e 0a 58 40 | 65 6e 64 20 64 65 66 74 |sult..X@|end deft|
|00005630| 79 70 65 66 6e 0a 58 0a | 58 40 64 65 66 74 79 70 |ypefn.X.|X@deftyp|
|00005640| 65 66 6e 20 43 6f 6e 73 | 74 72 75 63 74 6f 72 20 |efn Cons|tructor |
|00005650| 7b 7d 20 52 70 63 4d 65 | 74 68 6f 64 43 61 6c 6c |{} RpcMe|thodCall|
|00005660| 20 3c 63 6c 61 73 73 20 | 54 3e 20 28 76 6f 69 64 | <class |T> (void|
|00005670| 2a 20 28 54 3a 3a 2a 29 | 28 52 70 63 53 65 72 76 |* (T::*)|(RpcServ|
|00005680| 69 63 65 2a 29 20 40 76 | 61 72 7b 70 72 6f 63 7d |ice*) @v|ar{proc}|
|00005690| 29 0a 58 40 65 6e 64 20 | 64 65 66 74 79 70 65 66 |).X@end |deftypef|
|000056a0| 6e 0a 58 40 64 65 66 74 | 79 70 65 66 6e 20 43 6f |n.X@deft|ypefn Co|
|000056b0| 6e 73 74 72 75 63 74 6f | 72 20 7b 7d 20 52 70 63 |nstructo|r {} Rpc|
|000056c0| 4d 65 74 68 6f 64 43 61 | 6c 6c 20 3c 63 6c 61 73 |MethodCa|ll <clas|
|000056d0| 73 20 54 3e 20 28 76 6f | 69 64 2a 20 28 54 3a 3a |s T> (vo|id* (T::|
|000056e0| 2a 29 28 76 6f 69 64 2a | 2c 20 52 70 63 53 65 72 |*)(void*|, RpcSer|
|000056f0| 76 69 63 65 2a 29 20 40 | 76 61 72 7b 70 72 6f 63 |vice*) @|var{proc|
|00005700| 7d 29 0a 58 40 65 6e 64 | 20 64 65 66 74 79 70 65 |}).X@end| deftype|
|00005710| 66 6e 0a 58 40 64 65 66 | 74 79 70 65 66 6e 20 43 |fn.X@def|typefn C|
|00005720| 6f 6e 73 74 72 75 63 74 | 6f 72 20 7b 7d 20 52 70 |onstruct|or {} Rp|
|00005730| 63 4d 65 74 68 6f 64 43 | 61 6c 6c 20 3c 63 6c 61 |cMethodC|all <cla|
|00005740| 73 73 20 54 3e 20 28 76 | 6f 69 64 2a 20 28 54 3a |ss T> (v|oid* (T:|
|00005750| 3a 2a 29 28 76 6f 69 64 | 2a 2c 20 76 6f 69 64 2a |:*)(void|*, void*|
|00005760| 2c 20 52 70 63 53 65 72 | 76 69 63 65 2a 29 20 40 |, RpcSer|vice*) @|
|00005770| 76 61 72 7b 70 72 6f 63 | 7d 29 0a 43 6f 6e 73 74 |var{proc|}).Const|
|00005780| 72 75 63 74 20 61 6e 20 | 40 63 6f 64 65 7b 52 70 |ruct an |@code{Rp|
|00005790| 63 4d 65 74 68 6f 64 43 | 61 6c 6c 7d 20 66 6f 72 |cMethodC|all} for|
|000057a0| 20 61 6e 20 6f 62 6a 65 | 63 74 20 61 6e 64 20 6f | an obje|ct and o|
|000057b0| 6e 65 20 6f 66 20 69 74 | 73 20 6d 65 74 68 6f 64 |ne of it|s method|
|000057c0| 73 0a 74 68 61 74 20 74 | 61 6b 65 73 20 7a 65 72 |s.that t|akes zer|
|000057d0| 6f 2c 20 6f 6e 65 20 6f | 72 20 74 77 6f 20 61 72 |o, one o|r two ar|
|000057e0| 67 75 6d 65 6e 74 73 20 | 61 6e 64 20 72 65 74 75 |guments |and retu|
|000057f0| 72 6e 73 20 61 20 72 65 | 73 75 6c 74 2e 20 43 6f |rns a re|sult. Co|
|00005800| 6e 73 74 72 75 63 74 6f | 72 73 0a 66 6f 72 20 6d |nstructo|rs.for m|
|00005810| 65 74 68 6f 64 73 20 77 | 69 74 68 20 75 70 20 74 |ethods w|ith up t|
|00005820| 6f 20 73 65 76 65 6e 20 | 61 72 67 75 6d 65 6e 74 |o seven |argument|
|00005830| 73 20 61 72 65 20 64 65 | 66 69 6e 65 64 2e 20 55 |s are de|fined. U|
|00005840| 70 6f 6e 20 69 6e 76 6f | 63 61 74 69 6f 6e 2c 20 |pon invo|cation, |
|00005850| 61 0a 70 6f 69 6e 74 65 | 72 20 74 6f 20 74 68 65 |a.pointe|r to the|
|00005860| 20 6f 62 6a 65 63 74 20 | 6f 66 20 74 79 70 65 20 | object |of type |
|00005870| 40 63 6f 64 65 7b 52 70 | 63 53 65 72 76 69 63 65 |@code{Rp|cService|
|00005880| 7d 20 74 68 61 74 20 72 | 65 63 65 69 76 65 64 20 |} that r|eceived |
|00005890| 74 68 65 0a 72 65 71 75 | 65 73 74 20 61 6e 64 20 |the.requ|est and |
|000058a0| 63 61 6c 6c 65 64 20 74 | 68 65 20 6d 65 74 68 6f |called t|he metho|
|000058b0| 64 20 69 73 20 70 61 73 | 73 65 64 20 61 73 20 61 |d is pas|sed as a|
|000058c0| 6e 20 61 64 64 69 74 69 | 6f 6e 61 6c 20 61 72 67 |n additi|onal arg|
|000058d0| 75 6d 65 6e 74 2e 0a 58 | 40 65 6e 64 20 64 65 66 |ument..X|@end def|
|000058e0| 74 79 70 65 66 6e 0a 58 | 40 64 65 66 74 79 70 65 |typefn.X|@deftype|
|000058f0| 66 6e 20 43 6f 6e 73 74 | 72 75 63 74 6f 72 20 7b |fn Const|ructor {|
|00005900| 7d 20 52 70 63 4d 65 74 | 68 6f 64 43 61 6c 6c 20 |} RpcMet|hodCall |
|00005910| 3c 63 6c 61 73 73 20 54 | 3e 20 28 76 6f 69 64 2a |<class T|> (void*|
|00005920| 20 28 54 3a 3a 2a 29 28 | 76 6f 69 64 2a 2a 29 20 | (T::*)(|void**) |
|00005930| 40 76 61 72 7b 70 72 6f | 63 7d 29 0a 43 6f 6e 73 |@var{pro|c}).Cons|
|00005940| 74 72 75 63 74 20 61 6e | 20 40 63 6f 64 65 7b 52 |truct an| @code{R|
|00005950| 70 63 4d 65 74 68 6f 64 | 43 61 6c 6c 7d 20 66 6f |pcMethod|Call} fo|
|00005960| 72 20 61 6e 20 6f 62 6a | 65 63 74 20 61 6e 64 20 |r an obj|ect and |
|00005970| 6f 6e 65 20 6f 66 20 69 | 74 73 20 6d 65 74 68 6f |one of i|ts metho|
|00005980| 64 73 0a 74 68 61 74 20 | 74 61 6b 65 73 20 61 6e |ds.that |takes an|
|00005990| 20 61 72 62 69 74 72 61 | 72 79 20 6e 75 6d 62 65 | arbitra|ry numbe|
|000059a0| 72 20 6f 66 20 61 72 67 | 75 6d 65 6e 74 73 20 61 |r of arg|uments a|
|000059b0| 6e 64 20 72 65 74 75 72 | 6e 73 20 61 20 72 65 73 |nd retur|ns a res|
|000059c0| 75 6c 74 2e 20 55 70 6f | 6e 0a 69 6e 76 6f 63 61 |ult. Upo|n.invoca|
|000059d0| 74 69 6f 6e 2c 20 61 20 | 70 6f 69 6e 74 65 72 20 |tion, a |pointer |
|000059e0| 74 6f 20 74 68 65 20 6f | 62 6a 65 63 74 20 6f 66 |to the o|bject of|
|000059f0| 20 74 79 70 65 20 40 63 | 6f 64 65 7b 52 70 63 53 | type @c|ode{RpcS|
|00005a00| 65 72 76 69 63 65 7d 20 | 74 68 61 74 0a 72 65 63 |ervice} |that.rec|
|00005a10| 65 69 76 65 64 20 74 68 | 65 20 72 65 71 75 65 73 |eived th|e reques|
|00005a20| 74 20 61 6e 64 20 63 61 | 6c 6c 65 64 20 74 68 65 |t and ca|lled the|
|00005a30| 20 6d 65 74 68 6f 64 20 | 69 73 20 70 61 73 73 65 | method |is passe|
|00005a40| 64 20 61 73 20 61 6e 20 | 61 64 64 69 74 69 6f 6e |d as an |addition|
|00005a50| 61 6c 0a 61 72 67 75 6d | 65 6e 74 2e 0a 58 40 65 |al.argum|ent..X@e|
|00005a60| 6e 64 20 64 65 66 74 79 | 70 65 66 6e 0a 58 0a 58 |nd defty|pefn.X.X|
|00005a70| 40 64 65 66 74 79 70 65 | 66 6e 20 43 6f 6e 73 74 |@deftype|fn Const|
|00005a80| 72 75 63 74 6f 72 20 7b | 7d 20 52 70 63 4d 65 74 |ructor {|} RpcMet|
|00005a90| 68 6f 64 43 61 6c 6c 20 | 3c 63 6c 61 73 73 20 54 |hodCall |<class T|
|00005aa0| 3e 20 28 76 6f 69 64 20 | 28 54 3a 3a 2a 29 28 52 |> (void |(T::*)(R|
|00005ab0| 70 63 53 65 72 76 69 63 | 65 2a 29 20 40 76 61 72 |pcServic|e*) @var|
|00005ac0| 7b 70 72 6f 63 7d 29 0a | 58 40 65 6e 64 20 64 65 |{proc}).|X@end de|
|00005ad0| 66 74 79 70 65 66 6e 0a | 58 40 64 65 66 74 79 70 |ftypefn.|X@deftyp|
|00005ae0| 65 66 6e 20 43 6f 6e 73 | 74 72 75 63 74 6f 72 20 |efn Cons|tructor |
|00005af0| 7b 7d 20 52 70 63 4d 65 | 74 68 6f 64 43 61 6c 6c |{} RpcMe|thodCall|
|00005b00| 20 3c 63 6c 61 73 73 20 | 54 3e 20 28 76 6f 69 64 | <class |T> (void|
|00005b10| 20 28 54 3a 3a 2a 29 28 | 76 6f 69 64 2a 2c 20 52 | (T::*)(|void*, R|
|00005b20| 70 63 53 65 72 76 69 63 | 65 2a 29 20 40 76 61 72 |pcServic|e*) @var|
|00005b30| 7b 70 72 6f 63 7d 29 0a | 58 40 65 6e 64 20 64 65 |{proc}).|X@end de|
|00005b40| 66 74 79 70 65 66 6e 0a | 58 40 64 65 66 74 79 70 |ftypefn.|X@deftyp|
|00005b50| 65 66 6e 20 43 6f 6e 73 | 74 72 75 63 74 6f 72 20 |efn Cons|tructor |
|00005b60| 7b 7d 20 52 70 63 4d 65 | 74 68 6f 64 43 61 6c 6c |{} RpcMe|thodCall|
|00005b70| 20 3c 63 6c 61 73 73 20 | 54 3e 20 28 76 6f 69 64 | <class |T> (void|
|00005b80| 20 28 54 3a 3a 2a 29 28 | 76 6f 69 64 2a 2c 20 76 | (T::*)(|void*, v|
|00005b90| 6f 69 64 2a 2c 20 52 70 | 63 53 65 72 76 69 63 65 |oid*, Rp|cService|
|00005ba0| 2a 29 20 40 76 61 72 7b | 70 72 6f 63 7d 29 0a 43 |*) @var{|proc}).C|
|00005bb0| 6f 6e 73 74 72 75 63 74 | 20 61 6e 20 40 63 6f 64 |onstruct| an @cod|
|00005bc0| 65 7b 52 70 63 4d 65 74 | 68 6f 64 43 61 6c 6c 7d |e{RpcMet|hodCall}|
|00005bd0| 20 66 6f 72 20 61 6e 20 | 6f 62 6a 65 63 74 20 61 | for an |object a|
|00005be0| 6e 64 20 6f 6e 65 20 6f | 66 20 69 74 73 20 6d 65 |nd one o|f its me|
|00005bf0| 74 68 6f 64 73 0a 74 68 | 61 74 20 74 61 6b 65 73 |thods.th|at takes|
|00005c00| 20 7a 65 72 6f 2c 20 6f | 6e 65 20 6f 72 20 74 77 | zero, o|ne or tw|
|00005c10| 6f 20 61 72 67 75 6d 65 | 6e 74 73 20 61 6e 64 20 |o argume|nts and |
|00005c20| 72 65 74 75 72 6e 73 20 | 61 20 72 65 73 75 6c 74 |returns |a result|
|00005c30| 2e 20 43 6f 6e 73 74 72 | 75 63 74 6f 72 73 0a 66 |. Constr|uctors.f|
|00005c40| 6f 72 20 6d 65 74 68 6f | 64 73 20 77 69 74 68 20 |or metho|ds with |
|00005c50| 75 70 20 74 6f 20 73 65 | 76 65 6e 20 61 72 67 75 |up to se|ven argu|
|00005c60| 6d 65 6e 74 73 20 61 72 | 65 20 64 65 66 69 6e 65 |ments ar|e define|
|00005c70| 64 2e 20 55 70 6f 6e 20 | 69 6e 76 6f 63 61 74 69 |d. Upon |invocati|
|00005c80| 6f 6e 2c 20 61 0a 70 6f | 69 6e 74 65 72 20 74 6f |on, a.po|inter to|
|00005c90| 20 74 68 65 20 6f 62 6a | 65 63 74 20 6f 66 20 74 | the obj|ect of t|
|00005ca0| 79 70 65 20 40 63 6f 64 | 65 7b 52 70 63 53 65 72 |ype @cod|e{RpcSer|
|00005cb0| 76 69 63 65 7d 20 74 68 | 61 74 20 72 65 63 65 69 |vice} th|at recei|
|00005cc0| 76 65 64 20 74 68 65 0a | 72 65 71 75 65 73 74 20 |ved the.|request |
|00005cd0| 61 6e 64 20 63 61 6c 6c | 65 64 20 74 68 65 20 6d |and call|ed the m|
|00005ce0| 65 74 68 6f 64 20 69 73 | 20 70 61 73 73 65 64 20 |ethod is| passed |
|00005cf0| 61 73 20 61 6e 20 61 64 | 64 69 74 69 6f 6e 61 6c |as an ad|ditional|
|00005d00| 20 61 72 67 75 6d 65 6e | 74 2e 0a 58 40 65 6e 64 | argumen|t..X@end|
|00005d10| 20 64 65 66 74 79 70 65 | 66 6e 0a 58 40 64 65 66 | deftype|fn.X@def|
|00005d20| 74 79 70 65 66 6e 20 43 | 6f 6e 73 74 72 75 63 74 |typefn C|onstruct|
|00005d30| 6f 72 20 7b 7d 20 52 70 | 63 4d 65 74 68 6f 64 43 |or {} Rp|cMethodC|
|00005d40| 61 6c 6c 20 3c 63 6c 61 | 73 73 20 54 3e 20 28 76 |all <cla|ss T> (v|
|00005d50| 6f 69 64 20 28 54 3a 3a | 2a 29 28 76 6f 69 64 2a |oid (T::|*)(void*|
|00005d60| 2a 29 20 40 76 61 72 7b | 70 72 6f 63 7d 29 0a 43 |*) @var{|proc}).C|
|00005d70| 6f 6e 73 74 72 75 63 74 | 20 61 6e 20 40 63 6f 64 |onstruct| an @cod|
|00005d80| 65 7b 52 70 63 4d 65 74 | 68 6f 64 43 61 6c 6c 7d |e{RpcMet|hodCall}|
|00005d90| 20 66 6f 72 20 61 6e 20 | 6f 62 6a 65 63 74 20 61 | for an |object a|
|00005da0| 6e 64 20 6f 6e 65 20 6f | 66 20 69 74 73 20 6d 65 |nd one o|f its me|
|00005db0| 74 68 6f 64 73 0a 74 68 | 61 74 20 74 61 6b 65 73 |thods.th|at takes|
|00005dc0| 20 61 6e 20 61 72 62 69 | 74 72 61 72 79 20 6e 75 | an arbi|trary nu|
|00005dd0| 6d 62 65 72 20 6f 66 20 | 61 72 67 75 6d 65 6e 74 |mber of |argument|
|00005de0| 73 20 61 6e 64 20 72 65 | 74 75 72 6e 73 20 61 20 |s and re|turns a |
|00005df0| 72 65 73 75 6c 74 2e 20 | 55 70 6f 6e 0a 69 6e 76 |result. |Upon.inv|
|00005e00| 6f 63 61 74 69 6f 6e 2c | 20 61 20 70 6f 69 6e 74 |ocation,| a point|
|00005e10| 65 72 20 74 6f 20 74 68 | 65 20 6f 62 6a 65 63 74 |er to th|e object|
|00005e20| 20 6f 66 20 74 79 70 65 | 20 40 63 6f 64 65 7b 52 | of type| @code{R|
|00005e30| 70 63 53 65 72 76 69 63 | 65 7d 20 74 68 61 74 0a |pcServic|e} that.|
|00005e40| 72 65 63 65 69 76 65 64 | 20 74 68 65 20 72 65 71 |received| the req|
|00005e50| 75 65 73 74 20 61 6e 64 | 20 63 61 6c 6c 65 64 20 |uest and| called |
|00005e60| 74 68 65 20 6d 65 74 68 | 6f 64 20 69 73 20 70 61 |the meth|od is pa|
|00005e70| 73 73 65 64 20 61 73 20 | 61 6e 20 61 64 64 69 74 |ssed as |an addit|
|00005e80| 69 6f 6e 61 6c 0a 61 72 | 67 75 6d 65 6e 74 2e 0a |ional.ar|gument..|
|00005e90| 58 40 65 6e 64 20 64 65 | 66 74 79 70 65 66 6e 0a |X@end de|ftypefn.|
|00005ea0| 58 0a 58 40 6e 6f 64 65 | 20 20 20 20 43 61 6c 6c |X.X@node| Call|
|00005eb0| 69 6e 67 20 43 6f 6e 76 | 65 6e 74 69 6f 6e 73 2c |ing Conv|entions,|
|00005ec0| 20 20 2c 20 52 70 63 4d | 65 74 68 6f 64 43 61 6c | , RpcM|ethodCal|
|00005ed0| 6c 2c 20 43 61 6c 6c 62 | 61 63 6b 73 0a 58 40 63 |l, Callb|acks.X@c|
|00005ee0| 6f 6d 6d 65 6e 74 20 6e | 6f 64 65 2d 6e 61 6d 65 |omment n|ode-name|
|00005ef0| 2c 20 20 20 20 20 6e 65 | 78 74 2c 20 20 20 20 20 |, ne|xt, |
|00005f00| 20 20 20 20 20 20 70 72 | 65 76 69 6f 75 73 2c 20 | pr|evious, |
|00005f10| 75 70 0a 58 40 73 75 62 | 73 65 63 74 69 6f 6e 20 |up.X@sub|section |
|00005f20| 40 63 6f 64 65 7b 43 61 | 6c 6c 69 6e 67 20 43 6f |@code{Ca|lling Co|
|00005f30| 6e 76 65 6e 74 69 6f 6e | 73 7d 0a 58 40 63 69 6e |nvention|s}.X@cin|
|00005f40| 64 65 78 20 40 63 6f 64 | 65 7b 63 61 6c 6c 69 6e |dex @cod|e{callin|
|00005f50| 67 20 63 6f 6e 76 65 6e | 74 69 6f 6e 73 7d 0a 58 |g conven|tions}.X|
|00005f60| 0a 41 73 20 63 6f 75 6c | 64 20 62 65 20 73 65 65 |.As coul|d be see|
|00005f70| 6e 20 66 72 6f 6d 20 74 | 68 65 20 70 61 72 61 6d |n from t|he param|
|00005f80| 65 74 65 72 20 74 79 70 | 65 73 20 69 6e 20 74 68 |eter typ|es in th|
|00005f90| 65 20 63 6f 6e 73 74 72 | 75 63 74 6f 72 73 2c 20 |e constr|uctors, |
|00005fa0| 66 75 6e 63 74 69 6f 6e | 73 0a 61 6e 64 20 6d 65 |function|s.and me|
|00005fb0| 74 68 6f 64 73 20 74 68 | 61 74 20 61 72 65 20 63 |thods th|at are c|
|00005fc0| 61 6c 6c 65 64 20 69 6e | 20 72 65 73 70 6f 6e 73 |alled in| respons|
|00005fd0| 65 20 74 6f 20 61 20 72 | 65 71 75 65 73 74 20 66 |e to a r|equest f|
|00005fe0| 72 6f 6d 20 61 20 63 6c | 69 65 6e 74 20 6b 6e 6f |rom a cl|ient kno|
|00005ff0| 77 0a 6f 6e 6c 79 20 61 | 62 6f 75 74 20 70 6f 69 |w.only a|bout poi|
|00006000| 6e 74 65 72 73 20 74 6f | 20 76 6f 69 64 20 61 73 |nters to| void as|
|00006010| 20 61 72 67 75 6d 65 6e | 74 73 20 61 6e 64 20 72 | argumen|ts and r|
|00006020| 65 73 75 6c 74 20 76 61 | 6c 75 65 73 20 62 65 63 |esult va|lues bec|
|00006030| 61 75 73 65 20 74 68 65 | 69 72 0a 72 65 61 6c 20 |ause the|ir.real |
|00006040| 74 79 70 65 20 69 73 20 | 63 6f 64 65 64 20 69 6e |type is |coded in|
|00006050| 20 74 68 65 20 40 63 6f | 64 65 7b 52 70 63 52 65 | the @co|de{RpcRe|
|00006060| 71 75 65 73 74 7d 20 61 | 6e 64 20 6e 6f 74 20 6b |quest} a|nd not k|
|00006070| 6e 6f 77 6e 20 61 74 20 | 63 6f 6d 70 69 6c 65 0a |nown at |compile.|
|00006080| 74 69 6d 65 2e 20 54 68 | 65 20 6f 6e 6c 79 20 77 |time. Th|e only w|
|00006090| 61 79 20 74 6f 20 61 76 | 6f 69 64 20 74 68 69 73 |ay to av|oid this|
|000060a0| 20 69 73 20 74 6f 20 69 | 6d 70 6c 65 6d 65 6e 74 | is to i|mplement|
|000060b0| 20 73 6f 6d 65 20 6b 69 | 6e 64 20 6f 66 20 72 70 | some ki|nd of rp|
|000060c0| 63 67 65 6e 2b 2b 2e 0a | 48 6f 77 65 76 65 72 2c |cgen++..|However,|
|000060d0| 20 49 20 6e 65 76 65 72 | 20 6c 69 6b 65 64 20 74 | I never| liked t|
|000060e0| 68 69 73 20 6b 69 6e 64 | 20 6f 66 20 74 6f 6f 6c |his kind| of tool|
|000060f0| 73 20 61 6e 64 20 49 27 | 6d 20 77 69 6c 6c 69 6e |s and I'|m willin|
|00006100| 67 20 74 6f 20 72 69 73 | 6b 20 61 20 62 69 74 0a |g to ris|k a bit.|
|00006110| 6f 66 20 74 79 70 65 20 | 75 6e 73 61 66 65 6e 65 |of type |unsafene|
|00006120| 73 73 20 69 6e 20 74 68 | 69 73 20 63 61 73 65 2e |ss in th|is case.|
|00006130| 0a 58 0a 57 68 65 6e 20 | 61 20 70 72 6f 63 65 64 |.X.When |a proced|
|00006140| 75 72 65 20 28 6f 72 20 | 6d 65 74 68 6f 64 29 20 |ure (or |method) |
|00006150| 69 73 20 63 61 6c 6c 65 | 64 2c 20 69 74 73 20 61 |is calle|d, its a|
|00006160| 72 67 75 6d 65 6e 74 73 | 20 70 6f 69 6e 74 20 74 |rguments| point t|
|00006170| 6f 20 76 61 6c 75 65 73 | 0a 58 28 74 68 65 20 76 |o values|.X(the v|
|00006180| 61 72 69 61 6e 74 73 20 | 77 69 74 68 20 61 6e 20 |ariants |with an |
|00006190| 61 72 62 69 74 72 61 72 | 79 20 6e 75 6d 62 65 72 |arbitrar|y number|
|000061a0| 20 6f 66 20 61 72 67 75 | 6d 65 6e 74 73 20 72 65 | of argu|ments re|
|000061b0| 63 65 69 76 65 20 61 6e | 20 61 72 72 61 79 20 6f |ceive an| array o|
|000061c0| 66 0a 70 6f 69 6e 74 65 | 72 73 20 74 6f 20 76 61 |f.pointe|rs to va|
|000061d0| 6c 75 65 73 29 20 6f 66 | 20 74 68 65 20 74 79 70 |lues) of| the typ|
|000061e0| 65 73 20 73 70 65 63 69 | 66 69 65 64 20 69 6e 20 |es speci|fied in |
|000061f0| 74 68 65 20 63 6f 6e 73 | 74 72 75 63 74 6f 72 20 |the cons|tructor |
|00006200| 6f 66 20 74 68 65 0a 58 | 40 63 6f 64 65 7b 52 70 |of the.X|@code{Rp|
|00006210| 63 52 65 71 75 65 73 74 | 7d 20 74 68 61 74 20 6c |cRequest|} that l|
|00006220| 65 64 20 74 6f 20 74 68 | 65 20 69 6e 76 6f 63 61 |ed to th|e invoca|
|00006230| 74 69 6f 6e 20 6f 66 20 | 74 68 65 20 70 72 6f 63 |tion of |the proc|
|00006240| 65 64 75 72 65 2e 20 49 | 0a 72 65 63 6f 6d 6d 65 |edure. I|.recomme|
|00006250| 6e 64 20 74 6f 20 61 63 | 63 65 73 73 20 74 68 65 |nd to ac|cess the|
|00006260| 20 76 61 6c 75 65 73 20 | 61 6e 64 20 61 73 73 69 | values |and assi|
|00006270| 67 6e 20 74 68 65 6d 20 | 74 6f 20 6c 6f 63 61 6c |gn them |to local|
|00006280| 20 76 61 72 69 61 62 6c | 65 73 20 6f 66 20 74 68 | variabl|es of th|
|00006290| 65 0a 70 72 6f 63 65 64 | 75 72 65 20 69 6e 20 74 |e.proced|ure in t|
|000062a0| 68 65 20 66 69 72 73 74 | 20 73 74 61 74 65 6d 65 |he first| stateme|
|000062b0| 6e 74 73 2e 20 45 2e 67 | 2e 3a 0a 58 40 65 78 61 |nts. E.g|.:.X@exa|
|000062c0| 6d 70 6c 65 0a 76 6f 69 | 64 2a 20 41 64 64 20 28 |mple.voi|d* Add (|
|000062d0| 76 6f 69 64 2a 20 73 31 | 70 2c 20 76 6f 69 64 2a |void* s1|p, void*|
|000062e0| 20 73 32 70 29 0a 58 40 | 7b 0a 58 20 20 69 6e 74 | s2p).X@|{.X int|
|000062f0| 20 73 31 20 3d 20 2a 28 | 69 6e 74 2a 29 73 31 70 | s1 = *(|int*)s1p|
|00006300| 3b 0a 58 20 20 69 6e 74 | 20 73 32 20 3d 20 2a 28 |;.X int| s2 = *(|
|00006310| 69 6e 74 2a 29 73 32 70 | 3b 0a 58 20 20 2e 2e 2e |int*)s2p|;.X ...|
|00006320| 0a 58 40 65 6e 64 20 65 | 78 61 6d 70 6c 65 0a 58 |.X@end e|xample.X|
|00006330| 0a 54 68 65 20 72 65 74 | 75 72 6e 20 76 61 6c 75 |.The ret|urn valu|
|00006340| 65 20 6f 66 20 74 68 65 | 20 70 72 6f 63 65 64 75 |e of the| procedu|
|00006350| 72 65 20 69 73 20 61 20 | 70 6f 69 6e 74 65 72 20 |re is a |pointer |
|00006360| 74 6f 20 74 68 65 20 72 | 65 73 75 6c 74 2e 20 54 |to the r|esult. T|
|00006370| 68 65 72 65 66 6f 72 65 | 2c 0a 72 65 73 75 6c 74 |herefore|,.result|
|00006380| 73 20 6d 61 79 20 6e 65 | 76 65 72 20 62 65 20 70 |s may ne|ver be p|
|00006390| 75 74 20 69 6e 20 61 75 | 74 6f 6d 61 74 69 63 20 |ut in au|tomatic |
|000063a0| 76 61 72 69 61 62 6c 65 | 73 2e 20 54 68 65 79 20 |variable|s. They |
|000063b0| 6d 75 73 74 20 62 65 20 | 67 6c 6f 62 61 6c 20 6f |must be |global o|
|000063c0| 72 0a 73 74 61 74 69 63 | 2e 20 45 2e 67 2e 3a 0a |r.static|. E.g.:.|
|000063d0| 58 40 65 78 61 6d 70 6c | 65 0a 58 20 20 2e 2e 2e |X@exampl|e.X ...|
|000063e0| 0a 58 20 20 73 74 61 74 | 69 63 20 69 6e 74 20 73 |.X stat|ic int s|
|000063f0| 75 6d 3b 0a 58 20 20 73 | 75 6d 20 3d 20 73 31 20 |um;.X s|um = s1 |
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.