Package org.mongojack.internal.query

Examples of org.mongojack.internal.query.SimpleQueryCondition


         * @param field
         *            The field to check
         * @return the query
         */
        public Q exists(String field) {
            return put(field, QueryOperators.EXISTS, new SimpleQueryCondition(
                    true, false));
        }
View Full Code Here


         * @param field
         *            The field to check
         * @return the query
         */
        public Q notExists(String field) {
            return put(field, QueryOperators.EXISTS, new SimpleQueryCondition(
                    false, false));
        }
View Full Code Here

         * @param regex
         *            The regular expression to match with
         * @return the query
         */
        public Q regex(String field, Pattern regex) {
            return put(field, new SimpleQueryCondition(regex, false));
        }
View Full Code Here

         * @param code
         *            the JavaScript code
         * @return the query
         */
        public Q where(String code) {
            return put("$where", new SimpleQueryCondition(code, false));
        }
View Full Code Here

        protected abstract Q put(String field, String op, QueryCondition value);

        protected Q put(String field, String op, Collection<?> values) {
            List<QueryCondition> conditions = new ArrayList<QueryCondition>();
            for (Object value : values) {
                conditions.add(new SimpleQueryCondition(value));
            }
            return put(field, op,
                    new CollectionQueryCondition(conditions, true));
        }
View Full Code Here

TOP

Related Classes of org.mongojack.internal.query.SimpleQueryCondition

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.