Lasso Soft Inc. > Home

[ any->isNotA ]

Method

[any->isNotA] tests if a type is not of the specified type. Requires a type as a parameter.

  • Syntax
any->isnota(::type)
Examples
  • Beginner
  • Intermediate

To test if an object is not a specified type:

Use the [any->isnota] method. The following example tests whether a variable is not of type array, and returns true.

Code

local(mylocal)->isnota(::array)

Result

true

To redefine a local variable if it is not of the specified type:

Use [any->isNotA] within a ternary conditional.

Code

local(mylocal)->isnota(::array) ? #mylocal = array
#mylocal

Result

array()

Recent Comments

No Comments found

Please note that periodically LassoSoft will go through the notes and may incorporate information from them into the documentation. Any submission here gives LassoSoft a non-exclusive license and will be made available in various formats to the Lasso community.

LassoSoft Inc. > Home

 

 

©LassoSoft Inc 2015 | Web Development by Treefrog Inc | PrivacyLegal terms and Shipping | Contact LassoSoft