Microsoft Information Protection (MIP) SDK for C++: Reference 1.15
Doxygen-generated documentation for MIP SDK written in C++
Loading...
Searching...
No Matches
ProtectionProfile Class Referenceabstract

ProtectionProfile is the root class for performing protection operations. More...

#include <src/api/mip/protection/protection_profile.h>

Classes

class  Observer
 Interface that receives notifications related to ProtectionProfile. More...
 
class  Settings
 Settings used by ProtectionProfile during its creation and throughout its lifetime. More...
 

Public Member Functions

virtual std::shared_ptr< ProtectionEngineAddEngine (const ProtectionEngine::Settings &settings)=0
 Add a new protection engine to the profile.
 
virtual std::shared_ptr< AsyncControlAddEngineAsync (const ProtectionEngine::Settings &settings, const std::shared_ptr< void > &context)=0
 Starts adding a new protection engine to the profile.
 
virtual void DeleteEngine (const std::string &engineId)=0
 Delete the protection engine with the given ID.
 
virtual std::shared_ptr< AsyncControlDeleteEngineAsync (const std::string &engineId, const std::shared_ptr< void > &context)=0
 Starts deleting the protection engine with the given ID.
 
virtual const SettingsGetSettings () const =0
 Gets settings used by ProtectionProfile during its initialization and throughout its lifetime.
 
virtual std::vector< std::string > ListEngines ()=0
 List engines.
 
virtual std::shared_ptr< AsyncControlListEnginesAsync (const std::shared_ptr< void > &context)=0
 Starts list engines operation.
 

Static Public Member Functions

static MIP_API std::shared_ptr< PublishingLicenseInfo > __CDECL GetPublishingLicenseInfo (const std::vector< uint8_t > &serializedPublishingLicense)
 Creates a holder for details of a Publishing License and can be used to create a Protection Handler.
 
static MIP_API std::shared_ptr< PublishingLicenseInfo > __CDECL GetPublishingLicenseInfo (const std::vector< uint8_t > &serializedPublishingLicense, const std::shared_ptr< MipContext > &mipContext)
 Creates a holder for details of a Publishing License and can be used to create a Protection Handler.
 
static MIP_API const char *__CDECL GetVersion ()
 Gets library version.
 
static MIP_API std::shared_ptr< ProtectionProfile > __CDECL Load (const Settings &settings)
 Loading a profile based on the provided settings.
 
static MIP_API std::shared_ptr< AsyncControl > __CDECL LoadAsync (const Settings &settings, const std::shared_ptr< void > &context)
 Starts loading a profile based on the provided settings.
 

Detailed Description

ProtectionProfile is the root class for performing protection operations.

Note
An application needs to create a ProtectionProfile before performing any protection operations

Definition at line 59 of file protection_profile.h.

Member Function Documentation

◆ AddEngine()

virtual std::shared_ptr< ProtectionEngine > ProtectionProfile::AddEngine ( const ProtectionEngine::Settings & settings)
pure virtual

Add a new protection engine to the profile.

Parameters
settingsthe mip::ProtectionEngine::Settings object that specifies the engine's settings.
Returns
Newly created ProtectionEngine

◆ AddEngineAsync()

virtual std::shared_ptr< AsyncControl > ProtectionProfile::AddEngineAsync ( const ProtectionEngine::Settings & settings,
const std::shared_ptr< void > & context )
pure virtual

Starts adding a new protection engine to the profile.

Parameters
settingsthe mip::ProtectionEngine::Settings object that specifies the engine's settings.
contextClient context that will be opaquely passed back to observers
Returns
Async control object.
Note
ProtectionProfile::Observer will be called upon success or failure.

◆ DeleteEngine()

virtual void ProtectionProfile::DeleteEngine ( const std::string & engineId)
pure virtual

Delete the protection engine with the given ID.

All data for the given engine will be deleted.

Parameters
idthe unique engine ID.

◆ DeleteEngineAsync()

virtual std::shared_ptr< AsyncControl > ProtectionProfile::DeleteEngineAsync ( const std::string & engineId,
const std::shared_ptr< void > & context )
pure virtual

Starts deleting the protection engine with the given ID.

All data for the given engine will be deleted.

Parameters
idthe unique engine ID.
contextClient context that will be opaquely passed back to observers
Returns
Async control object.
Note
ProtectionProfile::Observer will be called upon success or failure.

◆ GetPublishingLicenseInfo() [1/2]

static MIP_API std::shared_ptr< PublishingLicenseInfo > __CDECL ProtectionProfile::GetPublishingLicenseInfo ( const std::vector< uint8_t > & serializedPublishingLicense)
static

Creates a holder for details of a Publishing License and can be used to create a Protection Handler.

Parameters
serializedPublishingLicensethe serialized publishing license.
Returns
a holder for details of a Publishing License
Note
The returned PublishingLicenseInfo is parsed

◆ GetPublishingLicenseInfo() [2/2]

static MIP_API std::shared_ptr< PublishingLicenseInfo > __CDECL ProtectionProfile::GetPublishingLicenseInfo ( const std::vector< uint8_t > & serializedPublishingLicense,
const std::shared_ptr< MipContext > & mipContext )
static

Creates a holder for details of a Publishing License and can be used to create a Protection Handler.

Allows delegate overrides.

Parameters
serializedPublishingLicensethe serialized publishing license.
mipContexta MIP context containing delegate overrides.
Returns
a holder for details of a Publishing License
Note
The returned PublishingLicenseInfo is parsed

◆ GetSettings()

virtual const Settings & ProtectionProfile::GetSettings ( ) const
pure virtual

Gets settings used by ProtectionProfile during its initialization and throughout its lifetime.

Returns
Settings used by ProtectionProfile during its initialization and throughout its lifetime

◆ GetVersion()

static MIP_API const char *__CDECL ProtectionProfile::GetVersion ( )
static

Gets library version.

Returns
Library version

◆ ListEngines()

virtual std::vector< std::string > ProtectionProfile::ListEngines ( )
pure virtual

List engines.

Returns
Cached engine IDs

◆ ListEnginesAsync()

virtual std::shared_ptr< AsyncControl > ProtectionProfile::ListEnginesAsync ( const std::shared_ptr< void > & context)
pure virtual

Starts list engines operation.

Parameters
contextClient context that will be opaquely passed back to observers
Returns
Async control object.
Note
ProtectionProfile::Observer will be called upon success or failure.

◆ Load()

static MIP_API std::shared_ptr< ProtectionProfile > __CDECL ProtectionProfile::Load ( const Settings & settings)
static

Loading a profile based on the provided settings.

Parameters
settingsSettings used by ProtectionProfile during its initialization and throughout its lifetime
Returns
Newly created profile

◆ LoadAsync()

static MIP_API std::shared_ptr< AsyncControl > __CDECL ProtectionProfile::LoadAsync ( const Settings & settings,
const std::shared_ptr< void > & context )
static

Starts loading a profile based on the provided settings.

Parameters
settingsSettings used by ProtectionProfile during its initialization and throughout its lifetime
contextThis same context will be forwarded to ProtectionProfile::Observer::OnLoadSuccess or ProtectionProfile::Observer::OnLoadFailure as-is.
Returns
Async control object.
Note
ProtectionProfile::Observer will be called upon success or failure.

The documentation for this class was generated from the following file: