import { NodeDefinition, NodeLike, StatelessGraphNode, StatelessNodeDefinition, StatelessNodeType } from '../../types/graph'; /** * An instance of the [[parseInt]] node. * See the [[parseInt]] documentation to find out more. */ export interface ParseIntNode extends StatelessGraphNode<'parse-int', ParseIntNodeProperties> { } /** * A definition of the [[parseInt]] node. * See the [[parseInt]] documentation to find out more. */ export interface ParseIntNodeDefinition extends StatelessNodeDefinition<'parse-int', ParseIntNodeProperties> { } export interface ParseIntNodeProperties { radix: NodeDefinition; subject: NodeDefinition; } /** * The implementation of the [[parseInt]] node. * See the [[parseInt]] documentation to learn more. */ export declare const ParseIntNodeType: StatelessNodeType<'parse-int', ParseIntNodeProperties>; /** * Creates a new instance of a [[parseInt]] node, which is used to convert values of a [[value]] to an integer. * * * @example **Convert string to an integer** * ```js * import muster, { parseInt, ref } from '@dws/muster'; * * const app = muster({ * one: '1', * two: 2, * }); * * const one = await app.resolve(parseInt(ref('one'))); * // one === 1 * * const two = await app.resolve(parseInt(ref('two'))); * // two === 2 * * const three = await app.resolve(parseInt('3')); * // three === 3 * ``` * This example shows how to use the [[parseInt]] to convert a value of a [[value]] * to an integer. */ export declare function parseInt(subject: NodeLike, radix?: NodeLike): ParseIntNodeDefinition; export declare function isParseIntNodeDefinition(value: NodeDefinition): value is ParseIntNodeDefinition;