You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Afterwards, decoded messages of this type are `instanceof AwesomeMessage`.
313
-
314
313
(*) Besides referencing its reflected type through `AwesomeMessage.$type` and `AwesomeMesage#$type`, the respective custom class is automatically populated with:
315
314
316
315
*`AwesomeMessage.create`
@@ -319,6 +318,23 @@ Afterwards, decoded messages of this type are `instanceof AwesomeMessage`.
319
318
*`AwesomeMessage.verify`
320
319
*`AwesomeMessage.fromObject`, `AwesomeMessage.toObject`, `AwesomeMessage#toObject` and `AwesomeMessage#toJSON`
321
320
321
+
Afterwards, decoded messages of this type are `instanceof AwesomeMessage`.
322
+
323
+
Alternatively, you can also just reuse and extend the internal constructor if custom initialization code is not required:
324
+
325
+
```js
326
+
...
327
+
328
+
// Reuse the internal constructor
329
+
var AwesomeMessage =root.lookupType("awesomepackage.AwesomeMessage").ctor;
The library also supports services but it doesn't make any assumptions about the actual transport channel. Instead, a user must provide a suitable RPC implementation, which is an asynchronous function that takes the reflected service method, the binary request and a node-style callback as its parameters:
0 commit comments