com.google.common.truth
Class CollectionSubject<S extends CollectionSubject<S,T,C>,T,C extends Collection<T>>

java.lang.Object
  extended by com.google.common.truth.Subject<S,C>
      extended by com.google.common.truth.IterableSubject<S,T,C>
          extended by com.google.common.truth.CollectionSubject<S,T,C>
Direct Known Subclasses:
ListSubject

public class CollectionSubject<S extends CollectionSubject<S,T,C>,T,C extends Collection<T>>
extends IterableSubject<S,T,C>


Nested Class Summary
static interface CollectionSubject.Has<E,C extends Collection<E>>
           
 
Nested classes/interfaces inherited from class com.google.common.truth.Subject
Subject.HasField
 
Field Summary
 
Fields inherited from class com.google.common.truth.Subject
failureStrategy
 
Constructor Summary
protected CollectionSubject(FailureStrategy failureStrategy, C collection)
           
 
Method Summary
static
<T,C extends Collection<T>>
CollectionSubject<? extends CollectionSubject<?,T,C>,T,C>
create(FailureStrategy failureStrategy, Collection<T> collection)
           
 CollectionSubject.Has<T,C> has()
           
 void isEmpty()
          Attests that a Collection is empty or fails.
 
Methods inherited from class com.google.common.truth.IterableSubject
create, isNotEmpty, iteratesAs, iteratesAs, iteratesOverSequence
 
Methods inherited from class com.google.common.truth.Subject
check, equals, fail, failWithBadResults, failWithCustomSubject, failWithoutSubject, failWithRawMessage, getDisplaySubject, getSubject, hasField, hashCode, internalCustomName, is, isA, isEqualTo, isNotA, isNotEqualTo, isNotNull, isNull, labeled, named
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CollectionSubject

protected CollectionSubject(FailureStrategy failureStrategy,
                            C collection)
Method Detail

create

public static <T,C extends Collection<T>> CollectionSubject<? extends CollectionSubject<?,T,C>,T,C> create(FailureStrategy failureStrategy,
                                                                                                           Collection<T> collection)

isEmpty

public void isEmpty()
Attests that a Collection is empty or fails.

Overrides:
isEmpty in class IterableSubject<S extends CollectionSubject<S,T,C>,T,C extends Collection<T>>

has

@CheckReturnValue
public CollectionSubject.Has<T,C> has()


Copyright © 2014. All rights reserved.