TIBCO Spotfire® C# Extensions Overview
The TIBCO Spotfire® platform can be extended with custom capabilities by adding Spotfire extensions. The Spotfire API provides a number of different types of extensions such as tools, UI panels, visualizations, data sources, data transformations and much more. A Spotfire extension is the smallest functional unit added to the platform. It is developed in Microsoft Visual Studio® and is included in a Spotfire add-in, enabling versioning, licensing, deployment and loading.
This article describes the different extension types and the key concepts needed when you develop Spotfire extensions.
- How to setup the development environment and to configure, run and deploy extensions
- How to choose between using IronPython scripting and creating a C# Extension when developing for TIBCO Spotfire®
- TIBCO Spotfire® Developer Documentation
- The latest version of the Spotfire Analyst API Refence documentation can be accessed here:
- API examples - C#
- API examples - IronPython
This section gives an overview of the different extension types available in the Spotfire platform.
A custom tool is a Spotfire extension type which is used to perform an action in a given context. The context may for example be the Spotfire application itself, the document, or a particular visualization type. Two special kinds of tools are export tools and share tools.
A custom panel is a general-purpose UI components in Spotfire that can be used to visualize contextual information, adding controls or other domain specific functionality.
The set of Spotfire visualizations can be extended. Custom visualizations that have been deployed in the Spotfire environment appear in the same places and behave in the same way as Spotfire visualizations.
Custom Value Renderer
Custom value renderers are used to render values in table visualization columns. The most common scenario is to turn data values into images, which are rendered in the table cells.
- CustomValueRenderer class
- SDK example: SpotfireDeveloper.CustomValueRendererExample
Custom Data Source
A custom data source is used to import data from any external data source into Spotfire’s in-memory data engine.
Custom Data Function
A data function is like a swiss-army-knife component when building applications in Spotfire. Data functions are similar to data sources, but are able to compute over multiple inputs from the document and output data to multiple places in the document.
Custom Data Transformation
The transformations framework adds a layer between data reading and the creating of a data table, providing the means to modify the data before it is imported. A data transformation applies a rule or a function to the retrieved data to prepare it for analysis.
Custom Data Writer
A Data Writer exports data to a custom file format.
- CustomDataWriter class
- SDK example: SpotfireDeveloper.CustomDataWriterExample
Custom Expression Functions
With custom expression functions, it is possible to extend the expression language used in custom expressions and calculated columns. A custom expression function is ether row-based, column-based or an aggregation method.
- CustomRowMethod class
- CustomColumnMethod class
- CustomAggregationMethod class
- SDK example: SpotfireDeveloper.CalculationMethodExample
Note: it is possible to call TIBCO Enterprise Runtime for R directly from the Spotfire Expression Language, without having to create a custom expression function or employ data functions The simplest way to enhance your analysis with R scripts.
Custom Fitting Models
Curve fitting is the process of calculating values from visualization coordinates and input parameters, to draw reference curves and points.
- CustomFittingModel class
- SDK example: SpotfireDeveloper.CustomFittingModelExample
Custom Virtual Column
Creates a new column based on one or more existing columns plus Document Properties.
Preferences Objects, also known as Configuration Sets, are collections of application attributes that can be shared by users and groups of users.
- CustomPreference class
- SDK example: SpotfireDeveloper.PreferenceObjectsExampl
With a Custom License, custom components can be enabled/disabled from the Spotfire Licensing dialog. Read more in the Licensiing Extensions section below.
Custom Nodes allows items to be added to the Spotfire Document Model and be serialized into the DXP file.
Custom Application Event Handler
A Custom Application Event Handler can monitor and react to application events.
The Add-in Framework
A Spotfire extension is included in a Spotfire add-in, implemented as a C# project in Visual Studio®. A compiled project can be packaged into a Spotfire package for distribution and deployment to a Spotfire server. Learn more.
A Spotfire license controls access to a specific extension. Learn more.
32-bit and 64-bit Platforms
64-bit (x64) platform, as opposed to 32-bit (x86), is considered the default platform for TIBCO Spotfire. If the custom extension uses a third party native 32-bit DLL to run on a 64-bit platform, the 32-bit DLL must be executed in a separate 32-bit process. Learn more.
Document Model Framework
When doing more complex extensions, including custom document nodes, properties, transactions, events and more, it is important to understand the Document Model Framework which provides the building blocks of a Spotfire document in a running instance of Spotfire. Learn more.
Data Table Source View
The Data Table Source View API lets you read information on the different operations and transformations that are performed to construct a data table in an analysis, what is referred to as the data table source view. It is also possible to modify individual operations and transformations. Learn more.
Exporting and rendering visualizations
TIBCO Spotfire® 7.12 has new capabilites for exporting to PDF and rendering visualizations. Learn more.