Prev Next

Writing a Custom Integration Plugin

We live in a highly connected world, and while there is a formidable list of out-of-the-box integrations provided with the Pro Cloud Server, custom (proprietary) integrations can be created with any product that has a standard web service interface.  This facility will both open up the contents of the Enterprise Architect repository to an external tool and also make the information in the external tool available within Enterprise Architect. For example a Project Management tool may define work pages that would be useful to visualize in Enterprise Architect, or an automated testing tool could define test cases and test procedures that could be related to implementation and specification elements in Enterprise Architect. This will require some technical expertise to create an integration using one of a number of programming languages such as C++ or C# , but this only needs to be done once and can be used across any number of repositories.

The Pro Cloud Server and Enterprise Architect will do the heavy lifting, and there is no need for an administrator to change any of the base security settings for the Pro Cloud Server as the new integration will operate through the existing Ports and firewalls. There is also no need for the developer to write http listening code, allowing them to focus on determining and configuring the RESTful API calls to pass the external items' information into and out of the server.

To write your own Custom Integration Plug-in you can either start from scratch or make a copy of one of the examples that is installed with Pro Cloud Server, and modify it. The Plug-ins can be written in either C++ or C#.

The examples are written using Visual Studio 2017 but this is not a pre-requisite.

The Custom Integration Plug-in must implement the interface defined in the ISBPIIntegrationPlugin, which is included in ISBPIIntegrationPlugin.h (for C++) or ISBPIIntegrationPlugin.cs (for C#).

The general flow of the program is as follows:

  • The user will perform an action within Enterprise Architect that needs information from the Integration Plugin
  • The plugin will receive a call (or multiple calls) to the appropriate interface method
  • The plugin should parse the request and, if required, make its own request to the actual data provider
  • The plugin receives the result from the actual provider, and parses the data
  • The plugin set the response to Enterprise Architect via the provided callback functions. This can either be the actual data requested or an error value
  • Enterprise Architect receives the callback data and displays it to the user

Fucntion/Class

Details

See also

Create Plugin

The plugin must implement the following export function:

extern "C" SBPI_API SBPI_INTEGRATION_PLUGIN CreatePlugin();

It must return a pointer to a class that implements the ISBPIIntegrationPlugin interface. The recommedned implementation is:

SBPI_INTEGRATION_PLUGIN CreatePlugin()

{

return new ExampleIntegrationPlugin;

}

The newly created ISBPIIntegrationPlugin can be deleted when it receives ISBPIIntegrationPlugin ::Release method.

ISBPIIntegrationPlugin interface

The dll plugin must implement all methods in theISBPIIntegrationPlugin interface.

ISBPIIntegrationPlugin interface