E - The type of the entries.@ThreadSafe @DefaultAnnotation(value=edu.umd.cs.findbugs.annotations.NonNull.class) public final class SynchronizedInputShop<E extends Entry> extends DecoratingInputShop<E,InputShop<E>>
SynchronizedOutputShopdelegate| Constructor and Description |
|---|
SynchronizedInputShop(InputShop<E> input)
Constructs a concurrent input shop.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
InputShop<E> |
getDelegate()
Returns the decorated input shop.
|
E |
getEntry(String name)
Returns the entry for the given
name or
null if no entry with this name exists in this container. |
InputSocket<? extends E> |
getInputSocket(String name)
Returns an input socket for reading from the entry with the given name.
|
int |
getSize()
Returns the number of entries in this container.
|
Iterator<E> |
iterator()
Returns a new iterator for all entries in this container.
|
toStringpublic void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class DecoratingInputShop<E extends Entry,InputShop<E extends Entry>>IOExceptionpublic InputShop<E> getDelegate()
public E getEntry(String name)
EntryContainername or
null if no entry with this name exists in this container.public InputSocket<? extends E> getInputSocket(String name)
InputServicegetInputSocket in interface InputService<E extends Entry>getInputSocket in class DecoratingInputShop<E extends Entry,InputShop<E extends Entry>>name - an entry name.public int getSize()
EntryContainerpublic Iterator<E> iterator()
EntryContainerFirst, the iteration must be consistent: Multiple iterators must iterate the same entries in the same order again unless the set of entries has changed.
Next, the iteration should also reflect the natural order of the entries in this container. For example, if this container represents an archive file, the iteration should reflect the natural order of the entries in the archive file.
Copyright © 2004-2011 Schlichtherle IT Services. All Rights Reserved.