Class RichTextFactory.BlockResolver<T extends CDARichBlock>

  • Type Parameters:
    T - a block to be resolved.
    Enclosing class:
    RichTextFactory

    public static class RichTextFactory.BlockResolver<T extends CDARichBlock>
    extends java.lang.Object
    Resolves a block of rich text
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      CDARichNode resolve​(java.util.Map<java.lang.String,​java.lang.Object> raw)
      This method is called in order to try to create rich text block node from a raw map representation.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • BlockResolver

        public BlockResolver​(RichTextFactory.Supplier<T> supplier)
        Create a block resolver based on its given supplier.
        Parameters:
        supplier - an object to create more objects of type T.
    • Method Detail

      • resolve

        public CDARichNode resolve​(java.util.Map<java.lang.String,​java.lang.Object> raw)
        This method is called in order to try to create rich text block node from a raw map representation.
        Parameters:
        raw - representation of the block node coming from Contentful.
        Returns:
        the rich node if resolving was successful.