cumulocity - Esper create expression - ReferenceError: \"function\" is not defined -


is there problem calling expression inside expression ? cause when do:

create expression int js:hextobin(hex) [   var bin = '';   (var = 0; <= hex.length - 1; += 1) {     bin += ('0000' + parseint(hex.substr(i, 1), 16).tostring(2)).slice(-4);   };   parseint(bin, 2); ];  create expression int js:gettemperature(hex) [   hextobin(hex.substring(4, 6)); ]; 

i got error \"hextobin\" not defined. (gettemperature#2). when put of code in gettemperature works properly.

as said in expression in javascript , has no idea of esper.

but expression not need contain single function. entry script can define multiple javascript functions within single expression if want structure code.


Comments

Popular posts from this blog

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12:test (default-test) on project.Error occurred in starting fork -

windows - Debug iNetMgr.exe unhandle exception System.Management.Automation.CmdletInvocationException -

configurationsection - activeMq-5.13.3 setup configurations for wildfly 10.0.0 -