Home Manual Reference Source
public class | source

IntentManager

Intent manager

Constructor Summary

Public Constructor
public

Method Summary

Public Methods
public

addAdhocAction(intentType: IntentType, actionMetadata: ActionMetadata): void

Registers an adhoc action

public

executeIntent(intentType: IntentType, options: Object): Promise<Object>

Executes an intent

public

intentIsDefined(intentType: IntentType): Promise<bool>

Determines whether an intent is defined for an intent manager

Public Constructors

public constructor source

Public Methods

public addAdhocAction(intentType: IntentType, actionMetadata: ActionMetadata): void source

Registers an adhoc action

Params:

NameTypeAttributeDescription
intentType IntentType

intent type

actionMetadata ActionMetadata

the metadata of the action implementing the intent

Return:

void

public executeIntent(intentType: IntentType, options: Object): Promise<Object> source

Executes an intent

Params:

NameTypeAttributeDescription
intentType IntentType

intent type

options Object

the input options for a given intent

Return:

Promise<Object>

Promise that resolves to a return object for a given intent

public intentIsDefined(intentType: IntentType): Promise<bool> source

Determines whether an intent is defined for an intent manager

Params:

NameTypeAttributeDescription
intentType IntentType

intent type

Return:

Promise<bool>

Promise that resolves to true (intent is defined) or false (inten is not defined)