# OrSpec

open class OrSpec<T> : CompositeSpec<T> (source)

A CompositeSpec which requires any one of its specs to be true in order to evaluate to true. Uses lazy evaluation.

#### Parameters

<T>

The target type for this Spec

## Constructors

OrSpec
Link copied to clipboard
constructor()
constructor(specs: Array<Spec<in T>>)
constructor(specs: Iterable<out Spec<in T>>)

## Properties

EMPTY
Link copied to clipboard
val EMPTY: OrSpec<out Any>

## Functions

empty
Link copied to clipboard
open fun <T> empty(): OrSpec<T>
equals
Link copied to clipboard
fun equals(o: Any): Boolean
getSpecs
Link copied to clipboard
open fun getSpecs(): List<Spec<in T>>
hashCode
Link copied to clipboard
fun hashCode(): Int
invoke
Link copied to clipboard
operator fun <T> Spec<T>.invoke(arg: T): Boolean

Enables function invocation syntax on Spec instances.

isEmpty
Link copied to clipboard
open fun isEmpty(): Boolean
isSatisfiedBy
Link copied to clipboard
open fun isSatisfiedBy(object: T): Boolean
or
Link copied to clipboard
open fun or(specs: Array<Spec<in T>>): OrSpec<T>