Murl::App Functions

Application linking functions. More...

Collaboration diagram for Murl::App Functions:

Macros

#define MURL_CREATE_VALIDATE_RECEIPT(identifier, version)
 Create an instance of the app-store copy protection validation receipt. More...
 

Functions

IAppMurl::App::CreateApp ()
 Global function to create an application. More...
 
void Murl::App::DestroyApp (IApp *app)
 Global function to destroy an application. More...
 
Bool Murl::App::CheckValidateReceipt ()
 Validation of the app-store copy protection, currently supported on MacOSX only. More...
 

Detailed Description

Application linking functions.

Add an application to the engine at link time.

Macro Definition Documentation

◆ MURL_CREATE_VALIDATE_RECEIPT

#define MURL_CREATE_VALIDATE_RECEIPT (   identifier,
  version 
)

Create an instance of the app-store copy protection validation receipt.

If creating an instance it is required to have a valid receipt from the store, otherwise the constructor of this object terminates the application, e.g. on OSX the application must be started once from the finder to get the receipt. See example CheckValidateReceipt().

Parameters
identifierThe obfuscated application identifier.
versionThe obfuscated version identifier.

Function Documentation

◆ CreateApp()

IApp* Murl::App::CreateApp ( )

Global function to create an application.

The platform creates the application using this function.

Returns
The created application object.

◆ DestroyApp()

void Murl::App::DestroyApp ( IApp app)

Global function to destroy an application.

The platform destroys the application using this function.

Parameters
appThe application object to destroy.

◆ CheckValidateReceipt()

Bool Murl::App::CheckValidateReceipt ( )
inline

Validation of the app-store copy protection, currently supported on MacOSX only.

The application can validate the receipt at any time and should terminate if verification fails, e.g on app creation:

#include "murl_app.h"
#include "my_app.h"
#include "murl_app_validate_receipt.h"
using namespace Murl;
{
// Check the receipt and terminate if not successful
{
return 0;
}
// Create the application instance
return new MyApp;
}
{
delete app;
}
// Set the bundle identifier
MURL_OBFUSCATION_STRING(identifierObfuscation)
// Set the bundle version
MURL_OBFUSCATION_STRING(versionObfuscation)
MURL_OBFUSCATION_STRING_END;
// Create the receipt instance
MURL_CREATE_VALIDATE_RECEIPT(identifierObfuscation, versionObfuscation);
Returns
true if validation is successful.

References Murl::Platform::ValidateReceipt::IsValid().


Copyright © 2011-2018 Spraylight GmbH.