﻿////////////////////////////////////////////////////////////////////////////////////////////////////
// Norman Geiersbach
// Eitido (c) 2008
// Version 1.0.0.0
// Created 03/07/2007
//
// Description
//   
//
// History
//   03/07/2007 File created
////////////////////////////////////////////////////////////////////////////////////////////////////


// Array extensions
////////////////////////////////////////////////////////////////////////////////////////////////////

  Array.prototype.map = function(f)
  {
    var returnArray = [];
    for( i = 0; i < this.length; i++ )
    {
      returnArray.push(f(this[i]));
    }
    
    return returnArray;
  }


// Array utility functions
////////////////////////////////////////////////////////////////////////////////////////////////////

// isArray
// Returns true if the object is an array
  function isArray(obj)
  {
    return obj && !(obj.propertyIsEnumerable('length')) && typeof obj === 'object' && typeof obj.length === 'number';
  }
