Custom Object Overview

A custom object provides a shortcut for customizing rules and actions for your environment. Based on the Groovy scripting language (1.8.2) and capable of using the Axeda® Platform SDK and Web Services, the custom object feature provides a simple way to implement custom Java code for the Axeda® Platform.

The custom source code for a custom object runs inside an automatically created object of the correct type. For example, if the custom object type is Alarm Rule, then a simple class that adheres to the interface is created automatically, similar to the following:

public class CustomObjectAlarmRule implements AlarmRule

{

public boolean evaluate(RuleContext context, Alarm alarm)

{

//Run custom object source code here

}

}

The custom object's source code runs in the evaluate method for custom rules and within the execute method for custom actions. Since the Axeda Platform provides the shell of the code, custom objects can just specify a code fragment that you are interested in instead of requiring you to adhere to an interface or leaving you open to coding errors. Several variables are ready for use in this code fragment. In particular, each of the interfaces for alarm rules, event rules, data rules, registration rules, and actions have method parameters that are available to your custom objects. In addition, you can set up a list of user input parameters for your custom objects. These parameters are configured when setting up the Rule or Action.

For M2M devices that use Shoulder Tap messaging, you can configure custom objects of type Shoulder Tap to use as the Transport for the Shoulder Tap delivery method (configured in a Model Profile for assets).

The Generic Interceptor for Axeda IDM Agents (referred to as IDM Agent Web Service Extension) allows you to add to request messages coming in from IDM agents before they are processed by the Axeda Platform, while the messages are being processed by the IDM Web Service, and to add to the response to be sent back to the IDM agent. You first create a custom object (Groovy script) to perform the desired action on the request or response message. Then you configure an IDM Web Service Extension and specify the name of the custom object. For more information on configuring IDM Web Service Extensions, refer to Enter the details for IDM Web Service Extension.

To create a custom object that will be rendered in the Asset dashboard, use the type Extended UI Module

For information about the context in which custom objects are run from expression rules or Web services, refer to Context for Running Custom Objects from Expression Rules or Web Services. For other links to information about custom objects, expression rules, and extended UI modules, refer to Developing Groovy Scripts for the Axeda Platform

Note: Custom objects rendered in Extended UI Modules will run in context of the user logged into the Axeda Applications, and will use the data for the asset shown in the related Asset dashboard. For example, if UserA is logged into the applications and viewing the Asset dashboard for Asset123, then the content shown in any Extended UI Modules defined in that asset dashboard is specific to Asset123, and constrained by the permissions set for that user.

For information about security for custom objects, refer to Security for Objects in Axeda® Connected Product Management Applications and for information about security for these objects when Delegated Administration is enabled, refer to Security for Objects in Delegated Administration Units.

In a Platform where Delegated Administration is enabled, the names of custom objects may contain prefixes. For details, refer to Names of Objects in DA Units.