Skip to content

Commit acebd75

Browse files
author
Rubens F. N. da Silva
committed
Updates macro adding missing #defines.
1 parent 63dcb85 commit acebd75

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

frontier-prod.xml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7340,4 +7340,25 @@ The purpose is to show that custom authentication strategies can be used exclusi
73407340
]]></Implementation>
73417341
</Method>
73427342
</Class>
7343+
7344+
7345+
<Routine name="frontier" type="INC"><![CDATA[
7346+
#include %ZEN.Utils
7347+
#include %occErrors
7348+
7349+
#define ltrim(%str) $zstrip(%str, "<W")
7350+
#define rtrim(%str) $zstrip(%str, ">W")
7351+
#define trim(%str) $zstrip(%str, "<>W")
7352+
#define trimQuote(%str) $zstrip(%str, "<>", $c(34))
7353+
#define IsSQLQuery(%str) ($$$ucase($extract($$$trim(%str), 6)) = "SELECT")
7354+
#define KeyGroup(%requestKey) $zstrip($zstrip(%requestKey, "<=N"), "=>N")
7355+
#define KeyIndex(%requestKey) $zstrip($zstrip(%requestKey, "<=N"), "<=A")
7356+
#define FormatBoolean(%value) $case(%value, 1: "true", 0: "false", : %value)
7357+
#define BooleanToBinary(%value) $case(%value, "true": 1, "false": 0, : %value)
7358+
#define NormalizeClassName(%cn) if $l(%cn, ".") = 1 && ($e(%cn) = "%") set %cn = "%Library."_$e(%cn, 2, *)
7359+
#define OSSlash $case($$$isWINDOWS, 1: "\", : "/")
7360+
#define AssertClassExists(%o) return:'$isobject(%o) $$$ERROR($$$ClassDoesNotExist, %o)
7361+
#define NULL $s($$$isWINDOWS : "//./nul", 1: "/dev/null")
7362+
#define ObjectOrNull(%obj) $select($isobject(%obj) : %obj, 1: "null")
7363+
]]></Routine>
73437364
</Export>

0 commit comments

Comments
 (0)