Class DelegateItem

  • All Implemented Interfaces:
    io.annot8.api.data.Item, io.annot8.api.helpers.WithFilter<io.annot8.api.data.Content<?>>, io.annot8.api.helpers.WithGroups, io.annot8.api.helpers.WithId, io.annot8.api.helpers.WithMutableProperties

    public class DelegateItem
    extends Object
    implements io.annot8.api.data.Item
    • Constructor Detail

      • DelegateItem

        public DelegateItem​(io.annot8.api.data.Item item)
    • Method Detail

      • getParent

        public Optional<String> getParent()
        Specified by:
        getParent in interface io.annot8.api.data.Item
      • hasParent

        public boolean hasParent()
        Specified by:
        hasParent in interface io.annot8.api.data.Item
      • getContent

        public Optional<io.annot8.api.data.Content<?>> getContent​(String id)
        Specified by:
        getContent in interface io.annot8.api.data.Item
      • getContents

        public Stream<io.annot8.api.data.Content<?>> getContents()
        Specified by:
        getContents in interface io.annot8.api.data.Item
      • getContents

        public <T extends io.annot8.api.data.Content<?>> Stream<T> getContents​(Class<T> clazz)
        Specified by:
        getContents in interface io.annot8.api.data.Item
      • createContent

        public <C extends io.annot8.api.data.Content<D>,​D> io.annot8.api.data.Content.Builder<C,​D> createContent​(Class<C> clazz)
        Specified by:
        createContent in interface io.annot8.api.data.Item
      • removeContent

        public void removeContent​(String id)
        Specified by:
        removeContent in interface io.annot8.api.data.Item
      • discard

        public void discard()
        Specified by:
        discard in interface io.annot8.api.data.Item
      • isDiscarded

        public boolean isDiscarded()
        Specified by:
        isDiscarded in interface io.annot8.api.data.Item
      • createChild

        public io.annot8.api.data.Item createChild()
        Specified by:
        createChild in interface io.annot8.api.data.Item
      • getGroups

        public io.annot8.api.stores.GroupStore getGroups()
        Specified by:
        getGroups in interface io.annot8.api.helpers.WithGroups
      • getId

        public String getId()
        Specified by:
        getId in interface io.annot8.api.helpers.WithId
      • getProperties

        public io.annot8.api.properties.MutableProperties getProperties()
        Specified by:
        getProperties in interface io.annot8.api.helpers.WithMutableProperties
      • find

        public Optional<io.annot8.api.data.Content<?>> find​(io.annot8.api.filters.Filter<io.annot8.api.data.Content<?>> filter)
        Specified by:
        find in interface io.annot8.api.helpers.WithFilter<io.annot8.api.data.Content<?>>
      • filter

        public Stream<io.annot8.api.data.Content<?>> filter​(io.annot8.api.filters.Filter<io.annot8.api.data.Content<?>> filter)
        Specified by:
        filter in interface io.annot8.api.data.Item
        Specified by:
        filter in interface io.annot8.api.helpers.WithFilter<io.annot8.api.data.Content<?>>