org.axonframework.mongo3.eventstore.criteria
Class And

java.lang.Object
  extended by org.axonframework.mongo3.eventstore.criteria.MongoCriteria
      extended by org.axonframework.mongo3.eventstore.criteria.And
All Implemented Interfaces:
Criteria

public class And
extends MongoCriteria

Representation of an AND operator for Mongo selection criteria.

Since:
2.0
Author:
Allard Buijze

Constructor Summary
And(MongoCriteria criteria1, MongoCriteria criteria2)
          Returns a criterium that requires both criteria1 and criteria2 to be true.
 
Method Summary
 org.bson.conversions.Bson asBson()
          Returns the Bson representing the criterium.
 
Methods inherited from class org.axonframework.mongo3.eventstore.criteria.MongoCriteria
and, or, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

And

public And(MongoCriteria criteria1,
           MongoCriteria criteria2)
Returns a criterium that requires both criteria1 and criteria2 to be true.

Parameters:
criteria1 - One of the criteria to be evaludated
criteria2 - One of the criteria to be evaludated
Method Detail

asBson

public org.bson.conversions.Bson asBson()
Description copied from class: MongoCriteria
Returns the Bson representing the criterium. This DBObject can be used to select documents in a Mongo Query.

Specified by:
asBson in class MongoCriteria
Returns:
the Bson representing the criterium


Copyright © 2010-2016. All Rights Reserved.