org.axonframework.eventstore.mongo.criteria
Class MongoCriteria

java.lang.Object
  extended by org.axonframework.eventstore.mongo.criteria.MongoCriteria
All Implemented Interfaces:
Criteria
Direct Known Subclasses:
And, CollectionCriteria, Equals, Or, SimpleMongoOperator

public abstract class MongoCriteria
extends Object
implements Criteria

Abstract class for Mongo-based criteria.

Since:
2.0
Author:
Allard Buijze

Constructor Summary
MongoCriteria()
           
 
Method Summary
 Criteria and(Criteria criteria)
          Returns a criteria instance where both this and given criteria must match.
abstract  com.mongodb.DBObject asMongoObject()
          Returns the DBObject representing the criterium.
 Criteria or(Criteria criteria)
          Returns a criteria instance where either this or the given criteria must match.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MongoCriteria

public MongoCriteria()
Method Detail

and

public Criteria and(Criteria criteria)
Description copied from interface: Criteria
Returns a criteria instance where both this and given criteria must match.

Specified by:
and in interface Criteria
Parameters:
criteria - The criteria that must match
Returns:
a criteria instance that matches if both this and criteria match

or

public Criteria or(Criteria criteria)
Description copied from interface: Criteria
Returns a criteria instance where either this or the given criteria must match.

Specified by:
or in interface Criteria
Parameters:
criteria - The criteria that must match if this doesn't match
Returns:
a criteria instance that matches if this or the given criteria match

asMongoObject

public abstract com.mongodb.DBObject asMongoObject()
Returns the DBObject representing the criterium. This DBObject can be used to select documents in a Mongo Query.

Returns:
the DBObject representing the criterium

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2010-2016. All Rights Reserved.