All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.greenpepper.expectation.Either Maven / Gradle / Ivy

There is a newer version: 4.2.4
Show newest version
package com.greenpepper.expectation;

/**
 * 

Either class.

* * @author oaouattara * @version $Id: $Id */ public class Either implements Collator { private Expectation expectation; /** *

Constructor for Either.

* * @param expectation a {@link com.greenpepper.expectation.Expectation} object. */ public Either(Expectation expectation) { this.expectation = expectation; } /** *

or.

* * @param other a {@link com.greenpepper.expectation.Expectation} object. * @return a {@link com.greenpepper.expectation.Either} object. */ public Either or(Expectation other) { this.expectation = new OrExpectation( this.expectation, other ); return this; } /** *

negate.

* * @return a {@link com.greenpepper.expectation.Either} object. */ public Either negate() { this.expectation = new NotExpectation( this.expectation ); return this; } /** *

toExpectation.

* * @return a {@link com.greenpepper.expectation.Expectation} object. */ public Expectation toExpectation() { return expectation; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy