Class SclElementAdapter<P extends SclElementAdapter,T>

java.lang.Object
org.lfenergy.compas.sct.commons.scl.SclElementAdapter<P,T>
Direct Known Subclasses:
AbstractDAIAdapter, AbstractDataAttributeAdapter, AbstractDataTypeAdapter, AbstractLNAdapter, AccessPointAdapter, BayAdapter, CommunicationAdapter, ConnectedAPAdapter, ControlBlockAdapter, DataSetAdapter, DataTypeTemplateAdapter, DOAdapter, DOIAdapter, FunctionAdapter, HeaderAdapter, IEDAdapter, InputsAdapter, LDeviceAdapter, LNodeAdapter, LNodeTypeAdapter, RootSDIAdapter, SclRootAdapter, SDIAdapter, SubNetworkAdapter, SubstationAdapter, VoltageLevelAdapter

public abstract class SclElementAdapter<P extends SclElementAdapter,T> extends Object
A representation of the model object SclElementAdapter.

The following features are supported:

  1. Adapter
    • Returns the value of the SclElementAdapter parent reference object
    • Returns the value of the SclElementAdapter current reference object
  2. Principal functions
  3. Checklist functions
  • Field Details

    • parentAdapter

      protected P extends SclElementAdapter parentAdapter
    • currentElem

      protected T currentElem
  • Constructor Details

    • SclElementAdapter

      protected SclElementAdapter(P parentAdapter)
      Constructor
      Parameters:
      parentAdapter - Parent container reference
    • SclElementAdapter

      protected SclElementAdapter(P parentAdapter, T currentElem)
      Constructor
      Parameters:
      parentAdapter - Parent container reference
      currentElem - Current reference
  • Method Details

    • amRootElement

      protected boolean amRootElement()
      Check if node is root in SCL
      Returns:
      true if root node of SCL and false if not
    • elementXPath

      protected abstract String elementXPath()
      Returns XPath path to current element
      Returns:
      message as undefined
    • customInit

      protected void customInit()
    • setCurrentElem

      public final void setCurrentElem(T currentElem)
      Sets current element
      Parameters:
      currentElem - new value of current element
    • amChildElementRef

      protected abstract boolean amChildElementRef()
      Check if node is child of the reference node
      Returns:
      link parent child existence
    • addPrivate

      public void addPrivate(TPrivate tPrivate)
      Adds Private to current element
      Parameters:
      tPrivate - Private to add
    • getXPath

      public String getXPath()
      Gets XPath path to current element from parent element
      Returns:
      path to current element
    • buildFatalReportItem

      public SclReportItem buildFatalReportItem(String message)
      builds message with message content and currentElement xpath
      Parameters:
      message - message
      Returns:
      error description with message and current element xpath