ELinks 0.18.0
domparser.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "elinks.h"
#include "document/libdom/doc.h"
#include "js/ecmascript.h"
#include "js/libdom/dom.h"
#include "js/quickjs.h"
#include "js/quickjs/document.h"
#include "js/quickjs/domparser.h"
#include "intl/charsets.h"
#include "terminal/event.h"
Include dependency graph for domparser.c:

Macros

#define countof(x)   (sizeof(x) / sizeof((x)[0]))
 

Functions

static JSValue js_domparser_parseFromString (JSContext *ctx, JSValueConst this_val, int argc, JSValueConst *argv)
 
static JSValue js_domparser_constructor (JSContext *ctx, JSValueConst new_target, int argc, JSValueConst *argv)
 
static void JS_NewGlobalCConstructor2 (JSContext *ctx, JSValue func_obj, const char *name, JSValueConst proto)
 
static JSValueConst JS_NewGlobalCConstructor (JSContext *ctx, const char *name, JSCFunction *func, int length, JSValueConst proto)
 
int js_domparser_init (JSContext *ctx)
 

Variables

JSClassID js_domparser_class_id
 
static JSClassDef js_domparser_class
 
static const JSCFunctionListEntry js_domparser_proto_funcs []
 

Macro Definition Documentation

◆ countof

#define countof ( x)    (sizeof(x) / sizeof((x)[0]))

Function Documentation

◆ js_domparser_constructor()

static JSValue js_domparser_constructor ( JSContext * ctx,
JSValueConst new_target,
int argc,
JSValueConst * argv )
static

◆ js_domparser_init()

int js_domparser_init ( JSContext * ctx)

◆ js_domparser_parseFromString()

static JSValue js_domparser_parseFromString ( JSContext * ctx,
JSValueConst this_val,
int argc,
JSValueConst * argv )
static

◆ JS_NewGlobalCConstructor()

static JSValueConst JS_NewGlobalCConstructor ( JSContext * ctx,
const char * name,
JSCFunction * func,
int length,
JSValueConst proto )
static

◆ JS_NewGlobalCConstructor2()

static void JS_NewGlobalCConstructor2 ( JSContext * ctx,
JSValue func_obj,
const char * name,
JSValueConst proto )
static

Variable Documentation

◆ js_domparser_class

JSClassDef js_domparser_class
static
Initial value:
= {
"DOMParser",
}

◆ js_domparser_class_id

JSClassID js_domparser_class_id

◆ js_domparser_proto_funcs

const JSCFunctionListEntry js_domparser_proto_funcs[]
static
Initial value:
= {
JS_CFUNC_DEF("parseFromString", 2, js_domparser_parseFromString),
}
static JSValue js_domparser_parseFromString(JSContext *ctx, JSValueConst this_val, int argc, JSValueConst *argv)
Definition domparser.c:37