Package com.thingworx.subscriptions
Class Subscription
- java.lang.Object
-
- com.thingworx.types.events.EventDescriptor
-
- com.thingworx.subscriptions.BaseSubscription
-
- com.thingworx.subscriptions.Subscription
-
- All Implemented Interfaces:
ICharacteristic
,IDiffableObject
,IAspectContainer
,INamedObject
,java.lang.Cloneable
@ThingworxExtensionApiClass(since={6,6}, canInstantiate=true) public final class Subscription extends BaseSubscription implements ICharacteristic, java.lang.Cloneable
-
-
Constructor Summary
Constructors Constructor Description Subscription()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description EntityReference
getOwner()
Returns a reference to the entity that owns the subscription.java.lang.String
getSourceName()
Deprecated.UsegetOwner()
instead.-
Methods inherited from class com.thingworx.subscriptions.BaseSubscription
getDescription, getName, isAsync, isEnabled
-
Methods inherited from class com.thingworx.types.events.EventDescriptor
getAlertName, getEventDescriptor, getEventName, getSource, getSourceProperty, isAlertEvent, isAnyEvent, isPostCommitEvent, isPropertyEvent, setAlertName, setEventName, setSource, setSourceProperty
-
-
-
-
Method Detail
-
getSourceName
@Deprecated @ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={8,0}) public java.lang.String getSourceName()
Deprecated.UsegetOwner()
instead.- Returns:
- the name of the entity owning this subscription
-
getOwner
@ThingworxExtensionApiMethod(since={8,0}) public EntityReference getOwner()
Returns a reference to the entity that owns the subscription.This entity may not necessarily be the subscriber; for example, a thing template or thing shape may define a subscription and thus be the "owner", but the thing that implements the template or shape would be the "subscriber".
The owner is referred to as the "source" in other classes, but this collides with the concept of a "source" on EventDescriptor and can be confusing to developers, so it is explicitly called out as the "owning entity" here.
- Returns:
- a reference to the entity that owns the subscription
-
-