From 0a2ce78ccc003c14e9f804ffbf53894939ade915 Mon Sep 17 00:00:00 2001 From: deuce <> Date: Fri, 15 Jan 2016 01:20:39 +0000 Subject: [PATCH] Add flo_outbound(default_zone) method to determine the path to append to the base outbound for a specified node. --- exec/load/fido.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/exec/load/fido.js b/exec/load/fido.js index 5d3bb18975..32c6b011e9 100644 --- a/exec/load/fido.js +++ b/exec/load/fido.js @@ -174,3 +174,16 @@ FIDO.Addr.prototype.toString = function() { return this.str; }; +FIDO.Addr.prototype.flo_outbound = function(default_zone) +{ + // backslash() doesn't work on an empty string + var ret = '_'; + + if (this.zone !== undefined && this.zone !== default_zone) + ret += format(".%03x", this.zone); + ret = backslash(ret); + if (this.point !== undefined) + ret += backslash(format("%08x.pnt", this.point)); + ret += format("%04x%04x.", this.net, this.node); + return ret.substr(1); +}; -- GitLab