api的使用场景是移除数组中某一个指定的项
关于splice的一些资料:http://zhangyaochun.iteye.com/blog/1448006
/* *remove-remove the element from the array* *@param {Array} source---the array* *@param element---the element* *@return {Array}----after removed* */ ZYC.array.remove = function(source,element){ var len = source.length; while (len --){ if(len in source && source[len] === element){ /* *based on the js.lib* array.splice(start,deleteCount,item) *item is the new insert items*/ source.splice(len,1); } } return source; };