docs/index.mdView |
---|
3 | 3 … | ### Table of Contents |
4 | 4 … | |
5 | 5 … | - [ID][1] |
6 | 6 … | - [FunctionRef][2] |
7 | | -- [ModuleRef][3] |
8 | | - - [getFuncRef][4] |
9 | | -- [Message][5] |
| 7 … | + - [copy][3] |
| 8 … | +- [ModuleRef][4] |
| 9 … | + - [getFuncRef][5] |
| 10 … | +- [Message][6] |
| 11 … | +- [getType][7] |
10 | 12 … | |
11 | 13 … | ## |
12 | 14 … | |
13 | | -[index.js:11-18][6] |
| 15 … | +[index.js:5-10][8] |
14 | 16 … | |
15 | 17 … | a cbor decoder for the objects |
16 | 18 … | |
17 | | -Type: [Object][7] |
| 19 … | +Type: [Object][9] |
18 | 20 … | |
19 | 21 … | ## ID |
20 | 22 … | |
21 | | -[index.js:45-60][8] |
| 23 … | +[index.js:37-52][10] |
22 | 24 … | |
23 | 25 … | an ID |
24 | 26 … | |
25 | 27 … | **Parameters** |
27 | 29 … | - `id` |
28 | 30 … | |
29 | 31 … | ## FunctionRef |
30 | 32 … | |
31 | | -[index.js:65-87][9] |
| 33 … | +[index.js:57-92][11] |
32 | 34 … | |
33 | 35 … | A function reference |
34 | 36 … | |
35 | 37 … | **Parameters** |
36 | 38 … | |
37 | | -- `opts` **[Object][7]** |
| 39 … | +- `opts` **[Object][9]** |
38 | 40 … | |
| 41 … | +### copy |
| 42 … | + |
| 43 … | +[index.js:84-91][12] |
| 44 … | + |
| 45 … | +Creates a copy of the funcRef |
| 46 … | + |
39 | 47 … | ## ModuleRef |
40 | 48 … | |
41 | | -[index.js:92-120][10] |
| 49 … | +[index.js:97-125][13] |
42 | 50 … | |
43 | 51 … | A module reference |
44 | 52 … | |
45 | 53 … | **Parameters** |
46 | 54 … | |
47 | | -- `exports` **[Object][7]** a map of exported function to params for the funcion if any |
48 | | -- `id` **[ID][11]** the id of the actor |
| 55 … | +- `exports` **[Object][9]** a map of exported function to params for the funcion if any |
| 56 … | +- `id` **[ID][14]** the id of the actor |
49 | 57 … | |
50 | 58 … | ### getFuncRef |
51 | 59 … | |
52 | | -[index.js:107-115][12] |
| 60 … | +[index.js:112-120][15] |
53 | 61 … | |
54 | 62 … | return a function refernce given the name of the function |
55 | 63 … | |
56 | 64 … | **Parameters** |
57 | 65 … | |
58 | | -- `name` **[string][13]** |
| 66 … | +- `name` **[string][16]** |
59 | 67 … | |
60 | | -Returns **[FunctionRef][14]** |
| 68 … | +Returns **[FunctionRef][17]** |
61 | 69 … | |
62 | 70 … | ## Message |
63 | 71 … | |
64 | | -[index.js:125-157][15] |
| 72 … | +[index.js:130-162][18] |
65 | 73 … | |
66 | 74 … | **Extends EventEmitter** |
67 | 75 … | |
68 | 76 … | This implements Messages for Primea |
69 | 77 … | |
70 | 78 … | **Parameters** |
71 | 79 … | |
72 | | -- `opts` **[Object][7]** |
| 80 … | +- `opts` **[Object][9]** |
73 | 81 … | |
| 82 … | +## getType |
| 83 … | + |
| 84 … | +[index.js:169-188][19] |
| 85 … | + |
| 86 … | +returns the type that the object is |
| 87 … | + |
| 88 … | +**Parameters** |
| 89 … | + |
| 90 … | +- `obj` **any** |
| 91 … | + |
| 92 … | +Returns **[String][16]** |
| 93 … | + |
74 | 94 … | [1]: #id |
75 | 95 … | |
76 | 96 … | [2]: #functionref |
77 | 97 … | |
78 | | -[3]: #moduleref |
| 98 … | +[3]: #copy |
79 | 99 … | |
80 | | -[4]: #getfuncref |
| 100 … | +[4]: #moduleref |
81 | 101 … | |
82 | | -[5]: #message |
| 102 … | +[5]: #getfuncref |
83 | 103 … | |
84 | | -[6]: https://github.com/primea/js-primea-objects/blob/3232a5e82edf2a3efc1f35a9be2159d416bca00d/index.js#L11-L18 "Source code on GitHub" |
| 104 … | +[6]: #message |
85 | 105 … | |
86 | | -[7]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object |
| 106 … | +[7]: #gettype |
87 | 107 … | |
88 | | -[8]: https://github.com/primea/js-primea-objects/blob/3232a5e82edf2a3efc1f35a9be2159d416bca00d/index.js#L45-L60 "Source code on GitHub" |
| 108 … | +[8]: https://github.com/primea/js-primea-objects/blob/3de2cd903c7ffab608c66c08ebae41dc3d742d2f/index.js#L5-L10 "Source code on GitHub" |
89 | 109 … | |
90 | | -[9]: https://github.com/primea/js-primea-objects/blob/3232a5e82edf2a3efc1f35a9be2159d416bca00d/index.js#L65-L87 "Source code on GitHub" |
| 110 … | +[9]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object |
91 | 111 … | |
92 | | -[10]: https://github.com/primea/js-primea-objects/blob/3232a5e82edf2a3efc1f35a9be2159d416bca00d/index.js#L92-L120 "Source code on GitHub" |
| 112 … | +[10]: https://github.com/primea/js-primea-objects/blob/3de2cd903c7ffab608c66c08ebae41dc3d742d2f/index.js#L37-L52 "Source code on GitHub" |
93 | 113 … | |
94 | | -[11]: #id |
| 114 … | +[11]: https://github.com/primea/js-primea-objects/blob/3de2cd903c7ffab608c66c08ebae41dc3d742d2f/index.js#L57-L92 "Source code on GitHub" |
95 | 115 … | |
96 | | -[12]: https://github.com/primea/js-primea-objects/blob/3232a5e82edf2a3efc1f35a9be2159d416bca00d/index.js#L107-L115 "Source code on GitHub" |
| 116 … | +[12]: https://github.com/primea/js-primea-objects/blob/3de2cd903c7ffab608c66c08ebae41dc3d742d2f/index.js#L84-L91 "Source code on GitHub" |
97 | 117 … | |
98 | | -[13]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String |
| 118 … | +[13]: https://github.com/primea/js-primea-objects/blob/3de2cd903c7ffab608c66c08ebae41dc3d742d2f/index.js#L97-L125 "Source code on GitHub" |
99 | 119 … | |
100 | | -[14]: #functionref |
| 120 … | +[14]: #id |
101 | 121 … | |
102 | | -[15]: https://github.com/primea/js-primea-objects/blob/3232a5e82edf2a3efc1f35a9be2159d416bca00d/index.js#L125-L157 "Source code on GitHub" |
| 122 … | +[15]: https://github.com/primea/js-primea-objects/blob/3de2cd903c7ffab608c66c08ebae41dc3d742d2f/index.js#L112-L120 "Source code on GitHub" |
| 123 … | + |
| 124 … | +[16]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String |
| 125 … | + |
| 126 … | +[17]: #functionref |
| 127 … | + |
| 128 … | +[18]: https://github.com/primea/js-primea-objects/blob/3de2cd903c7ffab608c66c08ebae41dc3d742d2f/index.js#L130-L162 "Source code on GitHub" |
| 129 … | + |
| 130 … | +[19]: https://github.com/primea/js-primea-objects/blob/3de2cd903c7ffab608c66c08ebae41dc3d742d2f/index.js#L169-L188 "Source code on GitHub" |