JS_SetRegExpInput

Set the pending RegExp input.

Syntax

bool
JS_SetRegExpInput(JSContext *cx, JS::HandleObject obj, JS::HandleString input,
                  bool multiline);
Name Type Description
cx JSContext *

The context. Requires request. In a JS_THREADSAFE build, the caller must be in a request on this JSContext.

obj JS::HandleObject A pointer to a global object.
input JS::HandleString A pointer to the input string.
multiline bool true if input is multiline.

Description

JS_SetRegExpInput sets the pending input string of the built-in RegExp object to the specified input string. The JSREG_MULTILINE is set to multiline parameter, and other flags are all reset.

On successful, JS_SetRegExpInput returns true, otherwise returns false.

See Also

Document Tags and Contributors

 Contributors to this page: kscarfone, arai
 Last updated by: kscarfone,