Class Normal<D extends AnyDocument<D>,PC extends Content<D,PC>,E extends Normal<D,PC,E,__,_c>,__ extends Content<D,__>,_c extends Normal_c<D,PC,_c>>

java.lang.Object
com.aoapps.html.any.Element<D,PC,E>
com.aoapps.html.any.Normal<D,PC,E,__,_c>
Type Parameters:
D - This document type
PC - The parent content model this element is within
E - This element type
__ - This content model, which will be the parent content model of child elements
_c - This content model as Closeable, which will be the parent content model of child elements
All Implemented Interfaces:
Whitespace, Autofocus<E>, AutocapitalizeUnexpected<E>, Dir<E>, OnabortUnexpected<E>, Onblur<E>, OncanplaythroughUnexpected<E>, OncanplayUnexpected<E>, OnchangeUnexpected<E>, Onclick<E>, Oncontextmenu<E>, Oncopy<E>, Oncut<E>, Ondblclick<E>, Ondrag<E>, Ondragend<E>, Ondragenter<E>, Ondragleave<E>, Ondragover<E>, Ondragstart<E>, Ondrop<E>, OndurationchangeUnexpected<E>, OnemptiedUnexpected<E>, OnendedUnexpected<E>, OnerrorUnexpected<E>, Onfocus<E>, OninputUnexpected<E>, OninvalidUnexpected<E>, Onkeydown<E>, Onkeypress<E>, Onkeyup<E>, OnloadeddataUnexpected<E>, OnloadedmetadataUnexpected<E>, OnloadstartUnexpected<E>, OnloadUnexpected<E>, Onmousedown<E>, Onmouseenter<E>, Onmouseleave<E>, Onmousemove<E>, Onmouseout<E>, Onmouseover<E>, Onmouseup<E>, Onmousewheel<E>, Onpaste<E>, OnpauseUnexpected<E>, OnplayingUnexpected<E>, OnplayUnexpected<E>, OnprogressUnexpected<E>, OnratechangeUnexpected<E>, OnresetUnexpected<E>, OnresizeUnexpected<E>, Onscroll<E>, OnsecuritypolicyviolationUnexpected<E>, OnseekedUnexpected<E>, OnseekingUnexpected<E>, OnselectUnexpected<E>, OnslotchangeUnexpected<E>, OnstalledUnexpected<E>, OnsubmitUnexpected<E>, OnsuspendUnexpected<E>, OntimeupdateUnexpected<E>, OntoggleUnexpected<E>, OnvolumechangeUnexpected<E>, OnwaitingUnexpected<E>, Onwheel<E>, Tabindex<E>, Accesskey<E>, Attribute<E>, Class<E>, Data<E>, Id<E>, Lang<E>, Style<E>, Title<E>, DocumentWriter, GlobalAttributes<E>
Direct Known Subclasses:
AnyBODY, AnyCOLGROUP, AnyDL, AnyHEAD, AnyHTML, AnyMENU, AnyOBJECT, AnyOL, AnyOPTGROUP, AnySELECT, AnyTABLE, AnyTBODY, AnyTFOOT, AnyTHEAD, AnyTR, AnyUL, NormalText, Transparent

public abstract class Normal<D extends AnyDocument<D>,PC extends Content<D,PC>,E extends Normal<D,PC,E,__,_c>,__ extends Content<D,__>,_c extends Normal_c<D,PC,_c>> extends Element<D,PC,E>
Author:
AO Industries, Inc.
  • Constructor Details

    • Normal

      protected Normal(D document, PC pc)
  • Method Details

    • isContentIndented

      protected boolean isContentIndented()
      Determines if this element has indented content.
      Returns:
      true - defaults to indenting
    • doBeforeBody

      protected void doBeforeBody(Writer unsafe) throws IOException
      Called after opening tag is completed, indentation depth is increased (if isContentIndented()), and before the body is invoked.

      An common use-case is to call AnyDocument.autoNl() to begin body on the next line.

      Throws:
      IOException
    • writeClose

      protected abstract void writeClose(Writer unsafe, boolean closeAttributes) throws IOException
      Writes the closing tag.
      Parameters:
      closeAttributes - When true, must end attributes with '>' before writing the closing tag. These are expected to be combined to a single write.
      Throws:
      IOException
    • __

      public <Ex extends Throwable> PC __(IORunnableE<Ex> body) throws IOException, Ex
      Ends attributes, invokes the body, then closes this element.
      Type Parameters:
      Ex - An arbitrary exception type that may be thrown
      Returns:
      The parent content model this element is within
      Throws:
      IOException
      Ex
    • __

      public <Ex extends Throwable> PC __(IOConsumerE<? super __,Ex> body) throws IOException, Ex
      Ends attributes, invokes the body, then closes this element.
      Type Parameters:
      Ex - An arbitrary exception type that may be thrown
      Returns:
      The parent content model this element is within
      Throws:
      IOException
      Ex
      See Also:
    • __

      public PC __() throws IOException
      Ends attributes then closes this element without any body.
      Returns:
      The parent content model this element is within
      Throws:
      IOException
    • _c

      public _c _c() throws IOException
      Ends attributes then begins element content.
      Returns:
      The content model of this element, which will be the parent content model of child elements. This must be ended or closed in order to end the tag. This is well suited for use in a try-with-resources block.
      Throws:
      IOException
      See Also:
    • new__

      protected abstract __ new__()
      Creates a new instance of uncloseable content.
      See Also:
    • new_c

      protected abstract _c new_c()
      Creates a new instance of closeable content.
      See Also: