skip to main content
Guide to Creating Corticon Extensions : Code conventions : Imports and interfaces used in extensions
 

Try Corticon Now

Imports and interfaces used in extensions

Annotations

Extended Operators - Extended operators load four annotation types:
import com.corticon.services.extensions.ArgumentName;
import com.corticon.services.extensions.Description;
import com.corticon.services.extensions.OperatorFolder;
import com.corticon.services.extensions.TopLevelFolder;
Service Callouts – Service callouts load one annotation type:
import com.corticon.services.extensions.Description;

Interfaces

Extended Operators – The interfaces added are those required for the data types used in the extended operator class, selected from the following:
import com.corticon.services.extensions.ICcCollectionExtension;
import com.corticon.services.extensions.ICcDateTimeExtension;
import com.corticon.services.extensions.ICcDecimalExtension;
import com.corticon.services.extensions.ICcIntegerExtension;
import com.corticon.services.extensions.ICcSequenceExtension;
import com.corticon.services.extensions.ICcStandAloneExtension;
import com.corticon.services.extensions.ICcStringExtension;
Note: While extended operators are limited to returning a value, the standalone extended operator type can access the interfaces for ICcDataObject:
import com.corticon.services.extensions.ICcStandAloneExtension;
import com.corticon.services.dataobject.ICcDataObject;
import com.corticon.services.dataobject.ICcDataObjectManager;
Note: When these interfaces are loaded, extended standalone operator methods can define ICcDataObjectManger as their first parameter. This provides flexibility in integrating Corticon with databases and other external services to perform complex actions, such as retrieving a set of records from a web service, and then adding them as associations on an entity. The ICcDataObjectManager parameter is not allowed in rule syntax.
Service Callouts – A service callout adds the following interface:
import com.corticon.services.extensions.ICcServiceCalloutExtension;

Extended operator data type mappings

The mapping of parameter and return types for Extended Operators are as follows:
Java Type
Corticon Type
java.math.BigInteger
Integer
java.math.BigDecimal
Decimal
java.lang.Boolean
Boolean
java.util.Date
Date, Time or DateTime
java.lang.String
String