Caplin Trader 5.1.0

Class: module:ct-services/providers/OpenPermissionService

module:ct-services/providers/OpenPermissionService()

new module:ct-services/providers/OpenPermissionService()

Constructs a OpenPermissionService.

The OpenPermissionService returns ALL to all permission requests. You may need to provide permission sets so that that the OpenPermissionService can return lists when they are requested (for example, currency pairs). You can achieve this by using the module:ct-services/providers/OpenPermissionService#addPermissionSet method.

Methods

addPermissionSet(sNamespace, pPermissionSet)

Adds a permission set for the specified namespace, for example: oPermissionService.addPermissionSet("CurrencyPair", ["GBPUS", "GBPAUD"]);

Parameters:
Name Type Description
sNamespace String

The namespace for the permission set.

pPermissionSet Array

The list of permissions to return for the namespace.