Added neighbor class

2025-08-10 17:34:23 +02:00
parent 3ed8cc0445
commit 3e29e2615d
2 changed files with 32 additions and 1 deletions

@@ -1,3 +1,34 @@
# ModuleClientApi - Neighbor # ModuleClientApi - Neighbor
Class representing a Neighbor of the ModuleClientAPI User. Class representing a Neighbor of the ModuleClientAPI User.
## Methods
Send a packet to this neighbor.
```javascript
Neighbor.send(header, ...args);
```
| Argument | Type | Description |
| -------- | ------ | -------------------------- |
| header | string | The header of the message. |
| args | any[] | Data of any type. |
## Constants
## moduleType
The type of the module.
```javascript
Neighbor.moduleType;
```
## moduleId
The id of the module.
```javascript
Neighbor.moduleId;
```

@@ -73,7 +73,7 @@ NeighborResults.last();
**Returns** [Neighbor](./ModuleClientAPINeighbor) _Neighbor instance._ **Returns** [Neighbor](./ModuleClientAPINeighbor) _Neighbor instance._
## Attributes ## Constants
### length ### length