External: Object

Object

Methods

toString()

Source:
See:

xEach(option) → {external:Object}

call of each Object key-items with (async) Crisp.utilTick and execute option.success and/or option.complete with (async) Crisp.utilTick
This:
Parameters:
Name Type Description
option external:Object
Properties
Name Type Attributes Default Description
success util.utilTickCallback callback function for execute each item with (async) Crisp.utilTick
self AnyItem <optional>
use Object for .call() the option.success an option.complete function
complete util.utilTickCallback <optional>
callback function for exeute on the end of xEach with (async) Crisp.utilTick
async external:Boolean <optional>
enable asynchronus for call of each Object key-items with (async) Crisp.utilTick
start external:Number <optional>
0 start index of each
limit external:Number <optional>
length limit items of each
Source:
Tutorials:
Returns:
Type
external:Object
Examples
{a:'A',b:'B'}.xEach({
  success: function( item, index ) {
    // return; go to the next item 
    // throw new Break(); stop each of items
    console.log('success:', index, item );
  },
  complete: function() {
    console.log('complete');
  }
});
console.log('end');
// logs:
// success: a A
// success: b B
// complete
// end

async

{a:'A',b:'B'}.xEach({
  async: true,
  success: function( item, index ) {
    // return; go to the next item 
    // throw new Break(); stop each of items
    console.log('success:', index, item );
  },
  complete: function() {
    console.log('complete');
  }
});
console.log('end');
// logs:
// end
// success: a A
// success: b B
// complete

xTo(typeopt) → {external:String}

This:
Parameters:
Name Type Attributes Default Description
type external:String <optional>
"json" data format
Implements:
Source:
Returns:
Type
external:String
Example
{ a: 'A' }.xTo(); // '{"a":"A"}'

xTo(typeopt) → {external:String}

This:
Parameters:
Name Type Attributes Default Description
type external:String <optional>
"json" data format
Implements:
Source:
Returns:
Type
external:String
Example
{ a: 'A' }.xTo(); // '{"a":"A"}'

xType(typeopt) → {external:String|external:Boolean}

This:
Parameters:
Name Type Attributes Description
type external:String <optional>
JavaScript type
Implements:
Source:
Returns:
Type
external:String | external:Boolean
Example
(false).xType();          // 'Object'
(true).xType('Object');  // 'true'