UNPKG

react-native-efilli-sdk

Version:
32 lines (31 loc) 1.07 kB
import { Categories } from './Categories'; import { ConsentAction } from '../enums/ConsentAction'; /** * ConsentResult model representing the outcome of a consent decision */ export declare class ConsentResult { /** The action taken (from ConsentAction enum) */ action: ConsentAction; /** The consent categories selections */ data: Categories | null; /** * Create a ConsentResult instance * @param action - The action taken (from ConsentAction enum) * @param data - The consent categories selections */ constructor(action: ConsentAction, data?: Categories | null); /** * Create a ConsentResult instance from a plain object or JSON string * @param data - Plain object or JSON string * @returns New ConsentResult instance or null if invalid */ static fromJSON(data: object | string): ConsentResult | null; /** * Convert to a plain object * @returns Plain object representation */ toJSON(): { action: string; data: Record<string, boolean> | null; }; }