View source

class thx.error.NullArgument extends Error

Available on all platforms

NullArgument is used to detect if arguments of methods are null or empty values.

It should not be used with its contructor but using the static extensions:

public function capitalize(text : String) {
  // ...

Class Fields

static function throwIfEmpty(expr:Dynamic):Dynamic

Like throwIfNull but also throws an exception if the passed argument is empty.

The concept of emptiness applies to String, Array, Iterator and Iterable.

static function throwIfNull<T>(expr:Null<T>):Dynamic

Throws an exception of type NullArgument if the passed identifier (usually a function argument name) is null.

Instance Fields

Toggle inherited fields

var message(default,null):String

defined by Error

Available on cpp, cs, java, neko, php, python, swf

The text message associated with the error.

function new(message:String, ?posInfo:PosInfos):Void

var pos(default,null):PosInfos

defined by Error

The location in code where the error has been instantiated.

var stackItems(default,null):Array<StackItem>

defined by Error

The collected error stack.

function toString():String

defined by Error