Interface DeferredContentSourceModelElement

All Superinterfaces:
ContentModelElement, ExtensibilityModelElement

public interface DeferredContentSourceModelElement extends ContentModelElement

This is a ContentModelElement that doesn't place any content at the location where it is placed in the ExtensibilityModel. Instead it is adds content to a previously rendered DeferredContentTargetModelElement that it is associated with. This has been provided to allow WebScripts to add new CSS and JavaScript dependency requests into the <HEAD> element of the HTML page after it has already been rendered.

Author:
David Draper
  • Method Details

    • enterEditMode

      void enterEditMode(String mode)

      Indicates the previously generated deferred content is being edited by an extension. This calls the associated DeferredContentTargetModelElement to indicate that editing is occurring to prepare it for handling subsequent requests.

      Parameters:
      mode - The mode of editing being started, e.g. "replace", "remove", "after", etc.
    • exitEditMode

      void exitEditMode()

      Indicates that the previously generated deferred content has finished being edited by an extension.

    • markAsRemoved

      void markAsRemoved()

      Allow elements to be marked when they're removed. This is done because even if an element is removed from the model it may still be referenced elsewhere. This makes it possible to check that the element is still part of the model when the model is not available.

    • hasBeenRemoved

      boolean hasBeenRemoved()

      Indicates whether or not the element has been removed from the model or not.

      Returns:
      true if the element is no longer in the model and false otherwise.