org.littleshoot.util
Class NoneImpl<T>

java.lang.Object
  extended by org.littleshoot.util.NoneImpl<T>
Type Parameters:
T - The type of object this optional object holds.
All Implemented Interfaces:
Serializable, None<T>, Optional<T>

public final class NoneImpl<T>
extends Object
implements None<T>, Serializable

An implementation of the None interface.

See Also:
Serialized Form

Constructor Summary
NoneImpl()
           
 
Method Summary
<ReturnT> ReturnT
accept(OptionalVisitor<ReturnT,T> visitor)
          Accepts a visitor to this optional object.
 boolean equals(Object other)
          
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NoneImpl

public NoneImpl()
Method Detail

accept

public <ReturnT> ReturnT accept(OptionalVisitor<ReturnT,T> visitor)
Accepts a visitor to this optional object.

Specified by:
accept in interface Optional<T>
Type Parameters:
ReturnT - The type returned by the visitor.
Parameters:
visitor - The visitor.
Returns:
The result of visiting this optional object with the given visitor.

equals

public boolean equals(Object other)

Overrides:
equals in class Object


Copyright © 2011-2013 LittleShoot. All Rights Reserved.