Home > Class Reference > %SYS namespace > %ZEN.Mojo.Utils

%ZEN.Mojo.Utils

class %ZEN.Mojo.Utils extends %Library.RegisteredObject

Utility methods used by Zen Mojo.

Method Inventory

Parameters

parameter DOMAIN = %ZEN;

Methods

classmethod %CreateLocalizationFiles(pPageClass As %Dictionary.CacheClassname = "", pOutputDirectory As %String = "", pLanguages As %List = "", pFlags As %String = "", pFile As %String = "", ByRef pGet As %Boolean = 0) as %Status
classmethod %GetLocalizationFilename(pPageClass As %Dictionary.CacheClassname = "", pLanguage As %String = "en", pDirectory As %String = {$select($get(pPageClass)'="" As ##class(%ZEN.Utils).%GetPhysicalIncludeDirectory($piece(pPageClass, ".", 1, $length(pPageClass, "."))), 1 As "")}) as %String
classmethod %GetObjectsForSQL(pSQL As %String, Output pList As %Library.ListOfObjects, pMaxRows As %Integer = 100, Output pRowCount As %String, pIncludeEmpty As %Boolean = 0, pSelectMode As %Integer = 1, pArgs...) as %Status
Prepare and execute an SQL query and place the results into a collection of objects for JSON transport.
Note: Replace this when we have the ability to "flow" json output into the normal output stream.
classmethod %PrintVersion() as %Status
Prints all Zen Mojo version strings on the current device.
classmethod %SQLToProxy(pSQL As %String, Output pObject As %ZEN.proxyObject, pIncludeEmpty As %Boolean = 0, pArgs...) as %Status
Helper method to execute an SQL statement and convert it to a list of proxy objects.
classmethod CreateOfflineBundle(pClassName As %String, pTargetFolder As %String) as %Status
Packages most of the required files for a Zen Mojo application and copies them into a target folder. Some dependencies cannot be resolved automatically. All JSINCLUDES and CSSINCLUDES the page and the application include must be copied manually. The same is true for any other external dependency as e.g. images. pClassName: The classname of a Zen Mojo page, without extension. pTargetFolder: The target folder all files are copied to.
classmethod CreateOfflinePage(pClassName As %String, ByRef pFileName As %String = "", pVerbose As %Boolean = 1) as %Status
Creates an offline html version of a Zen Mojo page pClassName: Classname of the Zen Mojo page. Includes package name, excludes extension. pFileName: Returns the name of the file that gets generated pVerbose: Writes information to the current device if true
classmethod GetZenMojoVersion() as %String

Inherited Members

Inherited Methods