minor: comments

This commit is contained in:
2026-03-20 10:26:22 +01:00
parent 47286248ef
commit 009b6f1b08
3 changed files with 4 additions and 5 deletions

View File

@@ -5,7 +5,7 @@ export default class N1mmServer {
constructor() { constructor() {
this.xmlParser = new XMLParser(); this.xmlParser = new XMLParser();
this.turnHandlers = []; // TurnEventHandler this.turnHandlers = []; // TurnMessageHandler[]
} }
start() { start() {

View File

@@ -9,7 +9,6 @@ export default class RotClient {
this.label = label; this.label = label;
this.ip = clientConfig.ip; this.ip = clientConfig.ip;
this.bands = clientConfig.bands; this.bands = clientConfig.bands;
this.startOffset = null;
this.cachedData = null this.cachedData = null
this.dynamicData = null; this.dynamicData = null;
this.dynamicHandlers = []; this.dynamicHandlers = [];

View File

@@ -1,11 +1,11 @@
import RotClient from './RotClient.js'; import RotClient from './RotClient.js';
import fs from 'node:fs'; import fs from 'node:fs';
export default class RotRouter { // implements TurnEventHandler export default class RotRouter { // implements TurnMessageHandler
constructor() { constructor() {
this.clients = {}; this.clients = {};
this.loadConfig(); this.loadConfig();
this.routerDataHandlers = []; this.routerDataHandlers = []; // array of callbacks accepting (RotClient, data)
} }
@@ -33,7 +33,7 @@ export default class RotRouter { // implements TurnEventHandler
client.turn(msg.az); client.turn(msg.az);
} }
onRotatorData(handler) { // (RotClient, data) onRotatorData(handler) { // will call with (RotClient, data)
this.routerDataHandlers.push(handler); this.routerDataHandlers.push(handler);
} }