Service object methods in automation scripts

The service object has been added in Maximo 7.6 script and is very useful in several scenarios. Here is a list of available methods. For more details refer to this page.

Logging

  • getLogger(loggerName)
  • log_debug(logMsg)
  • log_debug(logMsg, java.lang.Throwable t)
  • log_error(logMsg)
  • log_error(logMsg, java.lang.Throwable t)
  • log_fatal(logMsg)
  • log_fatal(logMsg, java.lang.Throwable t)
  • log_info(logMsg)
  • log_info(logMsg, java.lang.Throwable t)
  • log_warn(logMsg)
  • log_warn(logMsg, java.lang.Throwable t)
  • log(logMsg)
  • logError(logMsg)

Raise errors and warnings

  • error(grp, key)
  • error(grp, key, params)
  • setWarning(warnGrpVal, warnKeyVal, warnparams)

Yes/No/Cancel dialog

  • yncerror(grp, java.lang.String key)
  • yncerror(grp, java.lang.String key, params)
  • yncuserinput()

Integration

  • httpget(url)
  • httpget(url, user, pass)
  • httpgetasbytes(url, user, pass)
  • httppost(url, data)
  • httppost(url, user, pass, data)
  • httppostasbytes(url, user, pass, byte[] data)
  • invokeChannel(channelName)
  • invokeEndpoint(endPointName, metaData, byte[] data)
  • invokeEndpoint(endPointName, metaData, data)
  • wsinteraction(interactionName)
  • raiseSkipTransaction()

Invoke scripts and workflows

  • invokeScript(scriptName)
  • invokeScript(scriptName, context)
  • invokeWorkflow(wfName)

Other methods

  • getMbo()
  • getMboName()
  • getScriptName()
  • getProperty(propName)
Service object methods in automation scripts

Leave a Reply

Your email address will not be published. Required fields are marked *

Scroll to top