import { NodeDefinition, NodeLike, StatelessGraphNode, StatelessNodeDefinition, StatelessNodeType } from '../../types/graph'; /** * An instance of the [[toString]] node. * See the [[toString]] documentation to find out more. */ export interface ToStringNode extends StatelessGraphNode<'to-string', ToStringNodeProperties> { } /** * A definition of the [[toString]] node. * See the [[toString]] documentation to find out more. */ export interface ToStringNodeDefinition extends StatelessNodeDefinition<'to-string', ToStringNodeProperties> { } export interface ToStringNodeProperties { subject: NodeDefinition; } /** * The implementation of the [[toString]] node. * See the [[toString]] documentation to learn more. */ export declare const ToStringNodeType: StatelessNodeType<'to-string', ToStringNodeProperties>; /** * Creates a new instance of a [[toString]] node, which is used when converting a any type value to a stringified version of the * value. It uses the `toString` helper from lodash to do the conversion. The node expects the * subject to be a [[value]] containing a string value. * * * @example **Convert to string** * ```js * import muster, { toString } from '@dws/muster'; * * const app = muster({}); * * await app.resolve(toString('Hello world')); * // === 'Hello world' * * await app.resolve(toString(123)); * // === '123' * * await app.resolve(toString(true)); * // === 'true' * * await app.resolve(toString({ hello: 'world'})); * // === '[object Object]' * ``` */ export declare function toString(subject: NodeLike): ToStringNodeDefinition; export declare function isToStringNodeDefinition(value: NodeDefinition): value is ToStringNodeDefinition;