MineTrust Connector CPP SDK

MineTrustConnectorSDK.CPP

C++/CLI wrapper over the .NET application block which exposes the functionality of the MineTrust Connector SDK to native C++ applications.

Installation

The MineTrustConnector SDK for C++ is distributed by Datamine Software Ltd as a NuGet package. Please contact your local Datamine representative in order to obtain access.

Usage Examples

For usage examples of this package please see the examples page

Getting Started

This library is distributed as a NuGet package in the following locations:

  • StudioDataManagement artifact feed (please contact your local Datamine representative)
  • The datamine.local packages share (VPN required)

To use this library within a native C++ application, complete the following steps:

  1. Add a packages.config reference to the NuGet package as follows:

    <?xml version="1.0" encoding="utf-8"?>
    <packages>
    ...
    <package id="MineTrustConnectorSDK.CPP" version="1.0.0" targetFramework="Native" />
    </packages>
  2. Run a NuGet package restore on the project(s)
  3. Add a Project import target for the MineTrustConnectorSDK.CPP.targets file within the project(s) as follows:

    <?xml version="1.0" encoding="utf-8"?>
    <Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
    ...
    <Import Project="$(SolutionDir)packages\MineTrustConnectorSDK.CPP.1.0.0\build\native\MineTrustConnectorSDK.CPP.targets" />
    ...
    </Project>
  4. Include the CppCliInterop.h headers file in your source file(s):

    ...
    #include "CppCliInterop.h"
    ...
  5. The Interop library's classes and methods can now be called from the C++ application:
using namespace MineTrustConnector;
int main()
{
// Print the shell extension name
std::cout << CppCliInterop::GetShellExtensionName() << "\n";
// Find the server registration on the local machine
std::string serverUrl = CppCliInterop::ListServerURLs()[0];
std::cout << serverUrl << "\n";
// Query local packages that are Enabled
for (const CppCliInterop::PackageConfiguration& packageConfiguration : CppCliInterop::FindPackageConfigurations("$.Enabled", "True"))
{
std::cout << "Package is enabled: " << packageConfiguration.packageUID << "\n";
}
}
Definition CppCliInterop.h:26

Change Log

1.3.x

Introduction of PackageContentsHelper functionality Added ReceiveFiles and SendFiles APIs

1.2.x

Package configuration schema extended to support File arrays (breaking change to SDK class)

1.1.x

Includes functionality to query the local tag cache directly via the Connector SDK Additional dependency on SQLite in order to effect this

1.0.x

Baseline version of 'Production' MineTrust Connector SDK