Do more. Code less. Free software for GPU computing.
<scroll to top>
Functions

Licensing

Device Pointer Interface

Checkout or query the availability of features, and load license files. More...

Functions

void af_license_addsource (const char *file)
 Specify location of license file.
const char * af_license_getsource (int feature)
 Query which license source provides feature.
bool af_license_checkout (int feature)
 Attempt to checkout (use) a feature.
bool af_license_query (int feature)
 Test if a feature is available, but do not check it out.
int af_license_expires (int feature)
 How many days until specified feature expires.

Detailed Description

Checkout or query the availability of features, and load license files.


Function Documentation

void af_license_addsource ( const char *  file)

Specify location of license file.

By default, the current directory is searched for a file named arrayfire.lic and then home directory is searched for a file named .arrayfire.lic (or arrayfire.lic on Windows).

   af_license_addsource("/opt/licenses/arrayfire.lic");
Parameters:
[in]fileThe filename to search for a license.
const char* af_license_getsource ( int  feature)

Query which license source provides feature.

Parameters:
[in]featureFeature of interest
Returns:
Source file (network address). Do not free.
   printf("source: %s\n", af_license_getsource(4));
bool af_license_checkout ( int  feature)

Attempt to checkout (use) a feature.

Returns:
true if feature was successfully checked out, false if failure and see af_errno().
bool af_license_query ( int  feature)

Test if a feature is available, but do not check it out.

Returns:
true if feature is available, otherwise false.
int af_license_expires ( int  feature)

How many days until specified feature expires.

Returns:
Days until feature expires. INT_MAX if feature does not expire. Negative if feature not available.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines