org.apache.hivemind.impl
Class ElementsProxyList

java.lang.Object
  extended by java.util.AbstractCollection
      extended by java.util.AbstractList
          extended by org.apache.hivemind.impl.ElementsProxyList
All Implemented Interfaces:
java.lang.Iterable, java.util.Collection, java.util.EventListener, java.util.List, RegistryShutdownListener

public final class ElementsProxyList
extends java.util.AbstractList
implements RegistryShutdownListener

The List implementation visible to the client code. It defers to another inner implementation of List; initially this is a ElementsInnerProxyList, but the inner proxy replaces itself with a real List implementation containing the actual configuration elements.

Author:
Howard Lewis Ship

Field Summary
 
Fields inherited from class java.util.AbstractList
modCount
 
Constructor Summary
ElementsProxyList()
           
 
Method Summary
 boolean equals(java.lang.Object o)
           
 java.lang.Object get(int index)
           
 int hashCode()
           
 void registryDidShutdown()
          Invoked when a service is being shutdown, and should release any external resources.
 void setInner(java.util.List list)
           
 int size()
           
 java.lang.String toString()
           
 
Methods inherited from class java.util.AbstractList
add, add, addAll, clear, indexOf, iterator, lastIndexOf, listIterator, listIterator, remove, removeRange, set, subList
 
Methods inherited from class java.util.AbstractCollection
addAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
addAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray
 

Constructor Detail

ElementsProxyList

public ElementsProxyList()
Method Detail

registryDidShutdown

public void registryDidShutdown()
Description copied from interface: RegistryShutdownListener
Invoked when a service is being shutdown, and should release any external resources. A service should not attempt to use any resources or configurations, doing so may result in a runtime exception.

Specified by:
registryDidShutdown in interface RegistryShutdownListener

get

public java.lang.Object get(int index)
Specified by:
get in interface java.util.List
Specified by:
get in class java.util.AbstractList

size

public int size()
Specified by:
size in interface java.util.Collection
Specified by:
size in interface java.util.List
Specified by:
size in class java.util.AbstractCollection

toString

public java.lang.String toString()
Overrides:
toString in class java.util.AbstractCollection

equals

public boolean equals(java.lang.Object o)
Specified by:
equals in interface java.util.Collection
Specified by:
equals in interface java.util.List
Overrides:
equals in class java.util.AbstractList

hashCode

public int hashCode()
Specified by:
hashCode in interface java.util.Collection
Specified by:
hashCode in interface java.util.List
Overrides:
hashCode in class java.util.AbstractList

setInner

public void setInner(java.util.List list)