Class Thing
- All Implemented Interfaces:
ISupportsAccessModifier
,IConfigurableObject
,INotScriptFriendly
,ISupportsDeprecation
,IDiffableObject
,IAlertProvider
,IAvatar
,IEntityLifeCycleEvent
,IEventMetadataProvider
,IEventProvider
,IPersistable
,IPropertyProvider
,IServiceMetadataProvider
,IServiceProvider
,IShapeProvider
,ITaggableObject
,IDependencyScannableObject
,IImportDependencyHandler
,IHierarchicalEntity
,IEntityDefinition
,IPersistableObject<String>
,IDesignTimeSecurable
,IDesignTimeSecurableEntity
,IRunTimeSecurable
,IRunTimeSecurableEntity
,ISecurable
,IVisibilitySecurable
,IVisibilitySecurableEntity
,IEventProcessor
,IAspectContainer
,INamedObject
,Serializable
- Direct Known Subclasses:
DataThing
,FileRepositoryThing
,LogRetrievalStrategy
,NotificationHandler
,RemoteThing
,ReportingStrategy
,SecurityMonitorThing
An entity containing services, properties, events, and subscriptions representing an instance of a thing based on a specified template.
Thing entities are one of the fundamental entity types in Thingworx. They are used to represent an instance of an object that is
actionable (services), declarative (properties), reactive (events), and observable (subscriptions). Things must define a single
ThingTemplate
to inherit shared functionality, as well as any number of
ThingShape
s that add additional functionality that is independent of the
ThingTemplate
hierarchy. The consolidation of all inherited functionality must not have any name collisions within the same
behavioral type (i.e., a property and service can share the same name, but two services cannot).
All Things have the following lifecycle:
ThingState |
OFF | → | ON | → | OFF | → | N/A |
Events | Inactive → Preinitializing (Entity) → Validating → Initializing (Entity) → Initializing (Thing) → Starting | → | Notifying → Active → Stopping | → | Cleaning Up → Deactivated | → | Disposing |
These lifecycle events correspond to the following methods:
State | Method | Description |
---|---|---|
Preinitialize (Entity) 1 | RootEntity#preInitializeEntity() |
Occurs only during the entity import process. |
Validate1 | Thing#validateConfiguration(ImportedEntityCollection) |
Occurs only during the entity import process. Validates all requirements of the entity. |
Initialize (Entity) | Thing#initializeEntity(ContextType) |
Initializes the entity. Should be used to initialize anything needed by thing initialization. |
Initialize (Thing) with patch operation | Thing#initializeThing(ContextType) |
Initializes the thing. Should be used to construct the initial state of the thing. |
Start | Thing#startThing(ContextType) |
Brings the thing into an active state. Initialization should finish at this step. |
Notify | Thing#processStartNotification(ContextType) |
Thing has entered active state and is about to run. Any final processing must occur here. |
Stop | Thing#stopThing(ContextType) |
Thing has received a stop request. Any back-end processing should be torn down. |
Cleanup | Thing#cleanupThing(ContextType) |
Thing has stopped and needs to clean up its resources. Any managed resources should be cleaned up. |
Dispose | Thing#dispose() |
Removes any remaining references of this entity (e.g., networks). |
When developing extensions, you must extend from the Thing
class for any classes that are assigned to a
com.thingworx.thingpackages.ThingPackage entity. If the package is assigned to a thing in the extension, then the code will execute in
the context of that entity. If the package is assigned to a thing template, then the code will execute in the context of the things that
have been created with the thing template in its hierarchy.
Thing
is not thread-safe nor is it designed to be mutated by multiple threads simultaneously.
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic org.slf4j.Logger
static final PropertyDefinitionCollection
static final String
static final String
static final String
static final String
static final String
Fields inherited from class com.thingworx.entities.RootEntity
BASIC_PROPERTY_DEFINITIONS, EXCLUDED_ENTITY_TYPES_IN_PROJECT
Fields inherited from class com.thingworx.types.NamedObject
NAME_COMPARATOR
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
AcknowledgeAlert
(String property, String message) Service Category: Alerts Service Description: Acknowledge an active alert.void
acknowledgeAlertByProperty
(String propertyName, String message) void
acknowledgeAlertByPropertyAndName
(String propertyName, String alertName, String message) void
acknowledgeAllAlerts
(String message) void
AcknowledgeAllAlerts
(String message) Service Category: Alerts Service Description: Acknowledge all active alerts.void
AddBooleanValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Boolean value) void
AddBooleanValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Boolean value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
AddDateTimeValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, org.joda.time.DateTime value) void
AddDateTimeValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, org.joda.time.DateTime value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
AddDynamicSubscription
(String thingName, String eventName, String propertyName, String serviceName) Service Category: Subscriptions Service Description: Add a dynamic subscription.void
AddEventDefinition
(String name, String description, String category, String dataShape, Boolean remote, String remoteEventName) Service Category: Metadata Service Description: Add or update an event definition.void
AddImageValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, byte[] value) void
AddImageValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, byte[] value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
AddInfoTableValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, InfoTable value) void
AddInfoTableValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, InfoTable value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
AddIntegerValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Integer value) void
AddIntegerValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Integer value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
AddLocationValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Location value) void
AddLocationValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Location value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
AddLongValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Long value) void
AddLongValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Long value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
AddNumberValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Double value) void
AddNumberValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Double value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
AddOrUpdateAlert
(String property, String alertType, String alertName, String description, Boolean enabled, Integer priority, InfoTable attributes, Boolean persistent) Service Category: Alerts Service Description: Add or update an alert for a property.addProperty
(PropertyDefinition propertyDefinition) void
AddPropertyDefinition
(String name, String description, String type, String category, String dataShape, Boolean readOnly, Boolean persistent, Boolean logged, Boolean indexed, String dataChangeType, Double dataChangeThreshold, Boolean remote, String remotePropertyName, Integer timeout, String pushType, Double pushThreshold, String defaultValue, org.json.JSONObject remoteBindingAspects) Deprecated.void
AddPropertyDefinition
(String name, String description, String type, String category, String dataShape, Boolean readOnly, Boolean persistent, Boolean logged, Boolean indexed, String dataChangeType, Double dataChangeThreshold, Boolean remote, String remotePropertyName, Integer timeout, String pushType, Double pushThreshold, String defaultValue, org.json.JSONObject remoteBindingAspects, org.json.JSONObject accessModifier) Service Category: Metadata Service Description: Add a property definition.void
AddPropertyDefinition
(String name, String description, String type, String category, String dataShape, Boolean readOnly, Boolean persistent, Boolean logged, String dataChangeType, Double dataChangeThreshold, Boolean remote, String remotePropertyName, Integer timeout, String pushType, Double pushThreshold, String defaultValue) Deprecated.As of release 8.0, replaced by AddPropertyDefinition(String, String, String, String, String, Boolean, Boolean, Boolean, String, Double, Boolean, String, Integer, String, Double, String, JSONObject)void
AddPropertyDefinition
(String name, String description, String type, String category, String dataShape, Boolean readOnly, Boolean persistent, Boolean logged, String dataChangeType, Double dataChangeThreshold, Boolean remote, String remotePropertyName, Integer timeout, String pushType, Double pushThreshold, String defaultValue, org.json.JSONObject remoteBindingAspects) Deprecated.AddPropertyDefinitions
(InfoTable values, Boolean ignoreInvalidDefinitions) Service Category: Metadata Service Description: Add multiple property definitions at once.void
AddPropertyTransformDefinition
(String name, String description, String category, Boolean persistent, Boolean logged, Integer timeout, InfoTable propertyTransformConfig) Service Category: Metadata Service Description: Add a property transform definition.void
AddServiceDefinition
(String name, String description, String category, InfoTable parameters, InfoTable resultType, Boolean remote, String remoteServiceName, Integer timeout) Deprecated.void
AddServiceDefinition
(String name, String description, String category, InfoTable parameters, InfoTable resultType, Boolean remote, String remoteServiceName, Integer timeout, org.json.JSONObject accessModifier) Service Category: Metadata Service Description: Add or update a service definition.void
AddStringValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, String value) void
AddStringValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, String value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
AddTags
(TagCollection tags) Service Category: Metadata Service Description: Append additional tags to an entity.void
AddThingCodeValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, ThingCode value) void
AddThingCodeValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, ThingCode value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
AddVec2ValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Vec2 value) void
AddVec2ValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Vec2 value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
AddVec3ValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Vec3 value) void
AddVec3ValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Vec3 value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
AddVec4ValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Vec4 value) void
AddVec4ValueStreamEntry
(org.joda.time.DateTime timestamp, String propertyName, Vec4 value, String quality) Service Category: StreamEntries Service Description: Add a new stream entry.void
checkDemandRead
(ThingProperty property) protected void
checkPropertyName
(String propertyName) protected void
protected void
cleanupThing
(ContextType contextType) void
DisableAlertsForProperty
(String property, String alertName, Boolean persistent) Service Category: Alerts Service Description: Disable alert(s) for a property.void
DisableAllAlerts
(Boolean persistent) Service Category: Alerts Service Description: Disable all alerts for a thing.void
DisableSubscription
(String subscriptionName) Service Category: Subscriptions Service Description: Disable Subscription.void
DisableSubscription
(String thingName, String eventName, String propertyName) Deprecated.void
Service Category: Lifecycle Service Description: Disable this thing.void
void
dispatchEvent
(ThingworxEvent event) void
dispose()
void
EnableAlertsForProperty
(String property, String alertName, Boolean persistent) Service Category: Alerts Service Description: Enable alert(s) for a property.void
EnableAllAlerts
(Boolean persistent) Service Category: Alerts Service Description: Enable all alerts for a thing.void
EnableSubscription
(String subscriptionName) Service Category: Subscriptions Service Description: Enable Subscription.void
EnableSubscription
(String thingName, String eventName, String propertyName) Deprecated.void
Service Category: Lifecycle Service Description: Enable this thing.void
fireEvent
(EventDefinition eventDefinition, org.joda.time.DateTime timestamp, ValueCollection eventData) GetAlertDefinition
(String property, String alertName) Service Category: Alerts Service Description: Get alert definition for a property.GetAlertDefinitions
(String property) Service Category: Alerts Service Description: Get effective alert definitions for a property.getAlertsForProperty
(String propertyName)
Returns Effective Alerts including local and inherited from ancestors.GetAlertStatus
(String property, String alertName) Service Category: Alerts Service Description: Get the Status of the given Alert.Service Category: Alerts Service Description: Get the Statuses of the given Alerts.GetAlertStatusesForProperty
(String property) Service Category: Alerts Service Description: Get the Statuses of the given Alerts.GetAlertSummary
(Boolean onlyAcknowledged, Boolean onlyUnacknowledged, Double maxItems) Service Category: Alerts Service Description: Get alert summary status.GetAlertSummaryForProperty
(String property, Boolean onlyAcknowledged, Boolean onlyUnacknowledged, Double maxItems) Service Category: Alerts Service Description: Get alert summary for a property.Service Category: Alerts Service Description: Get All AnomalyAlert Training Statistics on this Thing.GetAnomalyAlertTrainingStatisticsForAlert
(String property, String alertName) Service Category: Alerts Service Description: Get Training Statistics for given Alert.Service Category: Alerts Service Description: Get AnomalyAlert Training Statistics for given Property.Service Category: Metadata Service Description: Get avatar image.GetBooleanAlertParameter
(String property, String alertName, String parameterName) Service Category: Alerts Service Description: Get a boolean alert parameter.GetBooleanPropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property value.org.joda.time.DateTime
GetDateTimeAlertParameter
(String property, String alertName, String parameterName) Service Category: Alerts Service Description: Get a date alert parameter.org.joda.time.DateTime
GetDateTimePropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property value.getEffectiveAlertDefinition
(String property, String alertName) GetEffectiveLocalPropertyBinding
(String propertyName) Service Category: Bindings Service Description: Get the effective local property binding for a property.
Get the effective (inherited and local) property binding for a propertyService Category: Bindings Service Description: Get the effective local property bindings.
Get all effective (inherited and local) property bindings for this thingGetEffectivePropertyLogging
(String propertyName) Service Category: DataLogging Service Description: Get the logging status of a specific property from the effective Thing shape.getEffectiveServiceDefinition
(String serviceName) Service Category: Mashups Service Description: Get home mashup.Service Category: Identifier Service Description: Get the identifier for a thing.byte[]
GetImagePropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property value.Service Category: Metadata Service Description: Get the implemented thing shapes for this thing.GetIncomingLocalPropertyBinding
(String propertyName) Service Category: Bindings Service Description: Get incoming local bindings to this thing for the given property.
Get incoming local bindings to this thing for the given propertyService Category: Bindings Service Description: Get all things and their properties that have local bindings on this thing.
Get all things and their properties that have local bindings on this thing
Returns the specified property definition for this instance if visible.Deprecated.UsegetInstanceMultiEventSubscriptions()
instead.GetIntegerAlertParameter
(String property, String alertName, String parameterName) Service Category: Alerts Service Description: Get a numeric alert parameter.GetIntegerPropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property value.GetLocalAlertDefinitions
(String property) Service Category: Alerts Service Description: Get local alert definitions for a property.Service Category: Metadata Service Description: Get the locally implemented thing shapes for this thing.GetLocalPropertyBinding
(String propertyName) Service Category: Bindings Service Description: Get the property binding for a property.GetLocationAlertParameter
(String property, String alertName, String parameterName) Service Category: Alerts Service Description: Get a location alert parameter.GetLocationPropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property value.GetLoggedProperties
(String type) Service Category: Metadata Service Description: Get a list of logged properties for this thing.GetLongAlertParameter
(String property, String alertName, String parameterName) Service Category: Alerts Service Description: Get a long alert parameter.GetLongPropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property value.Service Category: Mashups Service Description: Get the mashups related to this thing.GetNamedProperties
(org.json.JSONObject propertyNames) Service Category: Properties Service Description: Gets the current values of the specified properties.
Gets the current values of the specified properties.GetNamedPropertyValues
(InfoTable propertyNames) Service Category: Properties Service Description: Gets the current values of the specified properties.
Gets the current values of the specified properties.GetNamedPropertyValuesVTQ
(InfoTable propertyNames) Service Category: Properties Service Description: Get the current property values for this thing as VTQ.GetNamedPropertyValuesVTQA
(InfoTable propertyNames) Service Category: Properties Service Description: Get a subset of the current property values (VTQ) and the highest alert for this thing.Service Category: Networks Service Description: Get the networks associated with a thing.GetNumberAlertParameter
(String property, String alertName, String parameterName) Service Category: Alerts Service Description: Get a numeric alert parameter.GetNumberPropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property value.Service Category: Metadata Service Description: Get a list of logged properties for this thing that are of a numeric data type.
Performs runtime access by modifier check on each property definition.getProperty
(String propertyName) boolean
getPropertyAckStatus
(String property) boolean
getPropertyAlertStatus
(String property) GetPropertyLogging
(String propertyName) Service Category: DataLogging Service Description: Get property logging status for a specific property.getPropertyQuality
(String propertyName) GetPropertyQuality
(String propertyName) Service Category: Properties Service Description: Get the quality for a specific property.org.joda.time.DateTime
getPropertyTime
(String propertyName) org.joda.time.DateTime
GetPropertyTime
(String propertyName) Service Category: Properties Service Description: Get the timestamp for a specific property.getPropertyType
(String propertyName)
Returns the base type defined in the specified property's definition.getPropertyValue
(ThingProperty property) getPropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property values for this thing.
Returns anInfoTable
containing a list of the properties belonging to this instance and their values.Service Category: Properties Service Description: Get the current property values for this thing.Service Category: Properties Service Description: Get the current property values for this thing as VTQ.Service Category: Properties Service Description: Get the current property values (VTQ) and the highest alert for this thing.Service Category: Federation Service Description: Get published thing for federation.GetRemoteEventBinding
(String eventName) Service Category: Bindings Service Description: Get the remote event binding for a event.GetRemotePropertyBinding
(String propertyName) Service Category: Bindings Service Description: Get the remote property binding for a property.GetRemoteServiceBinding
(String serviceName) Service Category: Bindings Service Description: Get the remote service binding for a service.getState()
GetStringAlertParameter
(String property, String alertName, String parameterName) Service Category: Alerts Service Description: Get a string alert parameter.GetStringPropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property value.GetThingCodePropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property value.Service Category: Service Description: Get the Visibility permissions from all the ThingGroups where this Thing is directly or indirectly a member.GetThingRelationships
(Integer maxDepth) Service Category: Relationships Service Description: Return a list of all the things referenced by this thing.Service Category: Metadata Service Description: Get thing summary information.Service Category: Metadata Service Description: Get the thing template for this thing.Service Category: DataLogging Service Description: Get the identifier for a thing.GetVec2PropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property value.GetVec3PropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property value.GetVec4PropertyValue
(String propertyName) Service Category: Properties Service Description: Get the current property value.Service Category: Alerts Service Description: Check to see if an alert is defined for a property.boolean
hasEventDefinition
(String name) boolean
boolean
boolean
boolean
hasProperty
(String propertyName)
Returnstrue
if there exists a property with the specified name.boolean
hasPropertyAndIsVisible
(String propertyName)
Returnstrue
if there exists a property with the specified name and is visible to the user.boolean
hasPropertyDefinition
(String name) boolean
hasServiceDefinition
(String name) HavePropertiesChangedSince
(org.joda.time.DateTime timestamp) Service Category: Properties Service Description: Has any property changed since a given time.boolean
implementsShape
(String thingShape) ImplementsShape
(String thingShapeName) Service Category: Metadata Service Description: Check to see if a thing implements a particular thing shape.boolean
implementsTemplate
(String thingTemplate) void
initializeEntity
(ContextType contextType) void
initializeProperty
(String propertyName, IPrimitiveType value) protected void
initializeThing
(ContextType contextType) static boolean
static boolean
isBuiltInEvent
(String name) static boolean
isBuiltInProperty
(String name) IsDerivedFromTemplate
(String thingTemplateName) Service Category: Metadata Service Description: Check to see if a thing is derived from a particular thing template.boolean
IsDynamicSubscriptionCreated
(String thingName, String eventName, String propertyName, String serviceName) Service Category: Subscriptions Service Description: Returns true if given dynamic subscription is present.boolean
boolean
Service Category: Lifecycle Service Description: Get Enabled Status.boolean
isEventRemote
(EventDefinition eventDefinition) boolean
isExternallySubscribed
(String eventName) Deprecated.UseisSubscribed(String)
instead.IsInNetwork
(String network) Service Category: Networks Service Description: Check to see if a thing is in a specific network.boolean
isLocallySubscribed
(String eventName) Deprecated.UseisSubscribed(String)
instead.boolean
isLocalProperty
(String property) boolean
isPropertyEvent
(String eventName) boolean
isPropertyRemote
(PropertyDefinition propertyDefinition) boolean
boolean
boolean
isServiceRemote
(ServiceDefinition serviceDefinition) boolean
isSubscribed
(String eventName) protected void
preprocessSetPropertyVTQ
(ThingProperty property, VTQ newValue, boolean withUpdate) processAPIServiceRequest
(String serviceName, ValueCollection params) processServiceRequest
(String serviceName, ValueCollection params) protected void
processStartNotification
(ContextType contextType) void
PurgeAllPropertyHistory
(org.joda.time.DateTime startDate, org.joda.time.DateTime endDate) Service Category: Maintenance Service Description: Purge all value stream entries for a specified date range.void
PurgePropertyHistory
(String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean immediate) Service Category: Maintenance Service Description: Purge stream entries for a specified date range.void
PurgeSelectedPropertyHistory
(org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, InfoTable propertiesToPurge) Service Category: Maintenance Service Description: Purge all value stream entries for a specified date range for a given list of properties.QueryAlertHistory
(org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query, Double maxItems) Service Category: Alerts Service Description: Query the alert history.QueryAlertSummary
(org.json.JSONObject query, Boolean onlyAcknowledged, Boolean onlyUnacknowledged, Double maxItems) Service Category: Alerts Service Description: Query the alert summary.QueryBooleanPropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryBooleanPropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.QueryDateTimePropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryDateTimePropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.QueryImagePropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryImagePropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.QueryInfoTablePropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query, Boolean flatten) QueryInfoTablePropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query, Boolean flatten) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.QueryIntegerPropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryIntegerPropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.QueryLocationPropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryLocationPropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.QueryLongPropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryLongPropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.QueryNamedPropertyHistory
(InfoTable propertyNames, Double maxItems, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, String fillOption, org.json.JSONObject query) QueryNamedPropertyHistory
(InfoTable propertyNames, Double maxItems, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryNamedPropertyHistory
(InfoTable propertyNames, Double maxItems, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, String fillOption, String returnedMetadata, org.json.JSONObject query) Service Category: Queries Service Description: Queries the value stream entries for specified logged property value along with filter and sort criteria and normalizes the data set to display result for a given time range.QueryNumberPropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryNumberPropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.QueryPropertyHistory
(Double maxItems, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, String fillOption, org.json.JSONObject query) QueryPropertyHistory
(Double maxItems, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryPropertyHistory
(Double maxItems, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, String fillOption, String returnedMetadata, org.json.JSONObject query) Service Category: Queries Service Description: Queries the value stream entries for logged property value along with filter and sort criteria and normalizes the data set to display result for a given time range.QueryStringPropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryStringPropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.QueryThingCodePropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryThingCodePropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.QueryVec2PropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryVec2PropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.QueryVec3PropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryVec3PropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.QueryVec4PropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) QueryVec4PropertyHistory
(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) Service Category: Queries Service Description: Query stream entries, along with filter and sort criteria.void
QueuePostCommitEvent
(String eventName) Service Category: Queueing Service Description: Queue events to be executed in a post commit action.void
RemoveAlert
(String property, String alertName, Boolean persistent) Service Category: Alerts Service Description: Remove an alert for a property.void
RemoveDynamicSubscription
(String thingName, String eventName, String propertyName, String serviceName) Service Category: Subscriptions Service Description: Remove a dynamic subscription.void
RemoveEventDefinition
(String name) Service Category: Metadata Service Description: Remove a event definition.void
RemoveLocalPropertyBinding
(String propertyName) Service Category: Bindings Service Description: Remove the local property binding for a property.void
Service Category: Metadata Service Description: Remove a property definition.void
RemoveRemoteEventBinding
(String eventName) Service Category: Bindings Service Description: Remove the remote event binding for a event.void
RemoveRemotePropertyBinding
(String propertyName) Service Category: Bindings Service Description: Remove the remote property binding for a property.void
RemoveRemoteServiceBinding
(String serviceName) Service Category: Bindings Service Description: Remove the remote service binding for a service.void
Service Category: Metadata Service Description: Remove a service definition.void
Service Category: Lifecycle Service Description: Restart this thing.void
SetBooleanAlertParameter
(String property, String alertName, String parameterName, Boolean value, Boolean persistent) Service Category: Alerts Service Description: Set a boolean alert parameter.void
SetDateTimeAlertParameter
(String property, String alertName, String parameterName, org.joda.time.DateTime value, Boolean persistent) Service Category: Alerts Service Description: Set a date alert parameter.void
SetDescription
(String description) Service Category: Metadata Service Description: Overwrite/set the description for an entity.void
SetIdentifier
(String identifier) Service Category: Identifier Service Description: Set the identifier for a thing.void
SetIntegerAlertParameter
(String property, String alertName, String parameterName, Integer value, Boolean persistent) Service Category: Alerts Service Description: Set a numeric alert parameter.void
SetLocalPropertyBinding
(String propertyName, String sourceThingName, String sourcePropertyName) Deprecated.As of release 8.1.0, replaced bySetLocalPropertyBinding(String, String, String, JSONObject)
void
SetLocalPropertyBinding
(String propertyName, String sourceThingName, String sourcePropertyName, org.json.JSONObject aspects) Service Category: Bindings Service Description: Set the property binding for a property.void
SetLocationAlertParameter
(String property, String alertName, String parameterName, Location value, Boolean persistent) Service Category: Alerts Service Description: Set a location alert parameter.void
SetNumberAlertParameter
(String property, String alertName, String parameterName, Double value, Boolean persistent) Service Category: Alerts Service Description: Set a numeric alert parameter.void
SetPropertyLogging
(String propertyName, Boolean enabled) Service Category: DataLogging Service Description: Set property logging status for a specific property.void
setPropertyValue
(String propertyName, IPrimitiveType newValue) void
SetPropertyValues
(InfoTable values) Service Category: Properties Service Description: Get a subset of the current property values for this thing.setPropertyVTQ
(String propertyName, VTQ newValue, boolean withUpdate) setPropertyVTQ
(String propertyName, VTQ newValue, boolean deferNotifications, boolean bypassReadOnly, boolean bypassHooksAndBindings) void
SetPublished
(Boolean publish) Service Category: Federation Service Description: Set this as a published thing for federation.void
SetRemoteEventBinding
(String eventName, String sourceEventName) Service Category: Bindings Service Description: Set the remote event binding for a event.void
SetRemotePropertyBinding
(String propertyName, String sourcePropertyName, Integer timeout, String pushType, Double pushThreshold) Deprecated.As of release 8.0.0, replaced bySetRemotePropertyBinding(String, String, Integer, String, Double, JSONObject, Integer, String)
void
SetRemotePropertyBinding
(String propertyName, String sourcePropertyName, Integer timeout, String pushType, Double pushThreshold, org.json.JSONObject aspects, Integer cacheTime, String foldType) Service Category: Bindings Service Description: Set the remote property binding for a property.void
SetRemoteServiceBinding
(String serviceName, String sourceServiceName, Integer timeout) Service Category: Bindings Service Description: Set the remote service binding for a service.void
SetStringAlertParameter
(String property, String alertName, String parameterName, String value, Boolean persistent) Service Category: Alerts Service Description: Set a string alert parameter.void
SetTags
(TagCollection tags) Service Category: Metadata Service Description: Overwrite/set the tags for an entity.void
setThingTemplateName
(String value) void
SetUnitsForNumericPropertyDefinition
(String propertyName, String units) Service Category: Metadata Service Description: Set the additional information for units for a specific Long, Integer, or Number property.void
SetValueStream
(String name) Service Category: DataLogging Service Description: Set the value stream for a thing.protected void
startThing
(ContextType contextType) protected void
stopThing
(ContextType contextType) void
UpdatePropertyValues
(InfoTable values) Service Category: Properties Service Description: Write property values for a thing.void
UpdatePropertyValuesBatched
(InfoTable batches) Service Category: Properties Service Description: Write property values for a thing, processing change events in batches by timestamp.void
validateConfiguration
(ImportedEntityCollection importedEntities) void
WritePropertiesToStream
(String name, TagCollection tags) Service Category: Data Service Description: Store properties of this thing to a stream.Methods inherited from class com.thingworx.entities.RootEntity
AddConfigurationTableDefinition, AddConfigurationTableDefinition, addDesignTimePermission, AddDesignTimePermission, addRunTimePermission, AddRunTimePermission, addVisibilityPermission, AddVisibilityPermission, CheckDesignTimePermission, CheckDesignTimePermissionForGroup, CheckDesignTimePermissionForUser, CheckPermission, CheckPermissionForGroup, CheckPermissionForUser, cleanupEntity, DeleteAllConfigurationTableRows, DeleteConfigurationTable, DeleteConfigurationTableRows, DeleteConfigurationTableRows, deleteDesignTimePermission, DeleteDesignTimePermission, deleteRunTimePermission, DeleteRunTimePermission, deleteVisibilityPermission, DeleteVisibilityPermission, getAspects, getAvatarContent, GetAvatarURL, GetConfigurationChangeHistory, getConfigurationSetting, getConfigurationTable, GetConfigurationTable, GetConfigurationTableDefinition, GetConfigurationTableRow, GetConfigurationTables, GetDescription, getDesignTimePermissions, GetDesignTimePermissions, GetDesignTimePermissionsAsJSON, getDocumentationContent, getEntityTypeAsString, GetEventDefinition, GetEventDefinitions, GetIncomingDependencies, GetIncomingDependenciesAsNetwork, GetInstanceMetadataAsJSON, GetInstanceMetadataWithPermissionsAsJSON, GetLastModifiedDate, GetMetadata, GetMetadataAsJSON, GetMetadataWithPermissionsAsJSON, GetOutgoingDependencies, GetOutgoingDependenciesAsNetwork, getOwner, GetOwner, GetPermissionsForCurrentUser, GetPermissionsForGroup, GetPermissionsForUser, GetProjectName, GetPropertyDefinition, GetPropertyDefinitions, getRunTimePermissions, GetRunTimePermissions, GetRunTimePermissionsAsJSON, GetServiceDefinition, GetServiceDefinitions, getStringConfigurationSetting, getStringConfigurationSettingWithDefault, GetSummaryInformation, getTags, GetTags, GetTagsAsInfoTable, getVisibilityPermissions, GetVisibilityPermissions, GetVisibilityPermissionsAsJSON, HasIncomingDependencies, HasOutgoingDependencies, isEditable, isEditableExtensionObject, isEditableSystemObject, isExtensionObject, IsMultiRowTable, isOwner, isSystemObject, isThemeObject, isVisible, isVisible, ListDeprecatedUsage, persistDesignTimePermissions, persistRunTimePermissions, persistVisibilityPermissions, preInitializeEntity, RemoveTags, SaveConfigurationTables, SetAvatar, setConfigurationSetting, SetConfigurationTable, SetConfigurationTableRows, setDesignTimePermissions, SetDesignTimePermissionsAsJSON, setDocumentationContent, setExtensionObject, SetHomeMashup, setLastModifiedDate, SetMultiRowConfigurationTable, setOwner, SetOwner, SetProjectName, setRunTimePermissions, SetRunTimePermissionsAsJSON, setStringConfigurationSetting, setVisibilityPermissions, SetVisibilityPermissionsAsJSON, toJSON, toJSONDefinition, UpdateProjectDependencies
Methods inherited from class com.thingworx.persistence.common.PersistableNamedObject
getID, hasID, isTransient
Methods inherited from class com.thingworx.types.NamedObject
getDescription, getName, setDescription, setName, toValueCollection
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.thingworx.types.INamedObject
getDescription
Methods inherited from interface com.thingworx.entities.interfaces.IPersistable
getID, hasID
Methods inherited from interface com.thingworx.security.permissions.ISecurable
getID, getName
Methods inherited from interface com.thingworx.entities.interfaces.IShapeProvider
getName
Methods inherited from interface com.thingworx.accesscontrol.ISupportsAccessModifier
getAccessModifier, getAccessModifierScope, getExemptList, hasAccessModifier, isInternalAccess, isPrivateAccess, isRestrictedAccess
Methods inherited from interface com.thingworx.deprecation.ISupportsDeprecation
getDeprecated, isDeprecated, isDeprecatedBefore, since
-
Field Details
-
DATASHAPE_INCOMING_LOCAL_PROPERTY_BINDING
- See Also:
-
ENTITYLIST_SHAPE
- See Also:
-
GENERIC_THING_TEMPLATE
- See Also:
-
TYPE_THING
- See Also:
-
DEFAULT_SETTINGS_TABLE
- See Also:
-
BUILT_IN_PROPERTY_DEFINITIONS
-
PROPERTY_EVENTS
-
NON_PROPERTY_BASED_EVENTS
-
_logger
public static org.slf4j.Logger _logger
-
-
Constructor Details
-
Thing
-
-
Method Details
-
getEntityType
@ThingworxExtensionApiMethod(since={6,6}) public RelationshipTypes.ThingworxRelationshipTypes getEntityType()Description copied from class:RootEntity
Returns the type of this entity.
- Specified by:
getEntityType
in interfaceIShapeProvider
- Specified by:
getEntityType
in classRootEntity
- Returns:
- the entity type
-
initializeEntity
@ThingworxExtensionApiMethod(since={9,0}, canOverride=true, requiresSuper=true) public void initializeEntity(ContextType contextType) throws Exception Description copied from class:RootEntity
Initializes the internal state of the entity. This method may be called more than once on the same entity during initialization.
All metadata, including aspects and configuration tables, are available at this point in the lifecycle.
- Overrides:
initializeEntity
in classRootEntity
- Parameters:
contextType
- the patch operation- Throws:
Exception
- If an error occurs
-
getDependencies
@ThingworxExtensionApiMethod(since={6,6}, canOverride=true, requiresSuper=true) public EntityReferenceTypeMap getDependencies()
Returns a map containing references to all entities that the Thing is dependent on.
- Returns:
- a map of up-stream dependencies
-
isRunning
Returns
true
when the thing has completed starting up and has not yet been cleaned up.- Returns:
true
if the thing is active and has not yet been stopped
-
getState
Returns the current state of the thing.
- Returns:
- the thing's current state
-
dispose
@ThingworxExtensionApiMethod(since={6,6}, canOverride=true, requiresSuper=true) public void dispose() throws ExceptionDescription copied from class:RootEntity
Removes any remaining references of this entity and disposes any resources that were not cleaned up earlier in the lifecycle. This method is only invoked when the entity is in the process of deletion.
- Overrides:
dispose
in classRootEntity
- Throws:
Exception
- If an error occurs
This method handles cleanup for deletion, only cleanup that should be done during actual deletion should be done here.
-
startThing
@ThingworxExtensionApiMethod(since={9,0}, canOverride=true) protected void startThing(ContextType contextType) throws Exception
A startup hook for subclasses of
Thing
.- Throws:
Exception
- if an error occurs during thing startup
-
stopThing
@ThingworxExtensionApiMethod(since={9,0}, canOverride=true) protected void stopThing(ContextType contextType) throws Exception
A shutdown hook for subclasses of
Thing
.- Parameters:
contextType
-- Throws:
Exception
-
initializeThing
@ThingworxExtensionApiMethod(since={9,0}, canOverride=true) protected void initializeThing(ContextType contextType) throws Exception
An initialization hook for subclasses of
Thing
. Some resources ofThing
may not be available at this point in the lifecycle.- Throws:
Exception
- if an error occurs during thing initialization
-
cleanupThing
@ThingworxExtensionApiMethod(since={9,0}, canOverride=true) protected void cleanupThing(ContextType contextType) throws Exception
A teardown hook with model synchronization patch operation for subclasses of
Thing
. This method will be called whenever the thing is deactivated.This method is not invoked if the thing has been disabled.
- Parameters:
contextType
- model synchronization patch operation- Throws:
Exception
- if an error occurs during thing teardown
-
preprocessSetPropertyVTQ
@ThingworxExtensionApiMethod(since={6,6}, canOverride=true) protected void preprocessSetPropertyVTQ(ThingProperty property, VTQ newValue, boolean withUpdate) throws Exception
A property validation hook for subclasses of
Thing
. This method will execute whenever the value of a property is modified.- Parameters:
property
- the property being modifiednewValue
- the new value being assigned to the propertywithUpdate
- has no current function- Throws:
Exception
- if property validation fails against the new value
-
processStartNotification
@ThingworxExtensionApiMethod(since={9,0}, canOverride=true) protected void processStartNotification(ContextType contextType)
A post-startup hook for subclasses of
Thing
. This method executes when the thing has fully activated and all resources made available.- Parameters:
contextType
- the patch operation
-
getInstanceShape
Returns the thing shape describing the current thing. The thing shape instance contains only the resources that belong exclusively to this thing (i.e., not inherited from a thing template or shape).
The thing shape instance is not fully initialized until the "start" step of the lifecycle.
- Specified by:
getInstanceShape
in interfaceIShapeProvider
- Returns:
- the thing shape describing the thing itself
-
getThingTemplateName
-
setThingTemplateName
-
isPublished
-
getAllImplementedThingShapes
@ThingworxExtensionApiMethod(since={6,6}) public EntityReferenceCollection getAllImplementedThingShapes()
Returns all thing shapes implemented by this thing. This includes thing shapes applied via inheritance.
This method may be used at the "initialize thing" step of the lifecycle or later.
- Returns:
- a collection containing references to all implemented thing shapes
-
implementsShape
Returns
true
if the specified thing shape is implemented by this thing. This includes thing shapes applied via inheritance.This method may be used at the "initialize thing" step of the lifecycle or later.
- Parameters:
thingShape
- the name of the thing shape to test for- Returns:
true
if the thing implements the specified shape
-
getAllImplementedThingTemplates
@ThingworxExtensionApiMethod(since={6,6}) public EntityReferenceCollection getAllImplementedThingTemplates()
Returns all thing templates inherited by this thing.
This method may be used at the "initialize thing" step of the lifecycle or later.
- Returns:
- a collection containing references to all inherited thing templates
-
implementsTemplate
Returns
true
if the specified thing template is a member of of the thing's inheritance chain.This method may be used at the "initialize thing" step of the lifecycle or later.
- Parameters:
thingTemplate
- the name of the thing template to test for- Returns:
true
if the thing inherits the specified template
-
getImplementedThingTemplates
Returns a set containing the names of all thing templates the thing inherits from.
- Returns:
- a set containing the names of all thing templates this thing inherits from
-
isSubscribed
Returns
true
if the specified event has been subscribed to.This method may be used at the "notification" step of the lifecycle or later.
- Parameters:
eventName
- the name of the event- Returns:
true
if any subscriptions exist
-
isLocallySubscribed
@Deprecated @ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={7,4}) public boolean isLocallySubscribed(String eventName) Deprecated.UseisSubscribed(String)
instead.
Returns
true
if the specified event has been subscribed to within the thing.This method may be used at the "notification" step of the lifecycle or later.
- Parameters:
eventName
- the name of the event- Returns:
true
if any subscriptions exist within this thing
-
isExternallySubscribed
@Deprecated @ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={7,4}) public boolean isExternallySubscribed(String eventName) Deprecated.UseisSubscribed(String)
instead.
Returns
true
if the specified event has been subscribed to by an external entity.This method may be used at the "notification" step of the lifecycle or later.
- Parameters:
eventName
- the name of the event- Returns:
true
if any subscriptions exist on an external entity
-
getEffectiveIdentifier
-
getIdentifier
-
getValueStreamName
Returns the name of the value stream assigned to this thing, if any.
It is recommended to use the method
getEffectiveValueStreamName()
instead, as it will account for value streams attached to inherited thing templates.- Returns:
- the name of the assigned value stream, or an empty string if none has been assigned
-
isBuiltInProperty
-
isBuiltInEvent
-
isPropertyEvent
Returns
true
if the named event exists and binds to a property.- Parameters:
eventName
- The name of the event- Returns:
true
if the event binds to a property
-
hasPropertyDefinition
-
hasServiceDefinition
-
hasEventDefinition
-
hasLocalPropertyDefinition
-
hasLocalServiceDefinition
-
hasLocalEventDefinition
-
getEffectivePropertyDefinition
@ThingworxExtensionApiMethod(since={6,6}) public PropertyDefinition getEffectivePropertyDefinition(String name)
Returns the named property definition belonging to the current thing.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Specified by:
getEffectivePropertyDefinition
in interfaceIAlertProvider
- Parameters:
name
- The name of the property definition.- Returns:
- the property definition if it exists, otherwise
null
-
getInstancePropertyDefinitionIfVisible
@ThingworxExtensionApiMethod(since={9,0}) public PropertyDefinition getInstancePropertyDefinitionIfVisible(String name) throws Exception Description copied from interface:IPropertyProvider
Returns the specified property definition for this instance if visible.- Specified by:
getInstancePropertyDefinitionIfVisible
in interfaceIPropertyProvider
- Parameters:
name
- The name of the property definition.- Returns:
- the property definition if it exists, otherwise
null
- Throws:
Exception
- If an error occurs
Returns the named property definition. The property definition may belong to the thing itself or from an inherited template or implemented shape.
This method may be used at the "thing initialization" step of the lifecycle or later.
-
getInstancePropertyDefinition
@ThingworxExtensionApiMethod(since={6,6}) public PropertyDefinition getInstancePropertyDefinition(String name)
Returns the named property definition. The property definition may belong to the thing itself or from an inherited template or implemented shape.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Specified by:
getInstancePropertyDefinition
in interfaceIPropertyProvider
- Parameters:
name
- The name of the property definition.- Returns:
- the property definition if it exists, otherwise
null
-
getInstancePropertyDefinitions
@ThingworxExtensionApiMethod(since={6,6}) public PropertyDefinitionCollection getInstancePropertyDefinitions()
Returns a collection containing property definitions for all properties that are applicable to this thing.
- Specified by:
getInstancePropertyDefinitions
in interfaceIPropertyProvider
- Returns:
- a collection of property definitions
- See Also:
-
getInstanceServiceDefinition
@ThingworxExtensionApiMethod(since={6,6}) public ServiceDefinition getInstanceServiceDefinition(String name)
Returns the named service definition. The service definition may belong to the thing itself or from an inherited template or implemented shape.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Specified by:
getInstanceServiceDefinition
in interfaceIServiceProvider
- Parameters:
name
- The name of the service definition.- Returns:
- the service definition if it exists, otherwise
null
-
getEffectiveServiceDefinition
@ThingworxExtensionApiMethod(since={6,6}) public ServiceDefinition getEffectiveServiceDefinition(String serviceName)
Returns the named service definition belonging to the current thing.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Specified by:
getEffectiveServiceDefinition
in interfaceIServiceMetadataProvider
- Parameters:
serviceName
- The name of the service definition.- Returns:
- the service definition if it exists, otherwise
null
-
getEffectiveEventDefinition
@ThingworxExtensionApiMethod(since={6,6}) public EventDefinition getEffectiveEventDefinition(String name)
Returns the named event definition belonging to the current thing.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Specified by:
getEffectiveEventDefinition
in interfaceIEventMetadataProvider
- Parameters:
name
- The name of the event definition.- Returns:
- the event definition if it exists, otherwise
null
-
getInstanceEventDefinition
@ThingworxExtensionApiMethod(since={6,6}) public EventDefinition getInstanceEventDefinition(String name)
Returns the named event definition. The event definition may belong to the thing itself or from an inherited template or implemented shape.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Specified by:
getInstanceEventDefinition
in interfaceIEventProvider
- Parameters:
name
- The name of the property definition.- Returns:
- the event definition if it exists, otherwise
null
-
getInstanceServiceDefinitions
@ThingworxExtensionApiMethod(since={6,6}) public ServiceDefinitionCollection getInstanceServiceDefinitions()
Returns a collection containing service definitions for all services that are applicable to this thing.
- Specified by:
getInstanceServiceDefinitions
in interfaceIServiceProvider
- Returns:
- a collection of service definitions
- See Also:
-
getInstancePublicServiceDefinitions
@ThingworxExtensionApiMethod(since={6,6}) public ServiceDefinitionCollection getInstancePublicServiceDefinitions()
Returns a collection containing service definitions for all services that are applicable to this thing and are publicly exposed.
- Specified by:
getInstancePublicServiceDefinitions
in interfaceIServiceProvider
- Returns:
- a collection of public service definitions
- See Also:
-
getInstanceEventDefinitions
@ThingworxExtensionApiMethod(since={6,6}) public EventDefinitionCollection getInstanceEventDefinitions()
Returns a collection containing event definitions for all events that are applicable to this thing.
- Specified by:
getInstanceEventDefinitions
in interfaceIEventProvider
- Returns:
- a collection of event definitions
- See Also:
-
getInstanceSubscriptions
@Deprecated @ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={9,5}) public SubscriptionCollection getInstanceSubscriptions()Deprecated.UsegetInstanceMultiEventSubscriptions()
instead.Returns a collection containing all subscriptions that are applicable to this thing including it's inherited subscriptions. Supports only single events subscriptions, otherwise RuntimeException will be thrown.
This method may be used at the "start" step of the lifecycle or later.
- Returns:
- a collection of subscriptions
- See Also:
-
getInstanceMultiEventSubscriptions
@ThingworxExtensionApiMethod(since={9,5}) public MultiEventSubscriptionCollection getInstanceMultiEventSubscriptions()
Returns a collection containing all subscriptions that are applicable to this thing including it's inherited subscriptions.
- Returns:
- a collection of multi events subscriptions
- See Also:
-
isPropertyRemote
@ThingworxExtensionApiMethod(since={6,6}) public boolean isPropertyRemote(PropertyDefinition propertyDefinition)
Returns
true
if the property definition provided defines a remote property, or if the property is registered as remote according to the current thing.This method may be used at the "start" step of the lifecycle or later.
- Parameters:
propertyDefinition
- the definition of the property to test against- Returns:
true
if the definition provided defines a remote property or if the property is remote according to the current thing
-
isServiceRemote
@ThingworxExtensionApiMethod(since={6,6}) public boolean isServiceRemote(ServiceDefinition serviceDefinition)
Returns
true
if the service definition provided defines a remote service, or if the service is registered as remote according to the current thing.This method may be used at the "start" step of the lifecycle or later.
- Parameters:
serviceDefinition
- the definition of the service to test against- Returns:
true
if the definition provided defines a remote service or if the service is remote according to the current thing
-
isEventRemote
@ThingworxExtensionApiMethod(since={6,6}) public boolean isEventRemote(EventDefinition eventDefinition)
Returns
true
if the event definition provided defines a remote event, or if the event is registered as remote according to the current thing.This method may be used at the "start" step of the lifecycle or later.
- Parameters:
eventDefinition
- the definition of the event to test against- Returns:
true
if the definition provided defines a remote event or if the event is remote according to the current thing
-
getEffectiveLocalPropertyBindings
@ThingworxExtensionApiMethod(since={6,6}) public LocalPropertyBindingCollection getEffectiveLocalPropertyBindings() -
getEffectiveRemotePropertyBindings
@ThingworxExtensionApiMethod(since={6,6}) public RemotePropertyBindingCollection getEffectiveRemotePropertyBindings() -
getEffectiveRemoteEventBindings
@ThingworxExtensionApiMethod(since={6,6}) public RemoteEventBindingCollection getEffectiveRemoteEventBindings() -
getEffectiveRemoteServiceBindings
@ThingworxExtensionApiMethod(since={6,6}) public RemoteServiceBindingCollection getEffectiveRemoteServiceBindings() -
getEffectiveValueStreamName
Returns the name of the value stream effectively assigned to this thing, taking into account the thing template hierarchy.
- Returns:
- the name of the value stream associated with this thing
-
validateConfiguration
@ThingworxExtensionApiMethod(since={6,6}, canOverride=true, requiresSuper=true) public void validateConfiguration(ImportedEntityCollection importedEntities) throws Exception
Validates the configuration of the thing during the import process. This method is called whenever a thing is created or modified via the REST APIs. During the validation step, there may be other associated entities (including thing shapes and templates) that are being imported. These can be accessed via the
importedEntities
collection if needed.Note that some resources belonging to the thing or other associated entities may not be available during this step in the lifecycle.
It is required for all subclasses of
Thing
to callsuper.validateConfiguration(importedEntities)
if they override this method.- Overrides:
validateConfiguration
in classRootEntity
- Parameters:
importedEntities
- - a typed collection of entities currently being imported- Throws:
Exception
- if the thing is invalid
-
getThingTemplate
Returns the base thing template assigned to this thing.
- Returns:
- the base thing template
-
isEnabled
Returns
true
if the current thing is enabled. An enabled thing can be started and federated.- Returns:
true
if the current thing is enabled
-
getProperties
Performs runtime access by modifier check on each property definition.Returns a collection containing the property instances belonging to this thing and accessible to caller .
This method may be used at the "thing initialization" step of the lifecycle or later.
- Returns:
- a collection of property instances
- See Also:
-
addProperty
@ThingworxExtensionApiMethod(since={6,6}) public ThingProperty addProperty(PropertyDefinition propertyDefinition) throws Exception
Adds the provided property definition to this thing. An instance of the property will automatically be generated and assigned the default value.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Parameters:
propertyDefinition
- the property definition to apply to this thing- Returns:
- the generated property instance
- Throws:
Exception
- if an error occurs
-
isLocalProperty
Returns
true
if the specified property is defined by this thing.- Parameters:
property
- the name of the property- Returns:
true
if the named property is a local member of this thing
-
getProperty
@ThingworxExtensionApiMethod(since={6,6}) public ThingProperty getProperty(String propertyName) throws Exception
Returns the named property instance. This method performs two runtime checks:
- A run-time authorization check against the current security context.
- Access by modifier check on the property against the caller context.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Parameters:
propertyName
- the name of the property to retrieve- Returns:
- the associated property instance
- Throws:
Exception
- if an error occurs or authorization/runtime access is denied
-
getPropertyValue
@ThingworxExtensionApiMethod(since={6,6}) public IPrimitiveType getPropertyValue(String propertyName) throws Exception
Returns the current value assigned to the named property. This method performs a run-time authorization check against the current security context.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Specified by:
getPropertyValue
in interfaceIPropertyProvider
- Parameters:
propertyName
- the name of the property- Returns:
- the value of the property
- Throws:
Exception
- if an error occurs or authorization is denied
-
getPropertyValue
@ThingworxExtensionApiMethod(since={6,6}) public IPrimitiveType getPropertyValue(ThingProperty property) throws Exception
Returns the current value assigned to the provided property instance. This method performs a run-time authorization check against the current security context.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Parameters:
property
- the property- Returns:
- the value of the property
- Throws:
Exception
- if an error occurs or authorization is denied
-
getPropertyTime
@ThingworxExtensionApiMethod(since={6,6}) public org.joda.time.DateTime getPropertyTime(String propertyName)
Returns the modified time assigned to the named property. This method performs a run-time authorization check against the current security context.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Parameters:
propertyName
- the name of the property- Returns:
- the time the property was last modified, or the epoch if an error occurred
-
getPropertyQuality
@ThingworxExtensionApiMethod(since={6,6}) public QualityStatus getPropertyQuality(String propertyName)
Returns the current quality status assigned to the provided property instance. This method performs a run-time authorization check against the current security context.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Parameters:
propertyName
- the name of the property- Returns:
- the current quality status of the property, or
QualityStatus#UNKNOWN
if an error occurred
-
hasProperty
Description copied from interface:IPropertyProvider
Returnstrue
if there exists a property with the specified name. Property names are case-sensitive.- Specified by:
hasProperty
in interfaceIPropertyProvider
- Parameters:
propertyName
- the property name to check- Returns:
true
if the specified property exists
-
hasPropertyAndIsVisible
@ThingworxExtensionApiMethod(since={9,0}) public boolean hasPropertyAndIsVisible(String propertyName) throws Exception Description copied from interface:IPropertyProvider
Returnstrue
if there exists a property with the specified name and is visible to the user. Property names are case-sensitive.- Specified by:
hasPropertyAndIsVisible
in interfaceIPropertyProvider
- Parameters:
propertyName
- the property name to check- Returns:
true
if the specified property exists and is visible- Throws:
Exception
- If an error occurs
-
getPropertyType
Description copied from interface:IPropertyProvider
Returns the base type defined in the specified property's definition.- Specified by:
getPropertyType
in interfaceIPropertyProvider
- Parameters:
propertyName
- the name of the property- Returns:
- the
BaseTypes
entry corresponding to the property type
-
checkDemandRead
@ThingworxExtensionApiMethod(since={6,6}, canOverride=true) public void checkDemandRead(ThingProperty property) throws Exception
A property read hook for subclasses of
Thing
. This method may be used to update the property on read if it uses a backing cache or otherwise transform the property prior to read.- Parameters:
property
- the property that is being read- Throws:
Exception
- if the property cannot be read, or if an issue occurs
-
initializeProperty
@ThingworxExtensionApiMethod(since={6,6}) public void initializeProperty(String propertyName, IPrimitiveType value) throws Exception
Initializes the named property to the specified value. This method is intended for use by subclasses of
Thing
during the "thing initialization" step of the lifecycle to assign an initial value to a property managed by the subclass.- Parameters:
propertyName
- the name of the propertyvalue
- the value to assign to the property- Throws:
Exception
- If an error occurs
-
setPropertyValue
@ThingworxExtensionApiMethod(since={6,6}) public void setPropertyValue(String propertyName, IPrimitiveType newValue) throws Exception - Specified by:
setPropertyValue
in interfaceIPropertyProvider
- Parameters:
propertyName
- the name of the property that is being modifiednewValue
- the value to assign to the property- Throws:
Exception
- If an error occurs
Assigns the provided value to the specified property.
This method may be used at the "start" step of the lifecycle or later.
Exception
- if either of the parameters are null, the user is unauthorized, or an error occurs when attempting to modify the property
-
setPropertyVTQ
@ThingworxExtensionApiMethod(since={6,6}) public QueuedEvent setPropertyVTQ(String propertyName, VTQ newValue, boolean withUpdate) throws Exception - Throws:
Exception
- If an error occurs
-
setPropertyVTQ
@ThingworxExtensionApiMethod(since={6,6}) public QueuedEvent setPropertyVTQ(String propertyName, VTQ newValue, boolean deferNotifications, boolean bypassReadOnly, boolean bypassHooksAndBindings) throws Exception - Throws:
Exception
- If an error occurs
-
getPropertyValues
@ThingworxExtensionApiMethod(since={6,6}) public ValueCollection getPropertyValues() throws Exception
Returns a collection of mappings of property names and the current values of the properties. This method performs two checks:
- A runtime authorization check on each property to be read to ensure the current security context is authorized.
- A runtime access modifier check on each propoerty to make sure that the caller context has access to the property.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Returns:
- a map of property names and their current values
- Throws:
Exception
- if an error occurred while reading a property, excepting an authorization failure
-
getPropertyValuesAsInfoTable
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable getPropertyValuesAsInfoTable() throws ExceptionDescription copied from interface:IPropertyProvider
Returns anInfoTable
containing a list of the properties belonging to this instance and their values.- Specified by:
getPropertyValuesAsInfoTable
in interfaceIPropertyProvider
- Returns:
- an
InfoTable
of property names and their associated values - Throws:
Exception
- If an error occurs
-
getAlertConfigurations
@ThingworxExtensionApiMethod(since={6,6}) public AlertConfigurationCollection getAlertConfigurations()
Returns a collection of alert configurations belonging to the local properties of this thing.
- Specified by:
getAlertConfigurations
in interfaceIAlertProvider
- Returns:
- a collection of alert configurations
-
getEffectiveAlertConfiguration
@ThingworxExtensionApiMethod(since={6,6}) public AlertConfigurationCollection getEffectiveAlertConfiguration()
Returns a collection of alert configurations associated to any of the properties applicable to this thing.
This method may be used at the "thing initialization" step of the lifecycle or later.
- Specified by:
getEffectiveAlertConfiguration
in interfaceIAlertProvider
- Returns:
- a collection of alert configurations
-
acknowledgeAlertByPropertyAndName
@ThingworxExtensionApiMethod(since={7,3}) public void acknowledgeAlertByPropertyAndName(String propertyName, String alertName, String message) throws Exception - Throws:
Exception
- If an error occurs
-
acknowledgeAlertByProperty
@ThingworxExtensionApiMethod(since={6,6}) public void acknowledgeAlertByProperty(String propertyName, String message) throws Exception - Throws:
Exception
- If an error occurs
-
acknowledgeAllAlerts
-
getAlertsForProperty
@ThingworxExtensionApiMethod(since={6,6}) public AlertList getAlertsForProperty(String propertyName)
Returns Effective Alerts including local and inherited from ancestors.- Parameters:
propertyName
- name of the property on which the alert's defined- Returns:
- a list of alerts defined on the given property
-
getAlerts
Returns a list of effective alerts on the properties associated with this thing.
This method may be used at the "start" step of the lifecycle or later.
- Returns:
- a collection of alerts
-
getPropertyAlertStatus
-
getPropertyAckStatus
-
GetValueStream
- Service Category:
- DataLogging
- Service Description:
- Get the identifier for a thing.
- Returns:
- name Value Stream Name - THINGNAME
-
SetValueStream
- Service Category:
- DataLogging
- Service Description:
- Set the value stream for a thing.
- Parameters:
name
- Value stream name - THINGNAME- Throws:
Exception
- If an error occurs
-
DisableThing
- Service Category:
- Lifecycle
- Service Description:
- Disable this thing.
- Throws:
Exception
- If an error occurs
-
EnableThing
- Service Category:
- Lifecycle
- Service Description:
- Enable this thing.
- Throws:
Exception
- If an error occurs
-
IsEnabled
- Service Category:
- Lifecycle
- Service Description:
- Get Enabled Status.
- Returns:
- enabled Enabled status - BOOLEAN
- Throws:
Exception
- If an error occurs
-
RestartThing
- Service Category:
- Lifecycle
- Service Description:
- Restart this thing.
- Throws:
Exception
- If an error occurs
-
GetIdentifier
- Service Category:
- Identifier
- Service Description:
- Get the identifier for a thing.
- Returns:
- identifier Identifier - STRING
-
SetIdentifier
@ThingworxExtensionApiMethod(since={6,6}) public void SetIdentifier(String identifier) throws Exception - Service Category:
- Identifier
- Service Description:
- Set the identifier for a thing.
- Parameters:
identifier
- Thing identifier for remote things - STRING- Throws:
Exception
- If an error occurs
-
GetLocalPropertyBinding
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetLocalPropertyBinding(String propertyName) throws Exception - Service Category:
- Bindings
- Service Description:
- Get the property binding for a property.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property binding - INFOTABLE - Aspects {dataShape:LocalPropertyBinding}
- Throws:
Exception
- If an error occurs
-
GetEffectiveLocalPropertyBinding
@ThingworxExtensionApiMethod(since={7,3}) public InfoTable GetEffectiveLocalPropertyBinding(String propertyName) throws Exception - Service Category:
- Bindings
- Service Description:
- Get the effective local property binding for a property.
Get the effective (inherited and local) property binding for a property- Parameters:
propertyName
- : name of property to get the local binding- Returns:
- InfoTable of local property bindings consists of property name, name of thing(sourceThingName) and name of property(sourceName) the property is locally bound to.
- Throws:
Exception
-
GetEffectiveLocalPropertyBindings
@ThingworxExtensionApiMethod(since={7,3}) public InfoTable GetEffectiveLocalPropertyBindings() throws Exception- Service Category:
- Bindings
- Service Description:
- Get the effective local property bindings.
Get all effective (inherited and local) property bindings for this thing- Returns:
- InfoTable of local property bindings consists of property name, name of thing(sourceThingName) and name of property(sourceName) the property is locally bound to.
- Throws:
Exception
-
GetIncomingLocalPropertyBindings
@ThingworxExtensionApiMethod(since={8,0}) public InfoTable GetIncomingLocalPropertyBindings() throws Exception- Service Category:
- Bindings
- Service Description:
- Get all things and their properties that have local bindings on this thing.
Get all things and their properties that have local bindings on this thing- Returns:
- Infotable of propertyName, bound thing's property name, bound thing's name
- Throws:
Exception
-
GetIncomingLocalPropertyBinding
@ThingworxExtensionApiMethod(since={8,0}) public InfoTable GetIncomingLocalPropertyBinding(String propertyName) throws Exception - Service Category:
- Bindings
- Service Description:
- Get incoming local bindings to this thing for the given property.
Get incoming local bindings to this thing for the given property- Parameters:
propertyName
- : name of property for which incoming bindings are to be fetched- Returns:
- Infotable of propertyName, bound thing's property name, bound thing's name
- Throws:
Exception
-
RemoveLocalPropertyBinding
@ThingworxExtensionApiMethod(since={6,6}) public void RemoveLocalPropertyBinding(String propertyName) throws Exception - Service Category:
- Bindings
- Service Description:
- Remove the local property binding for a property.
- Parameters:
propertyName
- Property name - STRING- Throws:
Exception
- If an error occurs
-
SetLocalPropertyBinding
@ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={8,1,0}) @Deprecated public void SetLocalPropertyBinding(String propertyName, String sourceThingName, String sourcePropertyName) throws Exception Deprecated.As of release 8.1.0, replaced bySetLocalPropertyBinding(String, String, String, JSONObject)
- Throws:
Exception
- If an error occurs
-
SetLocalPropertyBinding
@ThingworxExtensionApiMethod(since={8,1,0}) public void SetLocalPropertyBinding(String propertyName, String sourceThingName, String sourcePropertyName, org.json.JSONObject aspects) throws Exception - Service Category:
- Bindings
- Service Description:
- Set the property binding for a property.
- Parameters:
propertyName
- Property name - STRINGsourceThingName
- Thing name to bind to - STRINGsourcePropertyName
- Source property name - STRINGaspects
- Aspects for the local binding - JSON- Throws:
Exception
- If an error occurs
-
GetRemotePropertyBinding
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetRemotePropertyBinding(String propertyName) throws Exception - Service Category:
- Bindings
- Service Description:
- Get the remote property binding for a property.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property binding - INFOTABLE - Aspects {dataShape:RemotePropertyBinding}
- Throws:
Exception
- If an error occurs
-
RemoveRemotePropertyBinding
@ThingworxExtensionApiMethod(since={6,6}) public void RemoveRemotePropertyBinding(String propertyName) throws Exception - Service Category:
- Bindings
- Service Description:
- Remove the remote property binding for a property.
- Parameters:
propertyName
- Property name - STRING- Throws:
Exception
- If an error occurs
-
SetRemotePropertyBinding
@ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={8,0,0}) @Deprecated public void SetRemotePropertyBinding(String propertyName, String sourcePropertyName, Integer timeout, String pushType, Double pushThreshold) throws Exception Deprecated.As of release 8.0.0, replaced bySetRemotePropertyBinding(String, String, Integer, String, Double, JSONObject, Integer, String)
- Throws:
Exception
- If an error occurs
-
SetRemotePropertyBinding
@ThingworxExtensionApiMethod(since={8,0}) public void SetRemotePropertyBinding(String propertyName, String sourcePropertyName, Integer timeout, String pushType, Double pushThreshold, org.json.JSONObject aspects, Integer cacheTime, String foldType) throws Exception - Service Category:
- Bindings
- Service Description:
- Set the remote property binding for a property.
- Parameters:
propertyName
- Property name - STRINGsourcePropertyName
- Source property name - STRINGtimeout
- Request timeout - INTEGERpushType
- Push type - STRINGpushThreshold
- Push threshold - NUMBERaspects
- Aspects for the remote binding - JSONcacheTime
- Property's cache time value at the server in milliseconds - INTEGERfoldType
- How a remote property's value should be handled by the server when a connection is lost - STRING- Throws:
Exception
- If an error occurs
-
GetRemoteServiceBinding
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetRemoteServiceBinding(String serviceName) throws Exception - Service Category:
- Bindings
- Service Description:
- Get the remote service binding for a service.
- Parameters:
serviceName
- Service name - STRING- Returns:
- result Service binding - INFOTABLE - Aspects {dataShape:RemoteServiceBinding}
- Throws:
Exception
- If an error occurs
-
RemoveRemoteServiceBinding
@ThingworxExtensionApiMethod(since={6,6}) public void RemoveRemoteServiceBinding(String serviceName) throws Exception - Service Category:
- Bindings
- Service Description:
- Remove the remote service binding for a service.
- Parameters:
serviceName
- Service name - STRING- Throws:
Exception
- If an error occurs
-
SetRemoteServiceBinding
@ThingworxExtensionApiMethod(since={6,6}) public void SetRemoteServiceBinding(String serviceName, String sourceServiceName, Integer timeout) throws Exception - Service Category:
- Bindings
- Service Description:
- Set the remote service binding for a service.
- Parameters:
serviceName
- Service name - STRINGsourceServiceName
- Source service name - STRINGtimeout
- Request timeout - INTEGER- Throws:
Exception
- If an error occurs
-
GetRemoteEventBinding
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetRemoteEventBinding(String eventName) throws Exception - Service Category:
- Bindings
- Service Description:
- Get the remote event binding for a event.
- Parameters:
eventName
- Event name - STRING- Returns:
- result Event binding - INFOTABLE - Aspects {dataShape:RemoteEventBinding}
- Throws:
Exception
- If an error occurs
-
RemoveRemoteEventBinding
@ThingworxExtensionApiMethod(since={6,6}) public void RemoveRemoteEventBinding(String eventName) throws Exception - Service Category:
- Bindings
- Service Description:
- Remove the remote event binding for a event.
- Parameters:
eventName
- Event name - STRING- Throws:
Exception
- If an error occurs
-
SetRemoteEventBinding
@ThingworxExtensionApiMethod(since={6,6}) public void SetRemoteEventBinding(String eventName, String sourceEventName) throws Exception - Service Category:
- Bindings
- Service Description:
- Set the remote event binding for a event.
- Parameters:
eventName
- Event name - STRINGsourceEventName
- Source event name - STRING- Throws:
Exception
- If an error occurs
-
UpdatePropertyValuesBatched
@ThingworxExtensionApiMethod(since={9,5}) public void UpdatePropertyValuesBatched(InfoTable batches) throws Exception - Service Category:
- Properties
- Service Description:
- Write property values for a thing, processing change events in batches by timestamp.
- Parameters:
batches
- Collection of batches containing properties to be updated - INFOTABLE- Throws:
Exception
- If an error occurs
-
UpdatePropertyValues
@ThingworxExtensionApiMethod(since={6,6}) public void UpdatePropertyValues(InfoTable values) throws Exception - Service Category:
- Properties
- Service Description:
- Write property values for a thing.
- Parameters:
values
- Collection of properties to be updated - INFOTABLE- Throws:
Exception
- If an error occurs
-
GetPropertyQuality
@ThingworxExtensionApiMethod(since={6,6}) public String GetPropertyQuality(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the quality for a specific property.
- Parameters:
propertyName
- Property name - STRING- Returns:
- Quality Quality value - STRING
- Throws:
Exception
- If an error occurs
-
GetPropertyTime
@ThingworxExtensionApiMethod(since={6,6}) public org.joda.time.DateTime GetPropertyTime(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the timestamp for a specific property.
- Parameters:
propertyName
- Property name - STRING- Returns:
- Time Time value - DATETIME
- Throws:
Exception
- If an error occurs
-
GetLoggedProperties
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetLoggedProperties(String type) throws Exception - Service Category:
- Metadata
- Service Description:
- Get a list of logged properties for this thing.
- Parameters:
type
- Type to filter on - BASETYPENAME- Returns:
- result Property names - INFOTABLE - Aspects {dataShape:PropertyDefinition}
- Throws:
Exception
- If an error occurs
-
GetNumericLoggedProperties
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetNumericLoggedProperties() throws Exception- Service Category:
- Metadata
- Service Description:
- Get a list of logged properties for this thing that are of a numeric data type.
- Returns:
- result Property names - INFOTABLE - Aspects {dataShape:PropertyDefinition}
- Throws:
Exception
- If an error occurs
-
GetNumberPropertyValue
@ThingworxExtensionApiMethod(since={6,6}) public Double GetNumberPropertyValue(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property value.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property value - NUMBER
- Throws:
Exception
- If an error occurs
-
GetIntegerPropertyValue
@ThingworxExtensionApiMethod(since={6,6}) public Integer GetIntegerPropertyValue(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property value.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property value - INTEGER
- Throws:
Exception
- If an error occurs
-
GetLongPropertyValue
@ThingworxExtensionApiMethod(since={6,6}) public Long GetLongPropertyValue(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property value.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property value - LONG
- Throws:
Exception
- If an error occurs
-
GetBooleanPropertyValue
@ThingworxExtensionApiMethod(since={6,6}) public Boolean GetBooleanPropertyValue(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property value.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property value - BOOLEAN
- Throws:
Exception
- If an error occurs
-
GetLocationPropertyValue
@ThingworxExtensionApiMethod(since={6,6}) public Location GetLocationPropertyValue(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property value.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property value - LOCATION
- Throws:
Exception
- If an error occurs
-
GetDateTimePropertyValue
@ThingworxExtensionApiMethod(since={6,6}) public org.joda.time.DateTime GetDateTimePropertyValue(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property value.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property value - DATETIME
- Throws:
Exception
- If an error occurs
-
GetStringPropertyValue
@ThingworxExtensionApiMethod(since={6,6}) public String GetStringPropertyValue(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property value.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property value - STRING
- Throws:
Exception
- If an error occurs
-
GetVec2PropertyValue
@ThingworxExtensionApiMethod(since={7,1}) public Vec2 GetVec2PropertyValue(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property value.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property value - VEC2
- Throws:
Exception
- If an error occurs
-
GetVec3PropertyValue
@ThingworxExtensionApiMethod(since={7,1}) public Vec3 GetVec3PropertyValue(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property value.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property value - VEC3
- Throws:
Exception
- If an error occurs
-
GetVec4PropertyValue
@ThingworxExtensionApiMethod(since={7,1}) public Vec4 GetVec4PropertyValue(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property value.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property value - VEC4
- Throws:
Exception
- If an error occurs
-
GetThingCodePropertyValue
@ThingworxExtensionApiMethod(since={7,1}) public ThingCode GetThingCodePropertyValue(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property value.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property value - THINGCODE
- Throws:
Exception
- If an error occurs
-
GetImagePropertyValue
@ThingworxExtensionApiMethod(since={6,6}) public byte[] GetImagePropertyValue(String propertyName) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property value.
- Parameters:
propertyName
- Property name - STRING- Returns:
- result Property value - IMAGE
- Throws:
Exception
- If an error occurs
-
GetPropertyValues
- Service Category:
- Properties
- Service Description:
- Get the current property values for this thing.
- Returns:
- result Property values - INFOTABLE
- Throws:
Exception
- If an error occurs
-
GetPropertyValuesAsMultiRowTable
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetPropertyValuesAsMultiRowTable() throws Exception- Service Category:
- Properties
- Service Description:
- Get the current property values for this thing.
- Returns:
- result Property values - INFOTABLE
- Throws:
Exception
- If an error occurs
-
SetPropertyValues
@ThingworxExtensionApiMethod(since={6,6}) public void SetPropertyValues(InfoTable values) throws Exception - Service Category:
- Properties
- Service Description:
- Get a subset of the current property values for this thing.
- Parameters:
values
- Property values - INFOTABLE- Throws:
Exception
- If an error occurs
-
GetNamedPropertyValues
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetNamedPropertyValues(InfoTable propertyNames) throws Exception - Service Category:
- Properties
- Service Description:
- Gets the current values of the specified properties.
Gets the current values of the specified properties.To create the required
InfoTable
for thepropertyNames
parameter, theInfoTableFunctions.CreateInfoTableFromDataShape(String, String)
method can be used, specifying any arbitrary value for the InfoTable's name, and "EntityList
" for the DataShape's name. This DataShape defines a "name
" field for the InfoTable (all other fields defined on this DataShape can be ignored for this particular Service call). Once the InfoTable is created, populate the "name
field with the names of the properties whose current values are to be returned, where each property name is added as a new row.The returned
InfoTable
, defined by a dynamically builtDataShape
based upon the property names specified inpropertyNames
, contains only one row, where the name of each field is a property name and the value of each field is that property's current value.NOTE: If
propertyNames
is empty, then an empty InfoTable will be returned (i.e. 0 rows).- Parameters:
propertyNames
- anInfoTable
, described by the "EntityList
" DataShape, identifying the properties whose current values are to be returned- Returns:
- a non-null
InfoTable
containing one row, where each field name corresponds to a property name specified inpropertyNames
, and each field value is the current value of that corresponding property - Throws:
Exception
- ifpropertyNames
does not contain a "name
" field, or if it contains a property name that does not identify a property defined on this Thing
-
GetNamedProperties
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetNamedProperties(org.json.JSONObject propertyNames) throws Exception - Service Category:
- Properties
- Service Description:
- Gets the current values of the specified properties.
Gets the current values of the specified properties.The format of the
propertyNames
parameter must be:{ "items" : [ "<property-name-1>", "<property-name-2>", "..." ] }
The returned
InfoTable
, defined by a dynamically builtDataShape
based upon the property names specified inpropertyNames
, contains only one row, where the name of each field is a property name and the value of each field is that property's current value.NOTE: If
propertyNames
is empty, then an empty InfoTable will be returned (i.e. 0 rows).- Parameters:
propertyNames
- anInfoTable
, described by the "EntityList
" DataShape, identifying the properties whose current values are to be returned- Returns:
- a non-null
InfoTable
containing one row, where each field name corresponds to a property name specified inpropertyNames
, and each field value is the current value of that corresponding property - Throws:
Exception
- ifpropertyNames
does not adhere to the required format, or if the JSON array contains a property name that does not identify a property defined on this Thing
-
GetPropertyValuesVTQ
- Service Category:
- Properties
- Service Description:
- Get the current property values for this thing as VTQ.
- Returns:
- result Property values - INFOTABLE
- Throws:
Exception
- If an error occurs
-
GetNamedPropertyValuesVTQ
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetNamedPropertyValuesVTQ(InfoTable propertyNames) throws Exception - Service Category:
- Properties
- Service Description:
- Get the current property values for this thing as VTQ.
- Parameters:
propertyNames
- Property names - INFOTABLE- Returns:
- result Property values - INFOTABLE - Aspects {isMultiRow: false}
- Throws:
Exception
- If an error occurs
-
GetPropertyValuesVTQA
- Service Category:
- Properties
- Service Description:
- Get the current property values (VTQ) and the highest alert for this thing.
- Returns:
- result Property values VTQA - INFOTABLE - Aspects {isMultiRow: false}
- Throws:
Exception
- If an error occurs
-
GetNamedPropertyValuesVTQA
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetNamedPropertyValuesVTQA(InfoTable propertyNames) throws Exception - Service Category:
- Properties
- Service Description:
- Get a subset of the current property values (VTQ) and the highest alert for this thing.
- Parameters:
propertyNames
- Property names - INFOTABLE- Returns:
- result Property values VTQA - INFOTABLE - Aspects {isMultiRow: false}
- Throws:
Exception
- If an error occurs
-
QueryAlertSummary
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryAlertSummary(org.json.JSONObject query, Boolean onlyAcknowledged, Boolean onlyUnacknowledged, Double maxItems) throws Exception - Service Category:
- Alerts
- Service Description:
- Query the alert summary.
- Parameters:
query
- Query definition - QUERYonlyAcknowledged
- Show only acknowledged alerts - BOOLEANonlyUnacknowledged
- Show only unacknowledged alerts - BOOLEANmaxItems
- Maximum number of items to return - NUMBER- Returns:
- result Alert Summary - INFOTABLE - Aspects {dataShape:AlertSummary}
- Throws:
Exception
- If an error occurs
-
QueryAlertHistory
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryAlertHistory(org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query, Double maxItems) throws Exception - Service Category:
- Alerts
- Service Description:
- Query the alert history.
- Parameters:
startDate
- Start time - DATETIMEendDate
- End time - DATETIMEoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERYmaxItems
- Maximum number of items to return - NUMBER- Returns:
- result Alert History - INFOTABLE - Aspects {dataShape:AlertHistory, isStreamEntry:true}
- Throws:
Exception
- If an error occurs
-
AcknowledgeAllAlerts
@ThingworxExtensionApiMethod(since={6,6}) public void AcknowledgeAllAlerts(String message) throws Exception - Service Category:
- Alerts
- Service Description:
- Acknowledge all active alerts.
- Parameters:
message
- Message (optional) - STRING- Throws:
Exception
- If an error occurs
-
AcknowledgeAlert
@ThingworxExtensionApiMethod(since={6,6}) public void AcknowledgeAlert(String property, String message) throws Exception - Service Category:
- Alerts
- Service Description:
- Acknowledge an active alert.
- Parameters:
property
- Property name - STRINGmessage
- Message (optional) - STRING- Throws:
Exception
- If an error occurs
Additional InformationThis service takes the name of the property and the message and throws an alert acknowledge event.
Acknowledges each alert on the property whether or not it's in an alert state.
-
GetAlertSummary
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetAlertSummary(Boolean onlyAcknowledged, Boolean onlyUnacknowledged, Double maxItems) throws Exception - Service Category:
- Alerts
- Service Description:
- Get alert summary status.
- Parameters:
onlyAcknowledged
- Show only acknowledged alerts - BOOLEANonlyUnacknowledged
- Show only unacknowledged alerts - BOOLEANmaxItems
- Maximum number of items to return - NUMBER- Returns:
- Status Alert status - INFOTABLE - Aspects {dataShape:AlertSummary}
- Throws:
Exception
- If an error occurs
-
GetAlertSummaryForProperty
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetAlertSummaryForProperty(String property, Boolean onlyAcknowledged, Boolean onlyUnacknowledged, Double maxItems) throws Exception - Service Category:
- Alerts
- Service Description:
- Get alert summary for a property.
- Parameters:
property
- Property name - STRINGonlyAcknowledged
- Show only acknowledged alerts - BOOLEANonlyUnacknowledged
- Show only unacknowledged alerts - BOOLEANmaxItems
- Maximum number of items to return - NUMBER- Returns:
- AlertSummary Alert summary - INFOTABLE - Aspects {dataShape:PropertyAlertSummary}
- Throws:
Exception
- If an error occurs
-
DisableAllAlerts
@ThingworxExtensionApiMethod(since={6,6}) public void DisableAllAlerts(Boolean persistent) throws Exception - Service Category:
- Alerts
- Service Description:
- Disable all alerts for a thing.
- Parameters:
persistent
- Persist this change - BOOLEAN- Throws:
Exception
- If an error occurs
-
EnableAllAlerts
@ThingworxExtensionApiMethod(since={6,6}) public void EnableAllAlerts(Boolean persistent) throws Exception - Service Category:
- Alerts
- Service Description:
- Enable all alerts for a thing.
- Parameters:
persistent
- Persist this change - BOOLEAN- Throws:
Exception
- If an error occurs
-
DisableAlertsForProperty
@ThingworxExtensionApiMethod(since={6,6}) public void DisableAlertsForProperty(String property, String alertName, Boolean persistent) throws Exception - Service Category:
- Alerts
- Service Description:
- Disable alert(s) for a property. Specify alertName for a specific property alert; otherwise, all alerts are disabled.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGpersistent
- Persist this change - BOOLEAN- Throws:
Exception
- If an error occurs
-
EnableAlertsForProperty
@ThingworxExtensionApiMethod(since={6,6}) public void EnableAlertsForProperty(String property, String alertName, Boolean persistent) throws Exception - Service Category:
- Alerts
- Service Description:
- Enable alert(s) for a property. Specify alertName for a specific property alert; otherwise, all alerts are enabled.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGpersistent
- Persist this change - BOOLEAN- Throws:
Exception
- If an error occurs
-
getEffectiveAlertDefinition
@ThingworxExtensionApiMethod(since={6,6}) public AlertDefinition getEffectiveAlertDefinition(String property, String alertName) -
GetPropertyLogging
@ThingworxExtensionApiMethod(since={6,6}) public Boolean GetPropertyLogging(String propertyName) throws Exception - Service Category:
- DataLogging
- Service Description:
- Get property logging status for a specific property.
- Parameters:
propertyName
- Property name - STRING- Returns:
- status Property logging status - BOOLEAN
- Throws:
Exception
- If an error occurs
-
SetPropertyLogging
@ThingworxExtensionApiMethod(since={6,6}) public void SetPropertyLogging(String propertyName, Boolean enabled) throws Exception - Service Category:
- DataLogging
- Service Description:
- Set property logging status for a specific property.
- Parameters:
propertyName
- Property name - STRINGenabled
- Enable/disable logging - BOOLEAN- Throws:
Exception
- If an error occurs
-
SetUnitsForNumericPropertyDefinition
@ThingworxExtensionApiMethod(since={8,5}) public void SetUnitsForNumericPropertyDefinition(String propertyName, String units) throws Exception - Service Category:
- Metadata
- Service Description:
- Set the additional information for units for a specific Long, Integer, or Number property.
- Parameters:
propertyName
- Property name - STRINGunits
- Units (eg. lbs, F, inches, etc.) associated with input. For information only. - STRING- Throws:
Exception
- If an error occurs
-
GetEffectivePropertyLogging
@ThingworxExtensionApiMethod(since={7,2,2}) public Boolean GetEffectivePropertyLogging(String propertyName) throws InvalidRequestException - Service Category:
- DataLogging
- Service Description:
- Get the logging status of a specific property from the effective Thing shape.
- Parameters:
propertyName
- Property name to look up on the effective shape for its logging status - STRING- Returns:
- status Effective property logging status - BOOLEAN
- Throws:
InvalidRequestException
- If an error occurs
-
AddPropertyDefinition
@ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={8,0}) @Deprecated public void AddPropertyDefinition(String name, String description, String type, String category, String dataShape, Boolean readOnly, Boolean persistent, Boolean logged, String dataChangeType, Double dataChangeThreshold, Boolean remote, String remotePropertyName, Integer timeout, String pushType, Double pushThreshold, String defaultValue) throws Exception Deprecated.As of release 8.0, replaced by AddPropertyDefinition(String, String, String, String, String, Boolean, Boolean, Boolean, String, Double, Boolean, String, Integer, String, Double, String, JSONObject)- Throws:
Exception
- If an error occurs
-
AddPropertyDefinition
@ThingworxExtensionApiMethod(since={8,0}, deprecatedSince={9,3}) @Deprecated public void AddPropertyDefinition(String name, String description, String type, String category, String dataShape, Boolean readOnly, Boolean persistent, Boolean logged, String dataChangeType, Double dataChangeThreshold, Boolean remote, String remotePropertyName, Integer timeout, String pushType, Double pushThreshold, String defaultValue, org.json.JSONObject remoteBindingAspects) throws Exception Deprecated.- Throws:
Exception
- If an error occurs
-
AddPropertyDefinition
@ThingworxExtensionApiMethod(since={8,0}, deprecatedSince={9,4}) @Deprecated public void AddPropertyDefinition(String name, String description, String type, String category, String dataShape, Boolean readOnly, Boolean persistent, Boolean logged, Boolean indexed, String dataChangeType, Double dataChangeThreshold, Boolean remote, String remotePropertyName, Integer timeout, String pushType, Double pushThreshold, String defaultValue, org.json.JSONObject remoteBindingAspects) throws Exception Deprecated.- Throws:
Exception
- If an error occurs
-
AddPropertyDefinition
@ThingworxExtensionApiMethod(since={9,3}) public void AddPropertyDefinition(String name, String description, String type, String category, String dataShape, Boolean readOnly, Boolean persistent, Boolean logged, Boolean indexed, String dataChangeType, Double dataChangeThreshold, Boolean remote, String remotePropertyName, Integer timeout, String pushType, Double pushThreshold, String defaultValue, org.json.JSONObject remoteBindingAspects, org.json.JSONObject accessModifier) throws Exception - Service Category:
- Metadata
- Service Description:
- Add a property definition.
- Parameters:
name
- Property name - STRINGdescription
- Property description - STRINGtype
- Data type - BASETYPENAMEcategory
- Category - STRINGdataShape
- Data shape - DATASHAPENAMEreadOnly
- Read only - BOOLEANpersistent
- Persist property value - BOOLEANlogged
- Log property value - BOOLEANindexed
- Index property value - BOOLEANdataChangeType
- Data change type - STRINGdataChangeThreshold
- Data change threshold - NUMBERremote
- Is a remote property - BOOLEANremotePropertyName
- Remote property name - STRINGtimeout
- Request timeout - INTEGERpushType
- Push type - STRINGpushThreshold
- Push threshold - NUMBERdefaultValue
- Default value for property - STRINGremoteBindingAspects
- Aspects for the remote binding - JSONaccessModifier
- AccessModifier for propertyDefinition - JSON- Throws:
Exception
- If an error occurs
-
AddPropertyTransformDefinition
@ThingworxExtensionApiMethod(since={8,4}) public void AddPropertyTransformDefinition(String name, String description, String category, Boolean persistent, Boolean logged, Integer timeout, InfoTable propertyTransformConfig) throws Exception - Service Category:
- Metadata
- Service Description:
- Add a property transform definition.
- Parameters:
name
- - The name of your new derived property.description
- - The description of the new property.category
- - Category for the new property.persistent
- - Should the value of this derived property be persisted between tomcat restarts?logged
- - Should the value of this derived property be logged over time?timeout
- - Timeout for creating the property.propertyTransformConfig
- - A configuration infotable consisting of key/value pairs. Refer to the help center for possible keys.- Throws:
Exception
- If an error occurs
Creates a derived property on this Thing. A derived property receives data from a specified source property, and performs some requested calculation on the stream of data as the source property changes. The type of calculation will determine which configuration keys/values need to be set on the derivedPropertyConfig.
Note: In order to use the derived property functionality, you must have a RabbitMQ instance, Flink cluster, and "derived property configuration service" running on your machine, as well as the necessary configuration set inside your platform-settings.json file.
For more information on running derived properties, please refer to the help center docs on derived properties.
-
AddPropertyDefinitions
@ThingworxExtensionApiMethod(since={7,3}) public InfoTable AddPropertyDefinitions(InfoTable values, Boolean ignoreInvalidDefinitions) throws Exception - Service Category:
- Metadata
- Service Description:
- Add multiple property definitions at once.
- Parameters:
values
- Infotable where each row defines a property, using the PropertyDefinitionWithDetailsV2 data shape - INFOTABLEignoreInvalidDefinitions
- True will skip over any invalid definitions provided, false indicates to fail the whole transaction when at least one invalid definition is found - BOOLEAN- Returns:
- status Table of information about which properties caused errors while attempting to add - INFOTABLE - Aspects {dataShape:BulkProcessingReport}
- Throws:
Exception
- If an error occurs
-
AddServiceDefinition
@ThingworxExtensionApiMethod(since={8,0}, deprecatedSince={9,4}) @Deprecated public void AddServiceDefinition(String name, String description, String category, InfoTable parameters, InfoTable resultType, Boolean remote, String remoteServiceName, Integer timeout) throws Exception Deprecated.- Throws:
Exception
- If an error occurs
-
AddServiceDefinition
@ThingworxExtensionApiMethod(since={6,6}) public void AddServiceDefinition(String name, String description, String category, InfoTable parameters, InfoTable resultType, Boolean remote, String remoteServiceName, Integer timeout, org.json.JSONObject accessModifier) throws Exception - Service Category:
- Metadata
- Service Description:
- Add or update a service definition.
- Parameters:
name
- Property name - STRINGdescription
- Property description - STRINGcategory
- Category - STRINGparameters
- Service parameters - INFOTABLEresultType
- Service result type - INFOTABLEremote
- Is a remote service - BOOLEANremoteServiceName
- Remote service name - STRINGtimeout
- Request timeout - INTEGERaccessModifier
- AccessModifier for serviceDefinition - JSON- Throws:
Exception
- If an error occurs
-
AddEventDefinition
@ThingworxExtensionApiMethod(since={6,6}) public void AddEventDefinition(String name, String description, String category, String dataShape, Boolean remote, String remoteEventName) throws Exception - Service Category:
- Metadata
- Service Description:
- Add or update an event definition.
- Parameters:
name
- Property name - STRINGdescription
- Property description - STRINGcategory
- Category - STRINGdataShape
- Data shape - DATASHAPENAMEremote
- Is a remote service - BOOLEANremoteEventName
- Remote event name - STRING- Throws:
Exception
- If an error occurs
-
DisableSubscription
@Deprecated @ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={9,0}) public void DisableSubscription(String thingName, String eventName, String propertyName) throws Exception Deprecated.- Throws:
Exception
- If an error occurs
-
DisableSubscription
@ThingworxExtensionApiMethod(since={9,0}) public void DisableSubscription(String subscriptionName) throws Exception - Service Category:
- Subscriptions
- Service Description:
- Disable Subscription.
- Parameters:
subscriptionName
- Subscription name - STRING- Throws:
Exception
- If an error occurs
-
EnableSubscription
@Deprecated @ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={9,0}) public void EnableSubscription(String thingName, String eventName, String propertyName) throws Exception Deprecated.- Throws:
Exception
- If an error occurs
-
EnableSubscription
@ThingworxExtensionApiMethod(since={9,0}) public void EnableSubscription(String subscriptionName) throws Exception - Service Category:
- Subscriptions
- Service Description:
- Enable Subscription.
- Parameters:
subscriptionName
- Subscription name - STRING- Throws:
Exception
- If an error occurs
-
RemovePropertyDefinition
@ThingworxExtensionApiMethod(since={6,6}) public void RemovePropertyDefinition(String name) throws Exception - Service Category:
- Metadata
- Service Description:
- Remove a property definition.
- Parameters:
name
- Property name - STRING- Throws:
Exception
- If an error occurs
-
RemoveServiceDefinition
@ThingworxExtensionApiMethod(since={6,6}) public void RemoveServiceDefinition(String name) throws Exception - Service Category:
- Metadata
- Service Description:
- Remove a service definition.
- Parameters:
name
- Service name - STRING- Throws:
Exception
- If an error occurs
-
RemoveEventDefinition
@ThingworxExtensionApiMethod(since={6,6}) public void RemoveEventDefinition(String name) throws Exception - Service Category:
- Metadata
- Service Description:
- Remove a event definition.
- Parameters:
name
- Event name - STRING- Throws:
Exception
- If an error occurs
-
AddOrUpdateAlert
@ThingworxExtensionApiMethod(since={6,6}) public void AddOrUpdateAlert(String property, String alertType, String alertName, String description, Boolean enabled, Integer priority, InfoTable attributes, Boolean persistent) throws Exception - Service Category:
- Alerts
- Service Description:
- Add or update an alert for a property.
- Parameters:
property
- Property name - STRINGalertType
- Alert type - STRINGalertName
- Alert name - STRINGdescription
- Alert description - STRINGenabled
- Alert enabled - BOOLEANpriority
- Alert priority - INTEGERattributes
- Alert attributes - INFOTABLEpersistent
- Persist this change - BOOLEAN- Throws:
Exception
- If an error occurs
-
RemoveAlert
@ThingworxExtensionApiMethod(since={6,6}) public void RemoveAlert(String property, String alertName, Boolean persistent) throws Exception - Service Category:
- Alerts
- Service Description:
- Remove an alert for a property.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGpersistent
- Persist this change - BOOLEAN- Throws:
Exception
- If an error occurs
-
GetLocalAlertDefinitions
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetLocalAlertDefinitions(String property) throws Exception - Service Category:
- Alerts
- Service Description:
- Get local alert definitions for a property.
- Parameters:
property
- Property name - STRING- Returns:
- AlertDefinitions Alert definition - INFOTABLE - Aspects {dataShape:AlertDefinition}
- Throws:
Exception
- If an error occurs
-
GetAlertDefinitions
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetAlertDefinitions(String property) throws Exception - Service Category:
- Alerts
- Service Description:
- Get effective alert definitions for a property.
- Parameters:
property
- Property name - STRING- Returns:
- AlertDefinitions Alert definition - INFOTABLE - Aspects {dataShape:AlertDefinition}
- Throws:
Exception
- If an error occurs
-
GetAlertDefinition
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetAlertDefinition(String property, String alertName) throws Exception - Service Category:
- Alerts
- Service Description:
- Get alert definition for a property.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRING- Returns:
- AlertDefinitions Alert definition - INFOTABLE - Aspects {dataShape:AlertDefinition}
- Throws:
Exception
- If an error occurs
-
HasAlert
@ThingworxExtensionApiMethod(since={6,6}) public Boolean HasAlert(String property, String alertName) throws Exception - Service Category:
- Alerts
- Service Description:
- Check to see if an alert is defined for a property.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRING- Returns:
- result Has alert definition - BOOLEAN
- Throws:
Exception
- If an error occurs
-
SetNumberAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public void SetNumberAlertParameter(String property, String alertName, String parameterName, Double value, Boolean persistent) throws Exception - Service Category:
- Alerts
- Service Description:
- Set a numeric alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRINGvalue
- Parameter value - NUMBERpersistent
- Make it persistent - BOOLEAN- Throws:
Exception
- If an error occurs
-
GetNumberAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public Double GetNumberAlertParameter(String property, String alertName, String parameterName) throws Exception - Service Category:
- Alerts
- Service Description:
- Get a numeric alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRING- Returns:
- value Alert parameter value - NUMBER
- Throws:
Exception
- If an error occurs
-
SetIntegerAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public void SetIntegerAlertParameter(String property, String alertName, String parameterName, Integer value, Boolean persistent) throws Exception - Service Category:
- Alerts
- Service Description:
- Set a numeric alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRINGvalue
- Parameter value - INTEGERpersistent
- Make it persistent - BOOLEAN- Throws:
Exception
- If an error occurs
-
GetIntegerAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public Integer GetIntegerAlertParameter(String property, String alertName, String parameterName) throws Exception - Service Category:
- Alerts
- Service Description:
- Get a numeric alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRING- Returns:
- value Alert parameter value - INTEGER
- Throws:
Exception
- If an error occurs
-
GetLongAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public Long GetLongAlertParameter(String property, String alertName, String parameterName) throws Exception - Service Category:
- Alerts
- Service Description:
- Get a long alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRING- Returns:
- value Alert parameter value - LONG
- Throws:
Exception
- If an error occurs
-
SetBooleanAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public void SetBooleanAlertParameter(String property, String alertName, String parameterName, Boolean value, Boolean persistent) throws Exception - Service Category:
- Alerts
- Service Description:
- Set a boolean alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRINGvalue
- Parameter value - BOOLEANpersistent
- Make it persistent - BOOLEAN- Throws:
Exception
- If an error occurs
-
GetBooleanAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public Boolean GetBooleanAlertParameter(String property, String alertName, String parameterName) throws Exception - Service Category:
- Alerts
- Service Description:
- Get a boolean alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRING- Returns:
- value Alert parameter value - BOOLEAN
- Throws:
Exception
- If an error occurs
-
SetDateTimeAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public void SetDateTimeAlertParameter(String property, String alertName, String parameterName, org.joda.time.DateTime value, Boolean persistent) throws Exception - Service Category:
- Alerts
- Service Description:
- Set a date alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRINGvalue
- Parameter value - DATETIMEpersistent
- Make it persistent - BOOLEAN- Throws:
Exception
- If an error occurs
-
GetDateTimeAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public org.joda.time.DateTime GetDateTimeAlertParameter(String property, String alertName, String parameterName) throws Exception - Service Category:
- Alerts
- Service Description:
- Get a date alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRING- Returns:
- value Alert parameter value - DATETIME
- Throws:
Exception
- If an error occurs
-
SetLocationAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public void SetLocationAlertParameter(String property, String alertName, String parameterName, Location value, Boolean persistent) throws Exception - Service Category:
- Alerts
- Service Description:
- Set a location alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRINGvalue
- Parameter value - LOCATIONpersistent
- Make it persistent - BOOLEAN- Throws:
Exception
- If an error occurs
-
GetLocationAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public Location GetLocationAlertParameter(String property, String alertName, String parameterName) throws Exception - Service Category:
- Alerts
- Service Description:
- Get a location alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRING- Returns:
- value Alert parameter value - LOCATION
- Throws:
Exception
- If an error occurs
-
SetStringAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public void SetStringAlertParameter(String property, String alertName, String parameterName, String value, Boolean persistent) throws Exception - Service Category:
- Alerts
- Service Description:
- Set a string alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRINGvalue
- Parameter value - STRINGpersistent
- Make it persistent - BOOLEAN- Throws:
Exception
- If an error occurs
-
GetStringAlertParameter
@ThingworxExtensionApiMethod(since={6,6}) public String GetStringAlertParameter(String property, String alertName, String parameterName) throws Exception - Service Category:
- Alerts
- Service Description:
- Get a string alert parameter.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRINGparameterName
- Parameter name - STRING- Returns:
- value Alert parameter value - STRING
- Throws:
Exception
- If an error occurs
-
GetAlertStatus
@ThingworxExtensionApiMethod(since={7,4}) public String GetAlertStatus(String property, String alertName) throws Exception - Service Category:
- Alerts
- Service Description:
- Get the Status of the given Alert.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRING- Returns:
- result Status of Alert - STRING
- Throws:
Exception
- If an error occurs
-
GetAlertStatuses
- Service Category:
- Alerts
- Service Description:
- Get the Statuses of the given Alerts.
- Returns:
- result Status of all Alerts on this Thing - INFOTABLE - Aspects {dataShape:AlertStatus}
- Throws:
Exception
- If an error occurs
-
GetAlertStatusesForProperty
@ThingworxExtensionApiMethod(since={7,4}) public InfoTable GetAlertStatusesForProperty(String property) throws Exception - Service Category:
- Alerts
- Service Description:
- Get the Statuses of the given Alerts.
- Parameters:
property
- Property name - STRING- Returns:
- result Status of all Alerts on the Property - INFOTABLE
- Throws:
Exception
- If an error occurs
-
GetAnomalyAlertTrainingStatisticsForAlert
@ThingworxExtensionApiMethod(since={8,0}) public InfoTable GetAnomalyAlertTrainingStatisticsForAlert(String property, String alertName) throws Exception - Service Category:
- Alerts
- Service Description:
- Get Training Statistics for given Alert.
- Parameters:
property
- Property name - STRINGalertName
- Alert name - STRING- Returns:
- result Anomaly Alert Training Statistics for given Alert - INFOTABLE - Aspects {dataShape:AnomalyAlertTrainingStatistics}
- Throws:
Exception
- If an error occurs
-
GetAllAnomalyAlertTrainingStatistics
@ThingworxExtensionApiMethod(since={8,0}) public InfoTable GetAllAnomalyAlertTrainingStatistics() throws Exception- Service Category:
- Alerts
- Service Description:
- Get All AnomalyAlert Training Statistics on this Thing.
- Returns:
- result AnomalyAlert Training Statistics on this Thing - INFOTABLE - Aspects {dataShape:AnomalyAlertTrainingStatistics}
- Throws:
Exception
- If an error occurs
-
GetAnomalyAlertTrainingStatisticsForProperty
@ThingworxExtensionApiMethod(since={8,0}) public InfoTable GetAnomalyAlertTrainingStatisticsForProperty(String property) throws Exception - Service Category:
- Alerts
- Service Description:
- Get AnomalyAlert Training Statistics for given Property.
- Parameters:
property
- Property name - STRING- Returns:
- result Training Statistics of all AnomalyAlerts on the Property - INFOTABLE - Aspects {dataShape:AnomalyAlertTrainingStatistics}
- Throws:
Exception
- If an error occurs
-
AddDynamicSubscription
@ThingworxExtensionApiMethod(since={6,6}) public void AddDynamicSubscription(String thingName, String eventName, String propertyName, String serviceName) throws Exception - Service Category:
- Subscriptions
- Service Description:
- Add a dynamic subscription.
- Parameters:
thingName
- Thing name - THINGNAMEeventName
- Event name - STRINGpropertyName
- Property name - STRINGserviceName
- Local service name - STRING- Throws:
Exception
- If an error occurs
-
IsDynamicSubscriptionCreated
@ThingworxExtensionApiMethod(since={8,5}) public boolean IsDynamicSubscriptionCreated(String thingName, String eventName, String propertyName, String serviceName) throws Exception - Service Category:
- Subscriptions
- Service Description:
- Returns true if given dynamic subscription is present.
- Parameters:
thingName
- Thing name - THINGNAMEeventName
- Event name - STRINGpropertyName
- Property name - STRINGserviceName
- Local service name - STRING- Returns:
- result True/false based on if given dynamic subscription exist or not - BOOLEAN
- Throws:
Exception
- If an error occurs
-
RemoveDynamicSubscription
@ThingworxExtensionApiMethod(since={6,6}) public void RemoveDynamicSubscription(String thingName, String eventName, String propertyName, String serviceName) throws Exception - Service Category:
- Subscriptions
- Service Description:
- Remove a dynamic subscription.
- Parameters:
thingName
- Thing name - THINGNAMEeventName
- Event name - STRINGpropertyName
- Property name - STRINGserviceName
- Local service name - STRING- Throws:
Exception
- If an error occurs
-
dispatchEvent
-
dispatchBackgroundEvent
-
processServiceRequest
@ThingworxExtensionApiMethod(since={6,6}, canOverride=true, requiresSuper=true) public InfoTable processServiceRequest(String serviceName, ValueCollection params) throws Exception Description copied from interface:IServiceProvider
Processes an internal or reflected service request. Entities may call this method if they wish to invoke a service call directly on an entity. This method performs a service invoke authorization check against the current security context.
- Specified by:
processServiceRequest
in interfaceIServiceProvider
- Parameters:
serviceName
- - The name of the service to invokeparams
- - A collection of parameter mappings- Returns:
- The results of the service invocation
- Throws:
Exception
- If an error occurs
If the security check fails, the service does not exist, or an error occurred during the execution of the serviceSubclasses of
Thing
may override this method if they want to add additional logic or validation around service calls.
-
processAPIServiceRequest
@ThingworxExtensionApiMethod(since={6,6}, canOverride=true, requiresSuper=true) public InfoTable processAPIServiceRequest(String serviceName, ValueCollection params) throws Exception Description copied from interface:IServiceProvider
Processes a service request invoked via the REST API. This method performs a service invoke authorization check against the current security context.
- Specified by:
processAPIServiceRequest
in interfaceIServiceProvider
- Parameters:
serviceName
- - The name of the service to invokeparams
- - A collection of parameter mappings- Returns:
- The results of the service invocation
- Throws:
Exception
- If an error occurs
If the security check fails, the service does not exist, or an error occurred during the execution of the serviceSubclasses of
Thing
may override this method if they want to add additional logic or validation around service calls.
-
isAlwaysAvailableService
@ThingworxExtensionApiMethod(since={6,6}, canOverride=true, requiresSuper=true) public static boolean isAlwaysAvailableService(String name)
Returns
true
if the provided service name can always be invoked against the thing, regardless of its current state.Subclasses overriding this method must ensure that they preserve and return the result of this method if it returns true.
- Parameters:
name
- the name of the service to check- Returns:
true
if the service can always be invoked
-
fireEvent
@ThingworxExtensionApiMethod(since={6,6}) public void fireEvent(EventDefinition eventDefinition, org.joda.time.DateTime timestamp, ValueCollection eventData) throws Exception - Specified by:
fireEvent
in interfaceIEventProvider
- Throws:
Exception
- If an error occurs
-
GetImplementedShapes
- Service Category:
- Metadata
- Service Description:
- Get the implemented thing shapes for this thing.
- Returns:
- result Implemented Shapes - INFOTABLE - Aspects {dataShape:EntityList}
- Throws:
Exception
- If an error occurs
-
GetLocallyImplementedShapes
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetLocallyImplementedShapes() throws Exception- Service Category:
- Metadata
- Service Description:
- Get the locally implemented thing shapes for this thing.
- Returns:
- result Implemented Shapes - INFOTABLE - Aspects {dataShape:EntityList}
- Throws:
Exception
- If an error occurs
-
GetMashups
- Service Category:
- Mashups
- Service Description:
- Get the mashups related to this thing.
- Returns:
- result Mashups - INFOTABLE - Aspects {dataShape:MashupList}
- Throws:
Exception
- If an error occurs
-
GetThingTemplate
- Service Category:
- Metadata
- Service Description:
- Get the thing template for this thing.
- Returns:
- result Thing Template - INFOTABLE - Aspects {dataShape:EntityList}
- Throws:
Exception
- If an error occurs
-
ImplementsShape
@ThingworxExtensionApiMethod(since={6,6}) public Boolean ImplementsShape(String thingShapeName) throws Exception - Service Category:
- Metadata
- Service Description:
- Check to see if a thing implements a particular thing shape.
- Parameters:
thingShapeName
- Thing shape name - THINGSHAPENAME- Returns:
- result Implements Shape - BOOLEAN
- Throws:
Exception
- If an error occurs
-
IsDerivedFromTemplate
@ThingworxExtensionApiMethod(since={6,6}) public Boolean IsDerivedFromTemplate(String thingTemplateName) throws Exception - Service Category:
- Metadata
- Service Description:
- Check to see if a thing is derived from a particular thing template.
- Parameters:
thingTemplateName
- Thing template name - THINGTEMPLATENAME- Returns:
- result Is Derived From Template - BOOLEAN
- Throws:
Exception
- If an error occurs
-
SetPublished
@ThingworxExtensionApiMethod(since={6,6}) public void SetPublished(Boolean publish) throws Exception - Service Category:
- Federation
- Service Description:
- Set this as a published thing for federation.
- Parameters:
publish
- Publish status (true/false) - BOOLEAN- Throws:
Exception
- If an error occurs
-
GetPublished
- Service Category:
- Federation
- Service Description:
- Get published thing for federation.
- Returns:
- result Publishing status for this thing - BOOLEAN
- Throws:
Exception
- If an error occurs
-
SetDescription
@ThingworxExtensionApiMethod(since={6,6}) public void SetDescription(String description) throws Exception - Service Category:
- Metadata
- Service Description:
- Overwrite/set the description for an entity.
- Overrides:
SetDescription
in classRootEntity
- Parameters:
description
- Description for an entity - STRING- Throws:
Exception
- If an error occurs
-
SetTags
- Service Category:
- Metadata
- Service Description:
- Overwrite/set the tags for an entity.
- Overrides:
SetTags
in classRootEntity
- Parameters:
tags
- Tags for an entity - TAGS- Throws:
Exception
- If an error occurs
-
AddTags
- Service Category:
- Metadata
- Service Description:
- Append additional tags to an entity.
- Overrides:
AddTags
in classRootEntity
- Parameters:
tags
- Tags for an entity - TAGS- Throws:
Exception
- If an error occurs
-
GetThingRelationships
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetThingRelationships(Integer maxDepth) throws Exception - Service Category:
- Relationships
- Service Description:
- Return a list of all the things referenced by this thing.
- Parameters:
maxDepth
- Maximum depth to search - INTEGER- Returns:
- result Thing connections - INFOTABLE - Aspects {dataShape:ThingRelationship}
- Throws:
Exception
- If an error occurs
-
GetNetworks
- Service Category:
- Networks
- Service Description:
- Get the networks associated with a thing.
- Returns:
- networks Networks - INFOTABLE - Aspects {dataShape:EntityList}
- Throws:
Exception
- If an error occurs
-
IsInNetwork
@ThingworxExtensionApiMethod(since={6,6}) public Boolean IsInNetwork(String network) throws Exception - Service Category:
- Networks
- Service Description:
- Check to see if a thing is in a specific network.
- Parameters:
network
- Network name - STRING- Returns:
- result Result - BOOLEAN
- Throws:
Exception
- If an error occurs
-
HavePropertiesChangedSince
@ThingworxExtensionApiMethod(since={6,6}) public Boolean HavePropertiesChangedSince(org.joda.time.DateTime timestamp) throws Exception - Service Category:
- Properties
- Service Description:
- Has any property changed since a given time.
- Parameters:
timestamp
- Timestamp to compare - DATETIME- Returns:
- result Result - BOOLEAN
- Throws:
Exception
- If an error occurs
-
PurgePropertyHistory
@ThingworxExtensionApiMethod(since={6,6}) public void PurgePropertyHistory(String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean immediate) throws Exception - Service Category:
- Maintenance
- Service Description:
- Purge stream entries for a specified date range.
- Parameters:
propertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEimmediate
- Delete immediately - BOOLEAN- Throws:
Exception
- If an error occurs
-
PurgeAllPropertyHistory
@ThingworxExtensionApiMethod(since={7,2}) public void PurgeAllPropertyHistory(org.joda.time.DateTime startDate, org.joda.time.DateTime endDate) throws Exception - Service Category:
- Maintenance
- Service Description:
- Purge all value stream entries for a specified date range.
- Parameters:
startDate
- Start time - DATETIMEendDate
- End time - DATETIME- Throws:
Exception
- If an error occurs
-
PurgeSelectedPropertyHistory
@ThingworxExtensionApiMethod(since={7,2}) public void PurgeSelectedPropertyHistory(org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, InfoTable propertiesToPurge) throws Exception - Service Category:
- Maintenance
- Service Description:
- Purge all value stream entries for a specified date range for a given list of properties.
- Parameters:
startDate
- Start time - DATETIMEendDate
- End time - DATETIMEpropertiesToPurge
- Properties to purge - INFOTABLE- Throws:
Exception
- If an error occurs
-
QueryPropertyHistory
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryPropertyHistory(Double maxItems, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
Additional InformationQueries the value stream for each property (must be a logged property) value of the given source thing in a given time range. Calls ValueStream.queryValueStreamEntries for each property, then munges the values together in a result set.
QueryPropertyHistory returns a data set created by querying each logged property on a thing and then combining the individual datasets into one big data set. A "row" is created for each time stamp in the individual data sets. If there is a logged value with that time stamp, it is entered in the row of the data set. If there is no logged value, the last logged value for that property is used. If there is no logged property; the entry is left blank. This combiner process removes duplicates for a given property based on timestamp.
To obtain the actual logged values for a given property, you must use the QuerydatatypePropertyHistory services (for example, QueryIntegerPropertyHistory). You can confirm that data is actually purged with these services.
-
QueryPropertyHistory
@ThingworxExtensionApiMethod(since={9,3,4}) public InfoTable QueryPropertyHistory(Double maxItems, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, String fillOption, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryPropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryPropertyHistory(Double maxItems, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, String fillOption, String returnedMetadata, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Queries the value stream entries for logged property value along with filter and sort criteria and normalizes the data set to display result for a given time range.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANfillOption
- Defines the value to report for time intervals with no data - STRINGreturnedMetadata
- Defines what extra columns will be returned in addition to the Property name, timestamp, and value. - STRINGquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE
- Throws:
Exception
- If an error occurs
-
QueryNamedPropertyHistory
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryNamedPropertyHistory(InfoTable propertyNames, Double maxItems, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryNamedPropertyHistory
@ThingworxExtensionApiMethod(since={9,3,4}) public InfoTable QueryNamedPropertyHistory(InfoTable propertyNames, Double maxItems, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, String fillOption, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryNamedPropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryNamedPropertyHistory(InfoTable propertyNames, Double maxItems, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, String fillOption, String returnedMetadata, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Queries the value stream entries for specified logged property value along with filter and sort criteria and normalizes the data set to display result for a given time range.
- Parameters:
propertyNames
- Property names - INFOTABLEmaxItems
- Maximum number of items to return - NUMBERstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANfillOption
- Defines the value to report for time intervals with no data - STRINGreturnedMetadata
- Defines what extra columns will be returned in addition to the Property name, timestamp, and value. - STRINGquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE
- Throws:
Exception
- If an error occurs
-
QueryIntegerPropertyHistory
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryIntegerPropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryIntegerPropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryIntegerPropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:IntegerValueStream}
- Throws:
Exception
- If an error occurs
-
QueryLongPropertyHistory
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryLongPropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryLongPropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryLongPropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:LongValueStream}
- Throws:
Exception
- If an error occurs
-
QueryNumberPropertyHistory
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryNumberPropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryNumberPropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryNumberPropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:NumberValueStream}
- Throws:
Exception
- If an error occurs
-
QueryBooleanPropertyHistory
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryBooleanPropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryBooleanPropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryBooleanPropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:BooleanValueStream}
- Throws:
Exception
- If an error occurs
-
QueryDateTimePropertyHistory
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryDateTimePropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryDateTimePropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryDateTimePropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:DateTimeValueStream}
- Throws:
Exception
- If an error occurs
-
QueryInfoTablePropertyHistory
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryInfoTablePropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query, Boolean flatten) throws Exception - Throws:
Exception
- If an error occurs
-
QueryInfoTablePropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryInfoTablePropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query, Boolean flatten) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERYflatten
- Flatten the result - BOOLEAN- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:InfoTableValueStream}
- Throws:
Exception
- If an error occurs
-
QueryLocationPropertyHistory
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryLocationPropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryLocationPropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryLocationPropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:LocationValueStream}
- Throws:
Exception
- If an error occurs
-
QueryStringPropertyHistory
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryStringPropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryStringPropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryStringPropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:StringValueStream}
- Throws:
Exception
- If an error occurs
-
QueryVec2PropertyHistory
@ThingworxExtensionApiMethod(since={7,1}) public InfoTable QueryVec2PropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryVec2PropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryVec2PropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:Vec2DataShape}
- Throws:
Exception
- If an error occurs
-
QueryVec3PropertyHistory
@ThingworxExtensionApiMethod(since={7,1}) public InfoTable QueryVec3PropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryVec3PropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryVec3PropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:Vec3DataShape}
- Throws:
Exception
- If an error occurs
-
QueryVec4PropertyHistory
@ThingworxExtensionApiMethod(since={7,1}) public InfoTable QueryVec4PropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryVec4PropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryVec4PropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:Vec4DataShape}
- Throws:
Exception
- If an error occurs
-
QueryThingCodePropertyHistory
@ThingworxExtensionApiMethod(since={7,1}) public InfoTable QueryThingCodePropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryThingCodePropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryThingCodePropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:ThingCodeDataShape}
- Throws:
Exception
- If an error occurs
-
QueryImagePropertyHistory
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryImagePropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Throws:
Exception
- If an error occurs
-
QueryImagePropertyHistory
@ThingworxExtensionApiMethod(since={9,5}) public InfoTable QueryImagePropertyHistory(Double maxItems, String propertyName, org.joda.time.DateTime startDate, org.joda.time.DateTime endDate, String quality, Boolean oldestFirst, org.json.JSONObject query) throws Exception - Service Category:
- Queries
- Service Description:
- Query stream entries, along with filter and sort criteria.
- Parameters:
maxItems
- Maximum number of items to return - NUMBERpropertyName
- Property name - STRINGstartDate
- Start time - DATETIMEendDate
- End time - DATETIMEquality
- Filter Quality value - STRINGoldestFirst
- Search/sort from oldest to newest - BOOLEANquery
- Query definition - QUERY- Returns:
- result Table entries - INFOTABLE - Aspects {dataShape:ImageValueStream}
- Throws:
Exception
- If an error occurs
-
WritePropertiesToStream
@ThingworxExtensionApiMethod(since={6,6}) public void WritePropertiesToStream(String name, TagCollection tags) throws Exception - Service Category:
- Data
- Service Description:
- Store properties of this thing to a stream.
- Parameters:
name
- Stream name - THINGNAMEtags
- Tags - TAGS- Throws:
Exception
- If an error occurs
-
GetThingSummaryInformation
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetThingSummaryInformation() throws Exception- Service Category:
- Metadata
- Service Description:
- Get thing summary information.
- Returns:
- Summary Thing summary information - INFOTABLE - Aspects {dataShape:Thing}
- Throws:
Exception
- If an error occurs
-
GetAvatar
- Service Category:
- Metadata
- Service Description:
- Get avatar image.
- Specified by:
GetAvatar
in interfaceIAvatar
- Overrides:
GetAvatar
in classRootEntity
- Returns:
- Avatar Entity avatar - IMAGE
- Throws:
Exception
- If an error occurs
-
GetHomeMashup
- Service Category:
- Mashups
- Service Description:
- Get home mashup.
- Overrides:
GetHomeMashup
in classRootEntity
- Returns:
- HomeMashup Home mashup - MASHUPNAME
-
AddIntegerValueStreamEntry
@ThingworxExtensionApiMethod(since={6,6}) public void AddIntegerValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Integer value) throws Exception - Throws:
Exception
- If an error occurs
-
AddIntegerValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddIntegerValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Integer value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - INTEGERquality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
AddLongValueStreamEntry
@ThingworxExtensionApiMethod(since={6,6}) public void AddLongValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Long value) throws Exception - Throws:
Exception
- If an error occurs
-
AddLongValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddLongValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Long value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - LONGquality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
AddNumberValueStreamEntry
@ThingworxExtensionApiMethod(since={6,6}) public void AddNumberValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Double value) throws Exception - Throws:
Exception
- If an error occurs
-
AddNumberValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddNumberValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Double value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - NUMBERquality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
AddBooleanValueStreamEntry
@ThingworxExtensionApiMethod(since={6,6}) public void AddBooleanValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Boolean value) throws Exception - Throws:
Exception
- If an error occurs
-
AddBooleanValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddBooleanValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Boolean value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - BOOLEANquality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
AddLocationValueStreamEntry
@ThingworxExtensionApiMethod(since={6,6}) public void AddLocationValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Location value) throws Exception - Throws:
Exception
- If an error occurs
-
AddLocationValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddLocationValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Location value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - LOCATIONquality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
AddVec2ValueStreamEntry
@ThingworxExtensionApiMethod(since={7,1}) public void AddVec2ValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Vec2 value) throws Exception - Throws:
Exception
- If an error occurs
-
AddVec2ValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddVec2ValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Vec2 value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - VEC2quality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
AddVec3ValueStreamEntry
@ThingworxExtensionApiMethod(since={7,1}) public void AddVec3ValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Vec3 value) throws Exception - Throws:
Exception
- If an error occurs
-
AddVec3ValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddVec3ValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Vec3 value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - VEC3quality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
AddVec4ValueStreamEntry
@ThingworxExtensionApiMethod(since={7,1}) public void AddVec4ValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Vec4 value) throws Exception - Throws:
Exception
- If an error occurs
-
AddVec4ValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddVec4ValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, Vec4 value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - VEC4quality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
AddThingCodeValueStreamEntry
@ThingworxExtensionApiMethod(since={7,1}) public void AddThingCodeValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, ThingCode value) throws Exception - Throws:
Exception
- If an error occurs
-
AddThingCodeValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddThingCodeValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, ThingCode value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - THINGCODEquality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
AddStringValueStreamEntry
@ThingworxExtensionApiMethod(since={6,6}) public void AddStringValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, String value) throws Exception - Throws:
Exception
- If an error occurs
-
AddStringValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddStringValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, String value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - STRINGquality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
AddInfoTableValueStreamEntry
@ThingworxExtensionApiMethod(since={6,6}) public void AddInfoTableValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, InfoTable value) throws Exception - Throws:
Exception
- If an error occurs
-
AddInfoTableValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddInfoTableValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, InfoTable value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - INFOTABLEquality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
AddImageValueStreamEntry
@ThingworxExtensionApiMethod(since={6,6}) public void AddImageValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, byte[] value) throws Exception - Throws:
Exception
- If an error occurs
-
AddImageValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddImageValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, byte[] value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - IMAGEquality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
AddDateTimeValueStreamEntry
@ThingworxExtensionApiMethod(since={6,6}) public void AddDateTimeValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, org.joda.time.DateTime value) throws Exception - Throws:
Exception
- If an error occurs
-
AddDateTimeValueStreamEntry
@ThingworxExtensionApiMethod(since={9,5}) public void AddDateTimeValueStreamEntry(org.joda.time.DateTime timestamp, String propertyName, org.joda.time.DateTime value, String quality) throws Exception - Service Category:
- StreamEntries
- Service Description:
- Add a new stream entry.
- Parameters:
timestamp
- Event time (optional) - DATETIMEpropertyName
- Property name - STRINGvalue
- Data value - DATETIMEquality
- Quality value - STRING- Throws:
Exception
- If an error occurs
-
checkValueStream
- Throws:
Exception
- If an error occurs
-
checkPropertyName
@ThingworxExtensionApiMethod(since={6,6}) protected void checkPropertyName(String propertyName) throws Exception - Throws:
Exception
- If an error occurs
-
QueuePostCommitEvent
@ThingworxExtensionApiMethod(since={9,0}, canOverride=true, requiresSuper=true) public void QueuePostCommitEvent(String eventName) throws Exception - Service Category:
- Queueing
- Service Description:
- Queue events to be executed in a post commit action.
- Parameters:
eventName
- Event Name - STRING- Throws:
Exception
- If an error occurs
-
GetThingGroupDelegatedVisibilityPermissions
@ThingworxExtensionApiMethod(since={9,2}) public InfoTable GetThingGroupDelegatedVisibilityPermissions() throws Exception- Service Category:
- Service Description:
- Get the Visibility permissions from all the ThingGroups where this Thing is directly or indirectly a member.
- Returns:
- result Delegated Permissions - INFOTABLE - Aspects {dataShape:DelegatedVisibilityPermission}
- Throws:
Exception
- If an error occurs
-