Class None<T>

  extended by com.atlassian.confluence.cache.option.None<T>
Type Parameters:
T -
All Implemented Interfaces:
Option<T>, Serializable

public class None<T>
extends Object
implements Option<T>

A cached option for no value. This is used when the factory does not find the value to cache and the missing value needs to be cached. The readResolve() method has been implemented to return the singleton instance so the Object.equals(Object) and Object.hashCode() methods behave as expected for objects that have propagated over the distributed cache.

See Also:
Serialized Form

Nested Class Summary
Nested classes/interfaces inherited from interface com.atlassian.confluence.cache.option.Option
Field Summary
static None<?> INSTANCE
Constructor Summary
Method Summary
 boolean exists()
 T getOrElse(T otherwise)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail


public static final None<?> INSTANCE
Constructor Detail


public None()
Method Detail


public boolean exists()
Specified by:
exists in interface Option<T>


public T getOrElse(T otherwise)
Specified by:
getOrElse in interface Option<T>

Copyright © 2003-2013 Atlassian. All Rights Reserved.