import Batcher from './batcher.js'; import ConstantProperties from './constantProperties.js'; export default class Events { private readonly constantProperties; private readonly getTimestamp; private readonly batcher; ownProperties: Record; constructor(constantProperties: ConstantProperties, getTimestamp: () => number, batcher: Batcher); /** * Add event to batch with option to send it immediately, * properties are optional and will not be saved as super prop * */ sendEvent: (eventName: string, properties?: Record, options?: { send_immediately: boolean; }) => void; /** * creates super property for all events * */ setProperty: (nameOrProperties: Record | string, value?: any) => void; /** * set super property only if it doesn't exist yet * */ setPropertiesOnce: (nameOrProperties: Record | string, value?: any) => void; /** * removes properties from list of super properties * */ unsetProperties: (properties: string | string[]) => void; /** clears all super properties */ reset: () => void; /** mixpanel compatibility */ register: (nameOrProperties: Record | string, value?: any) => void; register_once: (nameOrProperties: Record | string, value?: any) => void; unregister: (properties: string | string[]) => void; track: (eventName: string, properties?: Record, options?: { send_immediately: boolean; }) => void; }