- Enumerating an array with `for in` iterates over prototype methods the user may have added (like Array.prototype.indexOf for IE support, etc.) Changed all array loops to: for (var i = 0, l = foo.length; i < l; i++) - Same thing when iterating over objects. Though by convention users should not mutate Object.prototype, EcmaScript allows it. Changed all object iterations to check `hasOwnProperty`. Some methods iterate over objects or arrays, in such cases, `hasOwnProperty` was used.
…rays and sorting.
…parently a lot easier than I thought at first)
…e repeated or not. 2. converted stray +"" to framework.util.toString() 3. created util.toString method 4. created util.skipTake 5. changed util.select to work with indexes correctly 6. changed type checking from properties to instanceof where applicable 7. changed skip, take and skipTake to use util.skipTake instead of util.select 8. exposed util.skipTake in jlinq.util
…mmands 2. Added tests for greater, greaterEquals, less, lessEquals, between, betweenEquals 3. Added more sorting tests 4. Requires all tests to clone records. 5. Removed a stray 'i' from the tests... damn cat... 6. Changed the time for the tests to begin for no particular reason at all...
…parameter object which will be used more later. 2. Modified checking for 'cloning' arrays for new queries to work correctly 3. Changed default 'ignoreCase' state to come from a jLinq parameter 4. Added a 'trim' function for strings -- whoo! 5. Fixed a problem with 'each' - had too many field names 6. Changed 'empty' to trim strings before checking them. 7. Changed 'skip' to no longer create a new query as a result but instead continue to use the current query. 8. Changed 'take' to no longer create a new query but instead just return the results as an array 9. Changed 'skipTake' to no longer create a new query but instead just return the results as an array 10. removed 'firstOr', 'lastOr' and 'atOr' and instead added optional parameters for 'first', 'last', and 'at' to do the same thing. 11. Improved 'removed' to allow the same selection parameters as 'select' 12. Added jLinq property for default 'ignoreCase' state 13. Modified 'from' to always clone records before a query. 14. Added new function 'modify' that allows changes to the current records. 15. Added 'trim' as a public jLinq utility function
…modifying a collection 2. Added clone and cloneArray functions 3. Modified 'invoke' function to find the correct object to use 4. Removed pointless string combination in 'empty()' 5. Created property to make queries default to cloning arrays before using them.
…..]. jlinq.from(data) .equals(["util.calculate", 33, 2], 44) .select();