Class WoTDTDManager

java.lang.Object
io.github.webbasedwodt.DTDManager.impl.WoTDTDManager
All Implemented Interfaces:
DTDManager, DTDManagerReader

public class WoTDTDManager extends Object implements DTDManager
This class provide an implementation of the DTDManager using a WoT Thing Description to implement the Digital Twin Description.
  • Constructor Details

  • Method Details

    • addProperty

      public void addProperty(String rawPropertyName)
      Description copied from interface: DTDManager
      Add a property to the DTD.
      Specified by:
      addProperty in interface DTDManager
      Parameters:
      rawPropertyName - the raw name of the property to add
    • removeProperty

      public boolean removeProperty(String rawPropertyName)
      Description copied from interface: DTDManager
      Remove a property from the DTD.
      Specified by:
      removeProperty in interface DTDManager
      Parameters:
      rawPropertyName - the raw name of the property to remove
      Returns:
      true is correctly removed, false if not present
    • addRelationship

      public void addRelationship(String rawRelationshipName)
      Description copied from interface: DTDManager
      Add a relationship to the DTD.
      Specified by:
      addRelationship in interface DTDManager
      Parameters:
      rawRelationshipName - the raw name of the relationship to add
    • removeRelationship

      public boolean removeRelationship(String rawRelationshipName)
      Description copied from interface: DTDManager
      Remove a relationship from the DTD.
      Specified by:
      removeRelationship in interface DTDManager
      Parameters:
      rawRelationshipName - the raw name of the relationship to remove
      Returns:
      true is correctly removed, false if not present
    • addAction

      public void addAction(String rawActionName)
      Description copied from interface: DTDManager
      Add an action to the DTD.
      Specified by:
      addAction in interface DTDManager
      Parameters:
      rawActionName - the raw name of the action to add
    • removeAction

      public boolean removeAction(String rawActionName)
      Description copied from interface: DTDManager
      Remove an action from the DTD.
      Specified by:
      removeAction in interface DTDManager
      Parameters:
      rawActionName - the raw name of the action to remove
      Returns:
      true is correctly removed, false if not present
    • addEvent

      public void addEvent(String rawEventName)
      Description copied from interface: DTDManager
      Add an event to the DTD.
      Specified by:
      addEvent in interface DTDManager
      Parameters:
      rawEventName - the raw name of the event to add
    • removeEvent

      public boolean removeEvent(String rawEventName)
      Description copied from interface: DTDManager
      Remove an event from the DTD.
      Specified by:
      removeEvent in interface DTDManager
      Parameters:
      rawEventName - the raw name of the event to remove
      Returns:
      true is correctly removed, false if not present
    • getDTD

      public org.eclipse.ditto.wot.model.ThingDescription getDTD()
      Description copied from interface: DTDManagerReader
      Obtain the Digital Twin Description.
      Specified by:
      getDTD in interface DTDManagerReader
      Returns:
      Digital Twin Description implemented with a Thing Description