This commit is contained in:
Yaroslav Halchenko
2024-06-18 09:30:22 -04:00
committed by GitHub
38 changed files with 62 additions and 62 deletions

View File

@@ -163,7 +163,7 @@
height += 16;
$("#node-input-property-container").editableList('height',height);
}
/** Retrieve editableList items (refactored for re-use in the form inject button)*/
/** Retrieve editableList items (refactored for reuse in the form inject button)*/
function getProps(el, legacy) {
var result = {
props: []
@@ -192,7 +192,7 @@
});
return result;
}
/** Perform inject, optionally sending a custom msg (refactored for re-use in the form inject button)*/
/** Perform inject, optionally sending a custom msg (refactored for reuse in the form inject button)*/
function doInject(node, customMsg) {
var label = node._def.label.call(node,customMsg?customMsg.__user_inject_props__:undefined);
if (label.length > 30) {

View File

@@ -188,7 +188,7 @@ module.exports = function(RED) {
/**
* Helper function for applying changes to an objects properties ONLY when the src object actually has the property.
* This avoids setting a `dst` property null/undefined when the `src` object doesnt have the named property.
* This avoids setting a `dst` property null/undefined when the `src` object does not have the named property.
* @param {object} src Source object containing properties
* @param {object} dst Destination object to set property
* @param {string} propName The property name to set in the Destination object

View File

@@ -84,7 +84,7 @@ module.exports = function(RED) {
}
else {
node.log(RED._("udp.errors.alreadyused",{port:node.port}));
server = udpInputPortsInUse[node.port]; // re-use existing
server = udpInputPortsInUse[node.port]; // reuse existing
if (node.iface) { node.status({text:n.iface+" : "+node.iface}); }
}
@@ -184,7 +184,7 @@ module.exports = function(RED) {
sock.setBroadcast(true);
sock.setMulticastLoopback(false);
}
node.log(RED._("udp.status.re-use",{outport:node.outport,host:node.addr,port:node.port}));
node.log(RED._("udp.status.reuse",{outport:node.outport,host:node.addr,port:node.port}));
if (node.iface) { node.status({text:n.iface+" : "+node.iface}); }
}
else {

View File

@@ -1 +1 @@
[{"id":"ec5a531b.68b65","type":"inject","z":"90acd374.2feda","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"World","payloadType":"str","x":150,"y":100,"wires":[["961abba6.04a028"]]},{"id":"1b0f8c3e.1fd7e4","type":"debug","z":"90acd374.2feda","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":530,"y":100,"wires":[]},{"id":"4e5bf6b2.b4dd58","type":"comment","z":"90acd374.2feda","name":"send a message to output port","info":"Function node can be used to write JavaScript code to handle messages.\nThe input message can be referrenced by `msg` variable. \nA message returned from body of the function is sent to output port.\n\nSee Node-RED user guide about [functions](https://nodered.org/docs/user-guide/writing-functions).","x":170,"y":40,"wires":[]},{"id":"961abba6.04a028","type":"function","z":"90acd374.2feda","name":"return a message","func":"// returning message send it to output port\nmsg.payload = \"Hello, \"+msg.payload +\"!\";\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":330,"y":100,"wires":[["1b0f8c3e.1fd7e4"]]}]
[{"id":"ec5a531b.68b65","type":"inject","z":"90acd374.2feda","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"World","payloadType":"str","x":150,"y":100,"wires":[["961abba6.04a028"]]},{"id":"1b0f8c3e.1fd7e4","type":"debug","z":"90acd374.2feda","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":530,"y":100,"wires":[]},{"id":"4e5bf6b2.b4dd58","type":"comment","z":"90acd374.2feda","name":"send a message to output port","info":"Function node can be used to write JavaScript code to handle messages.\nThe input message can be referenced by `msg` variable. \nA message returned from body of the function is sent to output port.\n\nSee Node-RED user guide about [functions](https://nodered.org/docs/user-guide/writing-functions).","x":170,"y":40,"wires":[]},{"id":"961abba6.04a028","type":"function","z":"90acd374.2feda","name":"return a message","func":"// returning message send it to output port\nmsg.payload = \"Hello, \"+msg.payload +\"!\";\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":330,"y":100,"wires":[["1b0f8c3e.1fd7e4"]]}]

View File

@@ -1 +1 @@
[{"id":"89904b80.4fcd08","type":"inject","z":"d44bc7c8.48eca8","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":true,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":190,"y":100,"wires":[["22c235a0.acb41a"]]},{"id":"20fa70dc.7107f","type":"debug","z":"d44bc7c8.48eca8","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":550,"y":100,"wires":[]},{"id":"cddf88c9.9df018","type":"comment","z":"d44bc7c8.48eca8","name":"asynchronous setup","info":"The `Setup` code that performs asynchronous work can return a promise object of the work. The completion of the promise is waited before starting function body.\n\nSee Node-RED user guide about [functions](https://nodered.org/docs/user-guide/writing-functions).","x":150,"y":40,"wires":[]},{"id":"22c235a0.acb41a","type":"function","z":"d44bc7c8.48eca8","name":"async. setup","func":"// retrieve message value\nmsg.payload = global.get('message');\nreturn msg;","outputs":1,"noerr":0,"initialize":"// set initial value of message\nglobal.set(\"message\", \"Initializing, World!\");\n// create promise for async work\nvar promise = new Promise((resolve, reject) => {\n // async work: wait 1s, then set message\n setTimeout(() => {\n global.set(\"message\", \"Hello, World!\");\n // report this work successfuly ended\n resolve();\n }, 1000);\n});\n// return the promise that should be executed before function code\nreturn promise;","finalize":"","x":370,"y":100,"wires":[["20fa70dc.7107f"]]}]
[{"id":"89904b80.4fcd08","type":"inject","z":"d44bc7c8.48eca8","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":true,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":190,"y":100,"wires":[["22c235a0.acb41a"]]},{"id":"20fa70dc.7107f","type":"debug","z":"d44bc7c8.48eca8","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":550,"y":100,"wires":[]},{"id":"cddf88c9.9df018","type":"comment","z":"d44bc7c8.48eca8","name":"asynchronous setup","info":"The `Setup` code that performs asynchronous work can return a promise object of the work. The completion of the promise is waited before starting function body.\n\nSee Node-RED user guide about [functions](https://nodered.org/docs/user-guide/writing-functions).","x":150,"y":40,"wires":[]},{"id":"22c235a0.acb41a","type":"function","z":"d44bc7c8.48eca8","name":"async. setup","func":"// retrieve message value\nmsg.payload = global.get('message');\nreturn msg;","outputs":1,"noerr":0,"initialize":"// set initial value of message\nglobal.set(\"message\", \"Initializing, World!\");\n// create promise for async work\nvar promise = new Promise((resolve, reject) => {\n // async work: wait 1s, then set message\n setTimeout(() => {\n global.set(\"message\", \"Hello, World!\");\n // report this work successfully ended\n resolve();\n }, 1000);\n});\n// return the promise that should be executed before function code\nreturn promise;","finalize":"","x":370,"y":100,"wires":[["20fa70dc.7107f"]]}]

File diff suppressed because one or more lines are too long

View File

@@ -37,7 +37,7 @@
"id": "8e876a75.e9beb8",
"type": "comment",
"z": "6312c0588348b2d4",
"name": "Write string to a file specied by filename property, the read from the file",
"name": "Write string to a file specified by filename property, the read from the file",
"info": "Write file node can target file using `filename` property.",
"x": 310,
"y": 180,

View File

@@ -644,7 +644,7 @@
"bc-ready": "UDP-Broadcast bereit: __outport__-> __host__:__port__",
"ready": "UDP bereit: __outport__-> __host__:__port__",
"ready-nolocal": "UDP bereit: __host__:__port__",
"re-use": "UDP Wiederverwendung Socket: __outport__-> __host__:__port__"
"reuse": "UDP Wiederverwendung Socket: __outport__-> __host__:__port__"
},
"errors": {
"access-error": "UDP-Zugriffsfehler, Sie benötigen möglicherweise Root-Zugriff für Ports unter 1024",

View File

@@ -721,7 +721,7 @@
"bc-ready": "udp broadcast ready: __outport__ -> __host__:__port__",
"ready": "udp ready: __outport__ -> __host__:__port__",
"ready-nolocal": "udp ready: __host__:__port__",
"re-use": "udp re-use socket: __outport__ -> __host__:__port__"
"reuse": "udp reuse socket: __outport__ -> __host__:__port__"
},
"errors": {
"access-error": "UDP access error, you may need root access for ports below 1024",

View File

@@ -718,7 +718,7 @@
"bc-ready": "udp broadcast prêt : __outport__ -> __host__:__port__",
"ready": "udp prêt : __outport__ -> __host__:__port__",
"ready-nolocal": "udp prêt : __host__:__port__",
"re-use": "socket de réutilisation udp : __outport__ -> __host__:__port__"
"reuse": "socket de réutilisation udp : __outport__ -> __host__:__port__"
},
"errors": {
"access-error": "Erreur d'accès UDP, vous aurez peut-être besoin d'un accès root pour les ports inférieurs à 1024",

View File

@@ -721,7 +721,7 @@
"bc-ready": "udpードはブロードキャストの準備ができています: __outport__ -> __host__:__port__",
"ready": "udpードは準備ができています: __outport__ -> __host__:__port__",
"ready-nolocal": "udpードは準備ができています: __host__:__port__",
"re-use": "udp再利用ソケット: __outport__ -> __host__:__port__"
"reuse": "udp再利用ソケット: __outport__ -> __host__:__port__"
},
"errors": {
"access-error": "UDP接続エラー 管理者権限で1024未満のポート番号にアクセスできる必要があります",

View File

@@ -577,7 +577,7 @@
"bc-ready": "udp노드는 브로드캐스트 준비가 끝났습니다: __outport__ -> __host__:__port__",
"ready": "udp노드는 준비되었습니다: __outport__ -> __host__:__port__",
"ready-nolocal": "udp노드는 준비되었습니다: __host__:__port__",
"re-use": "udp재이용 소켓: __outport__ -> __host__:__port__"
"reuse": "udp재이용 소켓: __outport__ -> __host__:__port__"
},
"errors": {
"access-error": "UDP접속에러 관리자 권한으로 1024미만의 포트번호에 액세스할 필요가 있습니다",

View File

@@ -708,7 +708,7 @@
"bc-ready": "transmissão abrangente udp pronta: __outport__ -> __host __: __ port__",
"ready": "udp pronto: __outport__ -> __host __: __ port__",
"ready-nolocal": "udp pronto: __host __: __ port__",
"re-use": "udp reutilizar soquete: __outport__ -> __host __: __ port__"
"reuse": "udp reutilizar soquete: __outport__ -> __host __: __ port__"
},
"errors": {
"access-error": "Erro de acesso UDP, você pode precisar de acesso root para portas abaixo de 1024",

View File

@@ -604,7 +604,7 @@
"bc-ready": "широковещательная рассылка udp готова: __outport__ -> __host__:__port__",
"ready": "udp готов: __outport__ -> __host__:__port__",
"ready-nolocal": "udp готов: __host__:__port__",
"re-use": "сокет повторного использования udp: __outport__ -> __host__:__port__"
"reuse": "сокет повторного использования udp: __outport__ -> __host__:__port__"
},
"errors": {
"access-error": "Ошибка доступа UDP, Вам может потребоваться доступ с правами root для портов ниже 1024",

View File

@@ -711,7 +711,7 @@
"bc-ready": "udp 广播已就绪: __outport__ -> __host__:__port__",
"ready": "udp 已就绪: __outport__ -> __host__:__port__",
"ready-nolocal": "udp 已就绪: __host__:__port__",
"re-use": "udp 重用套接字: __outport__ -> __host__:__port__"
"reuse": "udp 重用套接字: __outport__ -> __host__:__port__"
},
"errors": {
"access-error": "UDP 访问错误, 你可能需要root权限才能接入1024以下的端口",

View File

@@ -598,7 +598,7 @@
"bc-ready": "udp 廣播已準備好: __outport__ -> __host__:__port__",
"ready": "udp 已準備好: __outport__ -> __host__:__port__",
"ready-nolocal": "udp 已準備好: __host__:__port__",
"re-use": "udp 重用通訊端: __outport__ -> __host__:__port__"
"reuse": "udp 重用通訊端: __outport__ -> __host__:__port__"
},
"errors": {
"access-error": "UDP 訪問錯誤, 你可能需要root許可權才能接入1024以下的埠",