Class ThingShapeInstance

All Implemented Interfaces:
IDiffableObject

@ThingworxExtensionApiClass(since={6,6}, canInstantiate=true) public final class ThingShapeInstance extends ThingShapeImplementation
  • Constructor Details

    • ThingShapeInstance

      public ThingShapeInstance()
  • Method Details

    • getServiceHandler

      @ThingworxExtensionApiMethod(since={6,6}) public IServiceHandler getServiceHandler(String serviceName)
    • getContainer

      @ThingworxExtensionApiMethod(since={6,6}) public EntityReference getContainer()
    • getEventHandler

      @ThingworxExtensionApiMethod(since={6,6}) public IServiceHandler getEventHandler(String handlerName)


      Returns the event handler with the given name.
      Parameters:
      handlerName - - The String version of the handler name - usually the Subscription Name.
      Returns:
      The first occurrence of a handler with this name or null if none are defined.
    • getEventHandlers

      @ThingworxExtensionApiMethod(since={8,4}, deprecatedSince={9,0}) public EventHandlerSet getEventHandlers(String subscriptionName)


      Returns all event handlers with the given handler name. This method is not deprecated because the event handlers are looked up by their respective names and not which event they are firing from. This will always return an eventHandlerSet with exactly 1 entry. Use getEventHandler(String) instead.
      Parameters:
      subscriptionName - - The String version of the handler name - usually the Subscription Name.
      Returns:
      An EventHandlerSet with the handler associated with the provided handlerName or null if none are defined.