Module: WAB::Impl

Defined in:
lib/wab/impl.rb,
lib/wab/impl/data.rb,
lib/wab/impl/expr.rb,
lib/wab/impl/init.rb,
lib/wab/impl/model.rb,
lib/wab/impl/shell.rb,
lib/wab/impl/utils.rb,
lib/wab/impl/handler.rb,
lib/wab/impl/exprs/eq.rb,
lib/wab/impl/exprs/gt.rb,
lib/wab/impl/exprs/in.rb,
lib/wab/impl/exprs/lt.rb,
lib/wab/impl/exprs/or.rb,
lib/wab/impl/bool_expr.rb,
lib/wab/impl/exprs/and.rb,
lib/wab/impl/exprs/gte.rb,
lib/wab/impl/exprs/has.rb,
lib/wab/impl/exprs/lte.rb,
lib/wab/impl/exprs/not.rb,
lib/wab/impl/path_expr.rb,
lib/wab/impl/expr_parser.rb,
lib/wab/impl/exprs/regex.rb,
lib/wab/impl/export_proxy.rb,
lib/wab/impl/configuration.rb,
lib/wab/impl/exprs/between.rb

Overview

Web Application Builder implementation of the WAB APIs.

Defined Under Namespace

Modules: Utils Classes: And, Between, BoolExpr, Configuration, Data, Eq, ExportProxy, Expr, ExprParser, Gt, Gte, Handler, Has, In, Init, Lt, Lte, Model, Not, Or, PathExpr, Regex, Shell

Class Method Summary collapse

Class Method Details

.format_error(msg, error_class = "Error", backtrace = []) ⇒ Object

For an error message string.



9
10
11
12
13
14
15
16
17
18
19
# File 'lib/wab/impl.rb', line 9

def self.format_error(msg, error_class="Error", backtrace=[])
  if msg.is_a?(Exception)
    error_class = msg.class
    backtrace = msg.backtrace
    msg = msg.message
  end
  if !backtrace.empty?
    backtrace.unshift('')
  end
  %|*-*-* #{error_class}: #{msg}#{backtrace.join("\n    ")}|
end