{"name":"waterline-criteria","version":"1.0.0","description":"Utility library for use in Sails adapters where you need to filter a list of output using a criteria object","main":"index.js","scripts":{"test":"mocha test --recursive","prepublish":"npm prune"},"repository":{"type":"git","url":"git+ssh://git@github.com/balderdashy/waterline-criteria.git"},"keywords":["waterline","utility"],"author":{"name":"Mike McNeil"},"license":"MIT","dependencies":{"lodash":"~2.4.1"},"testDependencies":{"mocha":"~1.12.0","bower":"~0.10.0","grunt":"~0.4.1","grunt-text-replace":"~0.3.6","grunt-contrib-clean":"~0.5.0","grunt-contrib-uglify":"~0.2.2"},"devDependencies":{"mocha":"^2.0.1"},"gitHead":"8a1fca82ede226e46e05bb3efd57d6cb56cfe875","bugs":{"url":"https://github.com/balderdashy/waterline-criteria/issues"},"homepage":"https://github.com/balderdashy/waterline-criteria#readme","_id":"waterline-criteria@1.0.0","_shasum":"ed936cf8f725e9b7445ab6aea233173ed0622275","_from":".","_npmVersion":"2.8.4","_nodeVersion":"0.10.26","_npmUser":{"name":"mikermcneil","email":"michael.r.mcneil@gmail.com"},"dist":{"shasum":"ed936cf8f725e9b7445ab6aea233173ed0622275","tarball":"http://registry-npm.ywwl.com/waterline-criteria/download/waterline-criteria-1.0.0.tgz","integrity":"sha512-fFSaA8//fYHg6TTYEqUBtyvDHz7LtM++LV8irRzBfDGgHF81siG4aD8vHgeImY/hqU84NbYK4vxR14NeQVbObQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCMeApGk/dtlnKrxV99zTL88sn14qowNg9+hTnoXCaNOAIhALIU+vlv62KzWoY/isoXGp/MrgT9Q1bsf9F1l1X2EHV7"}],"size":8978,"noattachment":false,"key":"/waterline-criteria/-/waterline-criteria-1.0.0.tgz"},"maintainers":[{"name":"balderdashy","email":"mike@balderdash.co"},{"name":"mikermcneil","email":"michael.r.mcneil@gmail.com"},{"name":"particlebanana","email":"particlebanana@gmail.com"},{"name":"sgress454","email":"sgress454@treeline.io"}],"_npmOperationalInternal":{"host":"packages-9-west.internal.npmjs.com","tmp":"tmp/waterline-criteria-1.0.0.tgz_1454671392167_0.7378153025638312"},"directories":{},"readme":"# waterline-criteria\n\nUtilities for working with Waterline criterias, especially for applying them to in-memory datasets.\n\n> This module was designed for adapters which communicate with key/value stores such as [`sails-disk`](https://github.com/balderdashy/sails-disk), [sails-memory](https://github.com/balderdashy/sails-memory), and [sails-redis](https://github.com/balderdashy/sails-redis) (i.e. they already implement the `semantic` interface, but need to implement the `queryable` interface).\n\n\n## Installation\n\n```sh\n$ npm install waterline-criteria --save\n```\n\n## Usage\n\n```js\nvar wlFilter = require('waterline-criteria');\n\nvar SOME_DATASET = [\n  {\n    id: 1,\n    name: 'Lyra'\n  },\n  {\n    id: 2,\n    name 'larry'\n  }\n];\n\nvar results = wlFilter(SOME_DATASET, {\n  where: {\n    name: { contains: 'lyr' }\n  }\n}).results;\n\n// x ==> [{name: 'Lyra', id: 1}]\n```\n\n## Bugs &nbsp; [![NPM version](https://badge.fury.io/js/waterline-criteria.svg)](http://npmjs.com/package/waterline-criteria)\n\nTo report a bug, [click here](http://sailsjs.com/bugs).\n\n> This is a built-in module in the Sails framework and the `sails-disk` adapter.  It is installed automatically when you run `npm install sails`.\n\n#### Version notes\n\nThe master branch of this repository holds `waterline-criteria` used in Sails versions 0.10.0 and up.  If you're looking for the version for the v0.9.x releases of Sails, the source is [located here](https://github.com/balderdashy/waterline-criteria/releases/tag/v0.9.7).\n\n## Contributing &nbsp; [![Build Status](https://travis-ci.org/balderdashy/waterline-criteria.svg?branch=master)](https://travis-ci.org/balderdashy/waterline-criteria)\n\nPlease observe the guidelines and conventions laid out in the [Sails project contribution guide](http://sailsjs.com/contribute) when opening issues or submitting pull requests.\n\n[![NPM package info](https://nodei.co/npm/waterline-criteria.png?downloads=true)](http://npmjs.com/package/waterline-criteria)\n\n## License\n\nThe [Sails framework](http://sailsjs.com) is free and open-source under the [MIT License](http://sailsjs.com/license).\n","publish_time":1454671394447,"_cnpm_publish_time":1454671394447,"dist-tags":{"latest":"2.0.0"}}