Class DelegateItem
- java.lang.Object
-
- io.annot8.implementations.support.delegates.DelegateItem
-
- All Implemented Interfaces:
Item,WithFilter<Content<?>>,WithGroups,WithId,WithMutableProperties
public class DelegateItem extends Object implements Item
-
-
Constructor Summary
Constructors Constructor Description DelegateItem(Item item)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ItemcreateChild()<C extends Content<D>,D>
Content.Builder<C,D>createContent(Class<C> clazz)voiddiscard()Stream<Content<?>>filter(Filter<Content<?>> filter)Optional<Content<?>>find(Filter<Content<?>> filter)Optional<Content<?>>getContent(String id)Stream<Content<?>>getContents()<T extends Content<?>>
Stream<T>getContents(Class<T> clazz)GroupStoregetGroups()StringgetId()Optional<String>getParent()MutablePropertiesgetProperties()booleanhasParent()booleanisDiscarded()voidremoveContent(String id)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.annot8.api.data.Item
removeContent
-
-
-
-
Constructor Detail
-
DelegateItem
public DelegateItem(Item item)
-
-
Method Detail
-
getContent
public Optional<Content<?>> getContent(String id)
- Specified by:
getContentin interfaceItem
-
getContents
public Stream<Content<?>> getContents()
- Specified by:
getContentsin interfaceItem
-
getContents
public <T extends Content<?>> Stream<T> getContents(Class<T> clazz)
- Specified by:
getContentsin interfaceItem
-
createContent
public <C extends Content<D>,D> Content.Builder<C,D> createContent(Class<C> clazz)
- Specified by:
createContentin interfaceItem
-
removeContent
public void removeContent(String id)
- Specified by:
removeContentin interfaceItem
-
isDiscarded
public boolean isDiscarded()
- Specified by:
isDiscardedin interfaceItem
-
createChild
public Item createChild()
- Specified by:
createChildin interfaceItem
-
getGroups
public GroupStore getGroups()
- Specified by:
getGroupsin interfaceWithGroups
-
getProperties
public MutableProperties getProperties()
- Specified by:
getPropertiesin interfaceWithMutableProperties
-
find
public Optional<Content<?>> find(Filter<Content<?>> filter)
- Specified by:
findin interfaceWithFilter<Content<?>>
-
-