Class DleseEditorRenderer

Direct Known Subclasses:
Msp2EditorRenderer, ResQualEditorRenderer, SIFEditorRenderer

public class DleseEditorRenderer extends EditorRenderer
Renders JSP for DLESE metadata frameworks, adding functionality for choosing from suggested standards, and other dlese-specific input objects, including:
  • Rendering multiBox elements using either Fields File, MUI groups, or StandardsManager (for suggestion service)
  • Rendering repeating elements as MdeStdNode if element has been configured to use standards manager
  • Rendering of textInput elements as textAreas for configured elements of "concepts" and "fields_files" frameworks
  • idiosyncratic rendering of xsd:string elements for certain fields in "adn" and "dlese_anno" frameworks
Author:
ostwald

  • Constructor Details

    • DleseEditorRenderer

      public DleseEditorRenderer()
  • Method Details

    • getMultiBoxInput

      public org.dom4j.Element getMultiBoxInput(String xpath)
      Renders a multibox input (a set of of checkboxes) as an Element using one of several methods of rendering a multiBoxInput, depending on what information is available for the current element.

      • If a MetadataVocab Mapping is available, the multibox input will be rendered by the tag file returned by getMultiBoxTag
      • If the current element has fieldInfo, then the multibox is rendered by the "fieldInfoMultiBox" tag
      • If neither of these are available, then the mulitbox is rendered by a superclass, such as
        invalid reference
        org.dlese.dpc.schemedit.autoform.SimpleJspRenderer#getMultiBoxInput()
      Overrides:
      getMultiBoxInput in class RendererImpl
      Parameters:
      xpath - xpath of element to be rendered as multiBoxInput
      Returns:
      The multiBoxInput as an element
    • getSelectInput

      public org.dom4j.Element getSelectInput(String xpath)
      If there is a vocabLayout (groups file) for this xpath, use it to layout the element.

      NOTES
      1 - the path passed to the "vl__vocabLayoutSingleSelect" is not a "siblingPath" as is the case with multi-selects, but the actual xpath, since here we are collecting a single value
      2 - the "elementPath" attribute (missed-named) determines which method is used to determine an input field's values. since this is a single-value select, we use "valueOf".

      Overrides:
      getSelectInput in class RendererImpl
      Parameters:
      xpath - path to the element to be rendered as a select input
      Returns:
      The selectInput value
    • renderRepeatingElement

      public void renderRepeatingElement()
      If this element has been configured to use suggestion service, render using MdeStdsNode, otherwise render as usual.
      Overrides:
      renderRepeatingElement in class RendererImpl
    • getTextInput

      protected org.dom4j.Element getTextInput(String xpath, SchemaNode schemaNode, GlobalDef typeDef)
      Render configured paths as textArea inputs instead of regular text inputs.
      Overrides:
      getTextInput in class RendererImpl
      Parameters:
      xpath - xpath of input
      schemaNode - schemaNode for this xpath
      typeDef - the typeDefinion for this node
      Returns:
      The textInput value
    • setDebug

      public static void setDebug(boolean bool)
      Sets the debug attribute of the DleseEditorRenderer class
      Parameters:
      bool - The new debug value