Enum BlockBox.ContentType

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<BlockBox.ContentType>
    Enclosing class:
    BlockBox

    public static enum BlockBox.ContentType
    extends java.lang.Enum<BlockBox.ContentType>
    What type of direct child content this block box contains.

    NOTE: A BlockBox can only contain inline or block content (not both) as direct children. If this constraint is not met by the original document, the BoxBuilder will insert AnonymousBlockBox with inline content.
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      BLOCK
      This block box's direct children consist only of BlockBox and subclassed objects.
      EMPTY
      This block box is empty but may still have border, etc.
      INLINE
      This block box contains inline content in the BlockBox.getInlineContent() property.
      UNKNOWN
      The box builder has not yet run to create our child boxes.
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private ContentType()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static BlockBox.ContentType valueOf​(java.lang.String name)
      Returns the enum constant of this type with the specified name.
      static BlockBox.ContentType[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      • Methods inherited from class java.lang.Enum

        clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • ContentType

        private ContentType()
    • Method Detail

      • values

        public static BlockBox.ContentType[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (BlockBox.ContentType c : BlockBox.ContentType.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static BlockBox.ContentType valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null