Class HtmlDiffModel

java.lang.Object
org.apache.wicket.model.LoadableDetachableModel<String>
org.hippoecm.frontend.plugins.standards.diff.HtmlDiffModel
All Implemented Interfaces:
Serializable, org.apache.wicket.model.IDetachable, org.apache.wicket.model.IModel<String>, org.apache.wicket.util.io.IClusterable

public class HtmlDiffModel extends org.apache.wicket.model.LoadableDetachableModel<String>
See Also:
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
    This model ensures the value is surrounded with ..value.. This is required by the DiffHelper.diffHtml method.
  • Constructor Summary

    Constructors
    Constructor
    Description
    HtmlDiffModel(org.apache.wicket.model.IModel<String> original, org.apache.wicket.model.IModel<String> current)
    Create a HtmlDiffModel using the default HTML diff service
    HtmlDiffModel(org.apache.wicket.model.IModel<String> original, org.apache.wicket.model.IModel<String> current, DiffService diffService)
    Create the model using a predefined diff service.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
     
    protected String
     

    Methods inherited from class org.apache.wicket.model.LoadableDetachableModel

    getObject, isAttached, of, onAttach, onDetach, setObject, toString

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface org.apache.wicket.model.IModel

    as, combineWith, filter, flatMap, isPresent, map, orElse, orElseGet
  • Constructor Details

    • HtmlDiffModel

      public HtmlDiffModel(org.apache.wicket.model.IModel<String> original, org.apache.wicket.model.IModel<String> current)
      Create a HtmlDiffModel using the default HTML diff service
      Parameters:
      original -
      current -
      See Also:
    • HtmlDiffModel

      public HtmlDiffModel(org.apache.wicket.model.IModel<String> original, org.apache.wicket.model.IModel<String> current, DiffService diffService)
      Create the model using a predefined diff service.
      Parameters:
      original -
      current -
      diffService - if it's null, the default HTML diff service is used (see DefaultHtmlDiffService)
      See Also:
  • Method Details

    • load

      protected String load()
      Specified by:
      load in class org.apache.wicket.model.LoadableDetachableModel<String>
    • detach

      public void detach()
      Specified by:
      detach in interface org.apache.wicket.model.IDetachable
      Specified by:
      detach in interface org.apache.wicket.model.IModel<String>
      Overrides:
      detach in class org.apache.wicket.model.LoadableDetachableModel<String>