UNPKG

@iterable/react-native-sdk

Version:
40 lines (36 loc) 1.04 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.IterableActionContext = void 0; var _IterableAction = require("./IterableAction.js"); /** * Information related to an Iterable action. */ class IterableActionContext { /** * The action associated with the context. */ /** * The origin of the action. In other words, where was the action triggered? */ /** * Creates an instance of IterableActionContext. */ constructor(action, source) { this.action = action; this.source = source; } /** * Creates an instance of `IterableActionContext` from a dictionary object. * * @returns A new instance of `IterableActionContext` with the provided properties. */ static fromDict(dict) { const action = _IterableAction.IterableAction.fromDict(dict.action); const source = dict.source; return new IterableActionContext(action, source); } } exports.IterableActionContext = IterableActionContext; //# sourceMappingURL=IterableActionContext.js.map