Class BaseCTDisplayRenderer<T extends com.liferay.portal.kernel.model.BaseModel<T>>

java.lang.Object
com.liferay.change.tracking.spi.display.BaseCTDisplayRenderer<T>
All Implemented Interfaces:
CTDisplayRenderer<T>

public abstract class BaseCTDisplayRenderer<T extends com.liferay.portal.kernel.model.BaseModel<T>> extends Object implements CTDisplayRenderer<T>
  • Constructor Details

    • BaseCTDisplayRenderer

      public BaseCTDisplayRenderer()
  • Method Details

    • getEditURL

      public String getEditURL(javax.servlet.http.HttpServletRequest httpServletRequest, T model) throws Exception
      Description copied from interface: CTDisplayRenderer
      Returns the edit URL for the model (optionally null).
      Specified by:
      getEditURL in interface CTDisplayRenderer<T extends com.liferay.portal.kernel.model.BaseModel<T>>
      Parameters:
      httpServletRequest - the request
      model - the model to be edited
      Returns:
      the URL to use for editing the model
      Throws:
      Exception - if an exception occurred
    • getModelClass

      public abstract Class<T> getModelClass()
      Description copied from interface: CTDisplayRenderer
      Returns the model class for this display renderer.
      Specified by:
      getModelClass in interface CTDisplayRenderer<T extends com.liferay.portal.kernel.model.BaseModel<T>>
      Returns:
      the model class for this display renderer
    • getTitle

      public abstract String getTitle(Locale locale, T model) throws com.liferay.portal.kernel.exception.PortalException
      Description copied from interface: CTDisplayRenderer
      Returns the title for the model.
      Specified by:
      getTitle in interface CTDisplayRenderer<T extends com.liferay.portal.kernel.model.BaseModel<T>>
      Parameters:
      locale - to use for translation
      model - the model for this display renderer
      Returns:
      the title for the model
      Throws:
      com.liferay.portal.kernel.exception.PortalException - if a portal exception occurred
    • getTypeName

      public String getTypeName(Locale locale)
      Description copied from interface: CTDisplayRenderer
      Returns the translated type name for the model type.
      Specified by:
      getTypeName in interface CTDisplayRenderer<T extends com.liferay.portal.kernel.model.BaseModel<T>>
      Parameters:
      locale - to use for translation
      Returns:
      the type name for the model type
    • isHideable

      public boolean isHideable(T model)
      Description copied from interface: CTDisplayRenderer
      Returns whether the model may be hidden by default. Hidden models may be filtered out in some views.
      Specified by:
      isHideable in interface CTDisplayRenderer<T extends com.liferay.portal.kernel.model.BaseModel<T>>
      Parameters:
      model - the model to be shown or hidden by default
      Returns:
      whether the model may be hidden by default
    • render

      public void render(DisplayContext<T> displayContext) throws Exception
      Description copied from interface: CTDisplayRenderer
      Renders the model with the display context.
      Specified by:
      render in interface CTDisplayRenderer<T extends com.liferay.portal.kernel.model.BaseModel<T>>
      Parameters:
      displayContext - the context for rendering the model
      Throws:
      Exception - if an exception occurred
    • buildDisplay

      protected void buildDisplay(BaseCTDisplayRenderer.DisplayBuilder<T> displayBuilder) throws com.liferay.portal.kernel.exception.PortalException
      Throws:
      com.liferay.portal.kernel.exception.PortalException
    • getResourceBundle

      protected ResourceBundle getResourceBundle(Locale locale)