import type { EventType, EventActionComponent, EventActionComponentWithFilters, FieldActionsComponents, FieldActionsComponentsWithFilters } from '../common-types';
export declare const isInternalField: (field: string) => boolean;
export declare const isTimeField: (field: string) => boolean;
/**
 * Converts a string with or without a wildcard asterisks to a regular expression and tests it against the second param.
 */
export declare const testStringWithWildCardString: (wildCardString: string, stringToTest: string) => boolean;
/**
 * Converts a string with wildcard asterisks to a regular expression.
 */
export declare const createWildcardRegex: (value: unknown) => RegExp | false;
/**
 * Check if subsetArray is a subset of supersetArray, where subsetArray may contain wildcard characters.
 * An empty array is always a subset of another array. Always compares string values of elements.
 *
 * This function is loosely based on isFuzzySubset() from splunkcore-web-ui,
 * and can potentially be optimized in future iterations.
 */
export declare const isFuzzySubset: (subsetArray?: any[], supersetArray?: any[]) => boolean;
/**
 * Determines if action should be shown, based on filtering of eventtypeValues.
 *
 * Behaviour is based on isRestrictedByEventtype() from splunkcore-web-ui:
 *      If eventtypeValues is empty or only contains *, action should always be shown,
 *      regardless of whether the 'eventtype' field exists in the event.
 *
 *      If 'eventtype' field exists in the event, action should only show
 *      if all eventtypeValues are a subset of eventtype's values.
 *      Note that eventtypeValues may contain wildcards.
 */
export declare const shouldShowActionAfterEventtypeFilter: (event: EventType, eventtypeValues?: string[]) => boolean;
/**
 * Determines if event action should be shown, based on filtering of fieldFilters.
 *
 * Behaviour is based on isRestrictedByPresenceOfAllFields() from splunkcore-web-ui:
 *      If fieldFilters is empty or only contains *, action should always be shown.
 *
 *      Otherwise, action should only show if all values in fieldFilters exist in the event.
 *      Note that fieldFilters may contain wildcards.
 */
export declare const shouldShowEventActionAfterFieldFilter: (event: EventType, fieldFilters?: string[]) => boolean;
/**
 * Checks if substring is a wildcard match of superstring. It is a match if:
 *  - substring equals * (which matches all values)
 *  - substring equals superstring
 *  - substring contains a wildcard asterisks, where the pattern matches superstring
 */
export declare const isWildcardMatch: (substring: string, superstring: string) => boolean;
/**
 * Creates a map of fields and their corresponding fieldActions, taking into account wildcard fields.
 * If a field does not have any fieldActions, it will not be added to the map.
 *
 * The `*` wildcard can be used to specify all fields that match a substring.
 * For example, fieldActions under `s*` would apply to `source`, `sourcetype`, and other fields starting with `s`.
 *
 * The `*` key can be used to indicate that all fields should receive the corresponding common fieldActions.
 */
export declare const getFieldActionsMap: (event: EventType, renderFieldActions?: FieldActionsComponentsWithFilters, fields?: string[]) => FieldActionsComponents;
/**
 * Filter event actions by eventtype and fields.
 */
export declare const getFilteredEventActionComponents: (event: EventType, renderEventActions?: EventActionComponentWithFilters[]) => EventActionComponent[];
/**
 * Generates a unique ID for an event. The ID is suitable
 * for use as a react "key" property.
 *
 * When possible, this function relies on the splunk_server,
 * index, and _cd fields of the event to generate repeatable
 * keys. If those fields are not available, a simple GUID is
 * generated. For that reason, these keys should be saved once
 * generated, and re-generation should be avoided.
 *
 * @param {Object} event The event for which to generate the key
 * @param {Number} index The event index
 * @param {Number} pageNumber The page number of the events if there is pagination
 * @returns {String} The ID
 */
export declare function generateKey(event: EventType, index?: number, pageNumber?: number): string;
/**
 * Return the raw string contents of the given event
 * @param {Object} event The event for which to generate the key
 * @returns {String} The raw event string
 */
export declare function rawString(event: EventType): string;
export declare function isJsonString(str: string): boolean;
