com.atlassian.confluence.api.model.reference
Class EmptyReference<T>

java.lang.Object
  extended by com.atlassian.confluence.api.model.reference.Reference<T>
      extended by com.atlassian.confluence.api.model.reference.EmptyReference<T>
All Implemented Interfaces:
java.lang.Iterable<T>

public final class EmptyReference<T>
extends Reference<T>

A null object reference, indicates that the referenced property is empty.


Method Summary
 boolean exists()
          An empty references value does not exist
 T get()
          Always returns null, the referent object is never defined for an EmptyReference
 java.util.Map<java.lang.Object,java.lang.Object> getIdProperties()
          A map of properties key by the idProperty enum in the model class for the referent object.
 boolean isExpanded()
          An empty reference is expanded, but calling get will return null.
 java.util.Iterator<T> iterator()
           
 java.lang.Class<? extends T> referentClass()
           
 
Methods inherited from class com.atlassian.confluence.api.model.reference.Reference
collapsed, collapsed, empty, getIdProperty, orEmpty, to
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

get

public T get()
Always returns null, the referent object is never defined for an EmptyReference

Specified by:
get in class Reference<T>
Returns:
null

exists

public boolean exists()
An empty references value does not exist

Specified by:
exists in class Reference<T>
Returns:
false

isExpanded

public boolean isExpanded()
An empty reference is expanded, but calling get will return null.

Specified by:
isExpanded in class Reference<T>
Returns:
true

getIdProperties

public java.util.Map<java.lang.Object,java.lang.Object> getIdProperties()
Description copied from class: Reference
A map of properties key by the idProperty enum in the model class for the referent object. The map contains properties sufficient to identify the referent object.

Specified by:
getIdProperties in class Reference<T>
Returns:
a map of id properties keyed by idProperty enum

referentClass

public java.lang.Class<? extends T> referentClass()
Specified by:
referentClass in class Reference<T>
Returns:
the class of the referent object.

iterator

public java.util.Iterator<T> iterator()


Copyright © 2003-2013 Atlassian. All Rights Reserved.