nokolexbor 0.2.5 → 0.2.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/ext/nokolexbor/libxml/SAX2.h +4 -4
- data/ext/nokolexbor/libxml/chvalid.h +21 -21
- data/ext/nokolexbor/libxml/dict.h +13 -13
- data/ext/nokolexbor/libxml/globals.h +202 -202
- data/ext/nokolexbor/libxml/hash.h +25 -25
- data/ext/nokolexbor/libxml/parser.h +5 -5
- data/ext/nokolexbor/libxml/parserInternals.h +4 -4
- data/ext/nokolexbor/libxml/pattern.h +14 -14
- data/ext/nokolexbor/libxml/threads.h +15 -15
- data/ext/nokolexbor/libxml/tree.h +5 -5
- data/ext/nokolexbor/libxml/xmlerror.h +5 -5
- data/ext/nokolexbor/libxml/xmlmemory.h +16 -16
- data/ext/nokolexbor/libxml/xmlstring.h +30 -30
- data/ext/nokolexbor/libxml/xpath.h +43 -43
- data/ext/nokolexbor/libxml/xpathInternals.h +128 -128
- data/ext/nokolexbor/nl_node.c +5 -5
- data/ext/nokolexbor/nl_node_set.c +3 -3
- data/ext/nokolexbor/nl_xpath_context.c +16 -16
- data/ext/nokolexbor/private/buf.h +1 -1
- data/ext/nokolexbor/private/error.h +3 -3
- data/ext/nokolexbor/xml_SAX2.c +8 -8
- data/ext/nokolexbor/xml_buf.c +19 -19
- data/ext/nokolexbor/xml_chvalid.c +25 -25
- data/ext/nokolexbor/xml_dict.c +69 -69
- data/ext/nokolexbor/xml_encoding.c +2 -2
- data/ext/nokolexbor/xml_error.c +51 -51
- data/ext/nokolexbor/xml_globals.c +329 -329
- data/ext/nokolexbor/xml_hash.c +131 -131
- data/ext/nokolexbor/xml_memory.c +25 -25
- data/ext/nokolexbor/xml_parser.c +3 -3
- data/ext/nokolexbor/xml_parserInternals.c +15 -15
- data/ext/nokolexbor/xml_pattern.c +103 -103
- data/ext/nokolexbor/xml_string.c +93 -93
- data/ext/nokolexbor/xml_threads.c +61 -61
- data/ext/nokolexbor/xml_tree.c +12 -12
- data/ext/nokolexbor/xml_xpath.c +1194 -1203
- data/lib/nokolexbor/version.rb +1 -1
- metadata +2 -2
@@ -18,7 +18,7 @@ VALUE cNokolexborXpathSyntaxError;
|
|
18
18
|
static void
|
19
19
|
free_xml_xpath_context(xmlXPathContextPtr ctx)
|
20
20
|
{
|
21
|
-
|
21
|
+
nl_xmlXPathFreeContext(ctx);
|
22
22
|
}
|
23
23
|
|
24
24
|
/*
|
@@ -33,7 +33,7 @@ nl_xpath_context_register_ns(VALUE self, VALUE prefix, VALUE uri)
|
|
33
33
|
xmlXPathContextPtr ctx;
|
34
34
|
Data_Get_Struct(self, xmlXPathContext, ctx);
|
35
35
|
|
36
|
-
|
36
|
+
nl_xmlXPathRegisterNs(ctx,
|
37
37
|
(const xmlChar *)StringValueCStr(prefix),
|
38
38
|
(const xmlChar *)StringValueCStr(uri));
|
39
39
|
return self;
|
@@ -52,9 +52,9 @@ nl_xpath_context_register_variable(VALUE self, VALUE name, VALUE value)
|
|
52
52
|
xmlXPathObjectPtr xmlValue;
|
53
53
|
Data_Get_Struct(self, xmlXPathContext, ctx);
|
54
54
|
|
55
|
-
xmlValue =
|
55
|
+
xmlValue = nl_xmlXPathNewCString(StringValueCStr(value));
|
56
56
|
|
57
|
-
|
57
|
+
nl_xmlXPathRegisterVariable(ctx,
|
58
58
|
(const xmlChar *)StringValueCStr(name),
|
59
59
|
xmlValue);
|
60
60
|
|
@@ -74,7 +74,7 @@ xpath2ruby(xmlXPathObjectPtr c_xpath_object, xmlXPathContextPtr ctx, VALUE rb_do
|
|
74
74
|
{
|
75
75
|
case XPATH_STRING:
|
76
76
|
rb_retval = rb_utf8_str_new_cstr((const char *)c_xpath_object->stringval);
|
77
|
-
|
77
|
+
nl_xmlFree(c_xpath_object->stringval);
|
78
78
|
return rb_retval;
|
79
79
|
|
80
80
|
case XPATH_NODESET:
|
@@ -192,20 +192,20 @@ nl_xpath_context_evaluate(int argc, VALUE *argv, VALUE self)
|
|
192
192
|
// if (Qnil != xpath_handler) {
|
193
193
|
// /* FIXME: not sure if this is the correct place to shove private data. */
|
194
194
|
// ctx->userData = (void *)xpath_handler;
|
195
|
-
//
|
195
|
+
// nl_xmlXPathRegisterFuncLookup(ctx, handler_lookup, (void *)xpath_handler);
|
196
196
|
// }
|
197
197
|
|
198
|
-
|
199
|
-
|
198
|
+
nl_xmlSetStructuredErrorFunc((void *)errors, nl_xpath_error_array_pusher);
|
199
|
+
nl_xmlSetGenericErrorFunc((void *)errors, nl_xpath_generic_exception_pusher);
|
200
200
|
|
201
|
-
xpath =
|
201
|
+
xpath = nl_xmlXPathEvalExpression(query, ctx);
|
202
202
|
|
203
|
-
|
204
|
-
|
203
|
+
nl_xmlSetStructuredErrorFunc(NULL, NULL);
|
204
|
+
nl_xmlSetGenericErrorFunc(NULL, NULL);
|
205
205
|
|
206
206
|
if (xpath == NULL)
|
207
207
|
{
|
208
|
-
|
208
|
+
nl_xmlXPathFreeObject(xpath);
|
209
209
|
rb_exc_raise(rb_ary_entry(errors, 0));
|
210
210
|
}
|
211
211
|
|
@@ -215,7 +215,7 @@ nl_xpath_context_evaluate(int argc, VALUE *argv, VALUE self)
|
|
215
215
|
retval = rb_funcall(cNokolexborNodeSet, rb_intern("new"), 1, rb_ary_new());
|
216
216
|
}
|
217
217
|
|
218
|
-
|
218
|
+
nl_xmlXPathFreeObject(xpath);
|
219
219
|
|
220
220
|
return retval;
|
221
221
|
}
|
@@ -234,7 +234,7 @@ nl_xpath_context_new(VALUE klass, VALUE rb_node)
|
|
234
234
|
|
235
235
|
lxb_dom_node_t *node = nl_rb_node_unwrap(rb_node);
|
236
236
|
|
237
|
-
ctx =
|
237
|
+
ctx = nl_xmlXPathNewContext(node->owner_document);
|
238
238
|
ctx->node = node;
|
239
239
|
|
240
240
|
self = Data_Wrap_Struct(klass, 0, free_xml_xpath_context, ctx);
|
@@ -246,9 +246,9 @@ nl_xpath_context_new(VALUE klass, VALUE rb_node)
|
|
246
246
|
void Init_nl_xpath_context(void)
|
247
247
|
{
|
248
248
|
#ifndef NOKOLEXBOR_ASAN
|
249
|
-
|
249
|
+
nl_xmlMemSetup((xmlFreeFunc)ruby_xfree, (xmlMallocFunc)ruby_xmalloc, (xmlReallocFunc)ruby_xrealloc, ruby_strdup);
|
250
250
|
#else
|
251
|
-
|
251
|
+
nl_xmlMemSetup((xmlFreeFunc)free, (xmlMallocFunc)malloc, (xmlReallocFunc)realloc, strdup);
|
252
252
|
#endif
|
253
253
|
|
254
254
|
cNokolexborXpathContext = rb_define_class_under(mNokolexbor, "XPathContext", rb_cObject);
|
@@ -43,7 +43,7 @@ xmlBufIsEmpty(const xmlBufPtr buf);
|
|
43
43
|
XML_HIDDEN int
|
44
44
|
xmlBufAddLen(xmlBufPtr buf, size_t len);
|
45
45
|
|
46
|
-
/* const xmlChar *
|
46
|
+
/* const xmlChar * nl_xmlBufContent(const xmlBuf *buf); */
|
47
47
|
/* const xmlChar * xmlBufEnd(xmlBufPtr buf); */
|
48
48
|
|
49
49
|
XML_HIDDEN xmlChar *
|
@@ -5,17 +5,17 @@
|
|
5
5
|
#include "libxml/xmlversion.h"
|
6
6
|
|
7
7
|
XML_HIDDEN void
|
8
|
-
|
8
|
+
__nl_xmlRaiseError(xmlStructuredErrorFunc schannel,
|
9
9
|
xmlGenericErrorFunc channel, void *data, void *ctx,
|
10
10
|
void *nod, int domain, int code, xmlErrorLevel level,
|
11
11
|
const char *file, int line, const char *str1,
|
12
12
|
const char *str2, const char *str3, int int1, int col,
|
13
13
|
const char *msg, ...) LIBXML_ATTR_FORMAT(16,17);
|
14
14
|
XML_HIDDEN void
|
15
|
-
|
15
|
+
__nl_xmlSimpleError(int domain, int code, lxb_dom_node_t_ptr node,
|
16
16
|
const char *msg, const char *extra) LIBXML_ATTR_FORMAT(4,0);
|
17
17
|
XML_HIDDEN void
|
18
|
-
|
18
|
+
nl_xmlGenericErrorDefaultFunc(void *ctx, const char *msg,
|
19
19
|
...) LIBXML_ATTR_FORMAT(2,3);
|
20
20
|
|
21
21
|
#endif /* XML_ERROR_H_PRIVATE__ */
|
data/ext/nokolexbor/xml_SAX2.c
CHANGED
@@ -16,7 +16,7 @@
|
|
16
16
|
#include "libxml/globals.h"
|
17
17
|
|
18
18
|
/**
|
19
|
-
*
|
19
|
+
* nl_xmlSAX2GetPublicId:
|
20
20
|
* @ctx: the user data (XML parser context)
|
21
21
|
*
|
22
22
|
* Provides the public ID e.g. "-//SGMLSOURCE//DTD DEMO//EN"
|
@@ -24,14 +24,14 @@
|
|
24
24
|
* Returns a xmlChar *
|
25
25
|
*/
|
26
26
|
const xmlChar *
|
27
|
-
|
27
|
+
nl_xmlSAX2GetPublicId(void *ctx ATTRIBUTE_UNUSED)
|
28
28
|
{
|
29
29
|
/* xmlParserCtxtPtr ctxt = (xmlParserCtxtPtr) ctx; */
|
30
30
|
return(NULL);
|
31
31
|
}
|
32
32
|
|
33
33
|
/**
|
34
|
-
*
|
34
|
+
* nl_xmlSAX2GetSystemId:
|
35
35
|
* @ctx: the user data (XML parser context)
|
36
36
|
*
|
37
37
|
* Provides the system ID, basically URL or filename e.g.
|
@@ -40,7 +40,7 @@ xmlSAX2GetPublicId(void *ctx ATTRIBUTE_UNUSED)
|
|
40
40
|
* Returns a xmlChar *
|
41
41
|
*/
|
42
42
|
const xmlChar *
|
43
|
-
|
43
|
+
nl_xmlSAX2GetSystemId(void *ctx)
|
44
44
|
{
|
45
45
|
xmlParserCtxtPtr ctxt = (xmlParserCtxtPtr) ctx;
|
46
46
|
if ((ctx == NULL) || (ctxt->input == NULL)) return(NULL);
|
@@ -48,7 +48,7 @@ xmlSAX2GetSystemId(void *ctx)
|
|
48
48
|
}
|
49
49
|
|
50
50
|
/**
|
51
|
-
*
|
51
|
+
* nl_xmlSAX2GetLineNumber:
|
52
52
|
* @ctx: the user data (XML parser context)
|
53
53
|
*
|
54
54
|
* Provide the line number of the current parsing point.
|
@@ -56,7 +56,7 @@ xmlSAX2GetSystemId(void *ctx)
|
|
56
56
|
* Returns an int
|
57
57
|
*/
|
58
58
|
int
|
59
|
-
|
59
|
+
nl_xmlSAX2GetLineNumber(void *ctx)
|
60
60
|
{
|
61
61
|
xmlParserCtxtPtr ctxt = (xmlParserCtxtPtr) ctx;
|
62
62
|
if ((ctx == NULL) || (ctxt->input == NULL)) return(0);
|
@@ -64,7 +64,7 @@ xmlSAX2GetLineNumber(void *ctx)
|
|
64
64
|
}
|
65
65
|
|
66
66
|
/**
|
67
|
-
*
|
67
|
+
* nl_xmlSAX2GetColumnNumber:
|
68
68
|
* @ctx: the user data (XML parser context)
|
69
69
|
*
|
70
70
|
* Provide the column number of the current parsing point.
|
@@ -72,7 +72,7 @@ xmlSAX2GetLineNumber(void *ctx)
|
|
72
72
|
* Returns an int
|
73
73
|
*/
|
74
74
|
int
|
75
|
-
|
75
|
+
nl_xmlSAX2GetColumnNumber(void *ctx)
|
76
76
|
{
|
77
77
|
xmlParserCtxtPtr ctxt = (xmlParserCtxtPtr) ctx;
|
78
78
|
if ((ctx == NULL) || (ctxt->input == NULL)) return(0);
|
data/ext/nokolexbor/xml_buf.c
CHANGED
@@ -92,7 +92,7 @@ struct _xmlBuf {
|
|
92
92
|
static void
|
93
93
|
xmlBufMemoryError(xmlBufPtr buf, const char *extra)
|
94
94
|
{
|
95
|
-
|
95
|
+
__nl_xmlSimpleError(XML_FROM_BUFFER, XML_ERR_NO_MEMORY, NULL, NULL, extra);
|
96
96
|
if ((buf) && (buf->error == 0))
|
97
97
|
buf->error = XML_ERR_NO_MEMORY;
|
98
98
|
}
|
@@ -107,7 +107,7 @@ xmlBufPtr
|
|
107
107
|
xmlBufCreate(void) {
|
108
108
|
xmlBufPtr ret;
|
109
109
|
|
110
|
-
ret = (xmlBufPtr)
|
110
|
+
ret = (xmlBufPtr) nl_xmlMalloc(sizeof(xmlBuf));
|
111
111
|
if (ret == NULL) {
|
112
112
|
xmlBufMemoryError(NULL, "creating buffer");
|
113
113
|
return(NULL);
|
@@ -115,13 +115,13 @@ xmlBufCreate(void) {
|
|
115
115
|
ret->use = 0;
|
116
116
|
ret->error = 0;
|
117
117
|
ret->buffer = NULL;
|
118
|
-
ret->size =
|
118
|
+
ret->size = nl_xmlDefaultBufferSize;
|
119
119
|
UPDATE_COMPAT(ret);
|
120
|
-
ret->alloc =
|
121
|
-
ret->content = (xmlChar *)
|
120
|
+
ret->alloc = nl_xmlBufferAllocScheme;
|
121
|
+
ret->content = (xmlChar *) nl_xmlMallocAtomic(ret->size);
|
122
122
|
if (ret->content == NULL) {
|
123
123
|
xmlBufMemoryError(ret, "creating buffer");
|
124
|
-
|
124
|
+
nl_xmlFree(ret);
|
125
125
|
return(NULL);
|
126
126
|
}
|
127
127
|
ret->content[0] = 0;
|
@@ -140,7 +140,7 @@ void
|
|
140
140
|
xmlBufFree(xmlBufPtr buf) {
|
141
141
|
if (buf == NULL) {
|
142
142
|
#ifdef DEBUG_BUFFER
|
143
|
-
|
143
|
+
nl_xmlGenericError(nl_xmlGenericErrorContext,
|
144
144
|
"xmlBufFree: buf == NULL\n");
|
145
145
|
#endif
|
146
146
|
return;
|
@@ -148,15 +148,15 @@ xmlBufFree(xmlBufPtr buf) {
|
|
148
148
|
|
149
149
|
if ((buf->alloc == XML_BUFFER_ALLOC_IO) &&
|
150
150
|
(buf->contentIO != NULL)) {
|
151
|
-
|
151
|
+
nl_xmlFree(buf->contentIO);
|
152
152
|
} else if (buf->content != NULL) {
|
153
|
-
|
153
|
+
nl_xmlFree(buf->content);
|
154
154
|
}
|
155
|
-
|
155
|
+
nl_xmlFree(buf);
|
156
156
|
}
|
157
157
|
|
158
158
|
/**
|
159
|
-
*
|
159
|
+
* nl_xmlBufContent:
|
160
160
|
* @buf: the buffer
|
161
161
|
*
|
162
162
|
* Function to extract the content of a buffer
|
@@ -165,7 +165,7 @@ xmlBufFree(xmlBufPtr buf) {
|
|
165
165
|
*/
|
166
166
|
|
167
167
|
xmlChar *
|
168
|
-
|
168
|
+
nl_xmlBufContent(const xmlBuf *buf)
|
169
169
|
{
|
170
170
|
if ((!buf) || (buf->error))
|
171
171
|
return NULL;
|
@@ -258,7 +258,7 @@ xmlBufResize(xmlBufPtr buf, size_t size)
|
|
258
258
|
buf->content[buf->use] = 0;
|
259
259
|
buf->size += start_buf;
|
260
260
|
} else {
|
261
|
-
rebuf = (xmlChar *)
|
261
|
+
rebuf = (xmlChar *) nl_xmlRealloc(buf->contentIO, start_buf + newSize);
|
262
262
|
if (rebuf == NULL) {
|
263
263
|
xmlBufMemoryError(buf, "growing buffer");
|
264
264
|
return 0;
|
@@ -268,21 +268,21 @@ xmlBufResize(xmlBufPtr buf, size_t size)
|
|
268
268
|
}
|
269
269
|
} else {
|
270
270
|
if (buf->content == NULL) {
|
271
|
-
rebuf = (xmlChar *)
|
271
|
+
rebuf = (xmlChar *) nl_xmlMallocAtomic(newSize);
|
272
272
|
buf->use = 0;
|
273
273
|
rebuf[buf->use] = 0;
|
274
274
|
} else if (buf->size - buf->use < 100) {
|
275
|
-
rebuf = (xmlChar *)
|
275
|
+
rebuf = (xmlChar *) nl_xmlRealloc(buf->content, newSize);
|
276
276
|
} else {
|
277
277
|
/*
|
278
278
|
* if we are reallocating a buffer far from being full, it's
|
279
279
|
* better to make a new allocation and copy only the used range
|
280
280
|
* and free the old one.
|
281
281
|
*/
|
282
|
-
rebuf = (xmlChar *)
|
282
|
+
rebuf = (xmlChar *) nl_xmlMallocAtomic(newSize);
|
283
283
|
if (rebuf != NULL) {
|
284
284
|
memcpy(rebuf, buf->content, buf->use);
|
285
|
-
|
285
|
+
nl_xmlFree(buf->content);
|
286
286
|
rebuf[buf->use] = 0;
|
287
287
|
}
|
288
288
|
}
|
@@ -320,7 +320,7 @@ xmlBufAdd(xmlBufPtr buf, const xmlChar *str, int len) {
|
|
320
320
|
|
321
321
|
if (len < -1) {
|
322
322
|
#ifdef DEBUG_BUFFER
|
323
|
-
|
323
|
+
nl_xmlGenericError(nl_xmlGenericErrorContext,
|
324
324
|
"xmlBufAdd: len < 0\n");
|
325
325
|
#endif
|
326
326
|
return -1;
|
@@ -328,7 +328,7 @@ xmlBufAdd(xmlBufPtr buf, const xmlChar *str, int len) {
|
|
328
328
|
if (len == 0) return 0;
|
329
329
|
|
330
330
|
if (len < 0)
|
331
|
-
len =
|
331
|
+
len = nl_xmlStrlen(str);
|
332
332
|
|
333
333
|
if (len < 0) return -1;
|
334
334
|
if (len == 0) return 0;
|
@@ -22,7 +22,7 @@
|
|
22
22
|
* allowed.
|
23
23
|
*
|
24
24
|
*/
|
25
|
-
const unsigned char
|
25
|
+
const unsigned char nl_xmlIsPubidChar_tab[256] = {
|
26
26
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00,
|
27
27
|
0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
28
28
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x01,
|
@@ -96,13 +96,13 @@ static const xmlChSRange xmlIsBaseChar_srng[] = { {0x100, 0x131},
|
|
96
96
|
{0x1fd6, 0x1fdb}, {0x1fe0, 0x1fec}, {0x1ff2, 0x1ff4}, {0x1ff6, 0x1ffc},
|
97
97
|
{0x2126, 0x2126}, {0x212a, 0x212b}, {0x212e, 0x212e}, {0x2180, 0x2182},
|
98
98
|
{0x3041, 0x3094}, {0x30a1, 0x30fa}, {0x3105, 0x312c}, {0xac00, 0xd7a3}};
|
99
|
-
const xmlChRangeGroup
|
99
|
+
const xmlChRangeGroup nl_xmlIsBaseCharGroup =
|
100
100
|
{197, 0, xmlIsBaseChar_srng, (xmlChLRangePtr)0};
|
101
101
|
|
102
102
|
static const xmlChSRange xmlIsChar_srng[] = { {0x100, 0xd7ff},
|
103
103
|
{0xe000, 0xfffd}};
|
104
104
|
static const xmlChLRange xmlIsChar_lrng[] = { {0x10000, 0x10ffff}};
|
105
|
-
const xmlChRangeGroup
|
105
|
+
const xmlChRangeGroup nl_xmlIsCharGroup =
|
106
106
|
{2, 1, xmlIsChar_srng, xmlIsChar_lrng};
|
107
107
|
|
108
108
|
static const xmlChSRange xmlIsCombining_srng[] = { {0x300, 0x345},
|
@@ -130,7 +130,7 @@ static const xmlChSRange xmlIsCombining_srng[] = { {0x300, 0x345},
|
|
130
130
|
{0xf90, 0xf95}, {0xf97, 0xf97}, {0xf99, 0xfad}, {0xfb1, 0xfb7},
|
131
131
|
{0xfb9, 0xfb9}, {0x20d0, 0x20dc}, {0x20e1, 0x20e1}, {0x302a, 0x302f},
|
132
132
|
{0x3099, 0x3099}, {0x309a, 0x309a}};
|
133
|
-
const xmlChRangeGroup
|
133
|
+
const xmlChRangeGroup nl_xmlIsCombiningGroup =
|
134
134
|
{95, 0, xmlIsCombining_srng, (xmlChLRangePtr)0};
|
135
135
|
|
136
136
|
static const xmlChSRange xmlIsDigit_srng[] = { {0x660, 0x669},
|
@@ -138,24 +138,24 @@ static const xmlChSRange xmlIsDigit_srng[] = { {0x660, 0x669},
|
|
138
138
|
{0xae6, 0xaef}, {0xb66, 0xb6f}, {0xbe7, 0xbef}, {0xc66, 0xc6f},
|
139
139
|
{0xce6, 0xcef}, {0xd66, 0xd6f}, {0xe50, 0xe59}, {0xed0, 0xed9},
|
140
140
|
{0xf20, 0xf29}};
|
141
|
-
const xmlChRangeGroup
|
141
|
+
const xmlChRangeGroup nl_xmlIsDigitGroup =
|
142
142
|
{14, 0, xmlIsDigit_srng, (xmlChLRangePtr)0};
|
143
143
|
|
144
144
|
static const xmlChSRange xmlIsExtender_srng[] = { {0x2d0, 0x2d0},
|
145
145
|
{0x2d1, 0x2d1}, {0x387, 0x387}, {0x640, 0x640}, {0xe46, 0xe46},
|
146
146
|
{0xec6, 0xec6}, {0x3005, 0x3005}, {0x3031, 0x3035}, {0x309d, 0x309e},
|
147
147
|
{0x30fc, 0x30fe}};
|
148
|
-
const xmlChRangeGroup
|
148
|
+
const xmlChRangeGroup nl_xmlIsExtenderGroup =
|
149
149
|
{10, 0, xmlIsExtender_srng, (xmlChLRangePtr)0};
|
150
150
|
|
151
151
|
static const xmlChSRange xmlIsIdeographic_srng[] = { {0x3007, 0x3007},
|
152
152
|
{0x3021, 0x3029}, {0x4e00, 0x9fa5}};
|
153
|
-
const xmlChRangeGroup
|
153
|
+
const xmlChRangeGroup nl_xmlIsIdeographicGroup =
|
154
154
|
{3, 0, xmlIsIdeographic_srng, (xmlChLRangePtr)0};
|
155
155
|
|
156
156
|
|
157
157
|
/**
|
158
|
-
*
|
158
|
+
* nl_xmlCharInRange:
|
159
159
|
* @val: character to be validated
|
160
160
|
* @rptr: pointer to range to be used to validate
|
161
161
|
*
|
@@ -165,7 +165,7 @@ const xmlChRangeGroup xmlIsIdeographicGroup =
|
|
165
165
|
* Returns: true if character valid, false otherwise
|
166
166
|
*/
|
167
167
|
int
|
168
|
-
|
168
|
+
nl_xmlCharInRange (unsigned int val, const xmlChRangeGroup *rptr) {
|
169
169
|
int low, high, mid;
|
170
170
|
const xmlChSRange *sptr;
|
171
171
|
const xmlChLRange *lptr;
|
@@ -214,7 +214,7 @@ xmlCharInRange (unsigned int val, const xmlChRangeGroup *rptr) {
|
|
214
214
|
|
215
215
|
|
216
216
|
/**
|
217
|
-
*
|
217
|
+
* nl_xmlIsBaseChar:
|
218
218
|
* @ch: character to validate
|
219
219
|
*
|
220
220
|
* This function is DEPRECATED.
|
@@ -223,13 +223,13 @@ xmlCharInRange (unsigned int val, const xmlChRangeGroup *rptr) {
|
|
223
223
|
* Returns true if argument valid, false otherwise
|
224
224
|
*/
|
225
225
|
int
|
226
|
-
|
226
|
+
nl_xmlIsBaseChar(unsigned int ch) {
|
227
227
|
return(xmlIsBaseCharQ(ch));
|
228
228
|
}
|
229
229
|
|
230
230
|
|
231
231
|
/**
|
232
|
-
*
|
232
|
+
* nl_xmlIsBlank:
|
233
233
|
* @ch: character to validate
|
234
234
|
*
|
235
235
|
* This function is DEPRECATED.
|
@@ -238,13 +238,13 @@ xmlIsBaseChar(unsigned int ch) {
|
|
238
238
|
* Returns true if argument valid, false otherwise
|
239
239
|
*/
|
240
240
|
int
|
241
|
-
|
241
|
+
nl_xmlIsBlank(unsigned int ch) {
|
242
242
|
return(xmlIsBlankQ(ch));
|
243
243
|
}
|
244
244
|
|
245
245
|
|
246
246
|
/**
|
247
|
-
*
|
247
|
+
* nl_xmlIsChar:
|
248
248
|
* @ch: character to validate
|
249
249
|
*
|
250
250
|
* This function is DEPRECATED.
|
@@ -253,13 +253,13 @@ xmlIsBlank(unsigned int ch) {
|
|
253
253
|
* Returns true if argument valid, false otherwise
|
254
254
|
*/
|
255
255
|
int
|
256
|
-
|
256
|
+
nl_xmlIsChar(unsigned int ch) {
|
257
257
|
return(xmlIsCharQ(ch));
|
258
258
|
}
|
259
259
|
|
260
260
|
|
261
261
|
/**
|
262
|
-
*
|
262
|
+
* nl_xmlIsCombining:
|
263
263
|
* @ch: character to validate
|
264
264
|
*
|
265
265
|
* This function is DEPRECATED.
|
@@ -268,13 +268,13 @@ xmlIsChar(unsigned int ch) {
|
|
268
268
|
* Returns true if argument valid, false otherwise
|
269
269
|
*/
|
270
270
|
int
|
271
|
-
|
271
|
+
nl_xmlIsCombining(unsigned int ch) {
|
272
272
|
return(xmlIsCombiningQ(ch));
|
273
273
|
}
|
274
274
|
|
275
275
|
|
276
276
|
/**
|
277
|
-
*
|
277
|
+
* nl_xmlIsDigit:
|
278
278
|
* @ch: character to validate
|
279
279
|
*
|
280
280
|
* This function is DEPRECATED.
|
@@ -283,13 +283,13 @@ xmlIsCombining(unsigned int ch) {
|
|
283
283
|
* Returns true if argument valid, false otherwise
|
284
284
|
*/
|
285
285
|
int
|
286
|
-
|
286
|
+
nl_xmlIsDigit(unsigned int ch) {
|
287
287
|
return(xmlIsDigitQ(ch));
|
288
288
|
}
|
289
289
|
|
290
290
|
|
291
291
|
/**
|
292
|
-
*
|
292
|
+
* nl_xmlIsExtender:
|
293
293
|
* @ch: character to validate
|
294
294
|
*
|
295
295
|
* This function is DEPRECATED.
|
@@ -298,13 +298,13 @@ xmlIsDigit(unsigned int ch) {
|
|
298
298
|
* Returns true if argument valid, false otherwise
|
299
299
|
*/
|
300
300
|
int
|
301
|
-
|
301
|
+
nl_xmlIsExtender(unsigned int ch) {
|
302
302
|
return(xmlIsExtenderQ(ch));
|
303
303
|
}
|
304
304
|
|
305
305
|
|
306
306
|
/**
|
307
|
-
*
|
307
|
+
* nl_xmlIsIdeographic:
|
308
308
|
* @ch: character to validate
|
309
309
|
*
|
310
310
|
* This function is DEPRECATED.
|
@@ -313,13 +313,13 @@ xmlIsExtender(unsigned int ch) {
|
|
313
313
|
* Returns true if argument valid, false otherwise
|
314
314
|
*/
|
315
315
|
int
|
316
|
-
|
316
|
+
nl_xmlIsIdeographic(unsigned int ch) {
|
317
317
|
return(xmlIsIdeographicQ(ch));
|
318
318
|
}
|
319
319
|
|
320
320
|
|
321
321
|
/**
|
322
|
-
*
|
322
|
+
* nl_xmlIsPubidChar:
|
323
323
|
* @ch: character to validate
|
324
324
|
*
|
325
325
|
* This function is DEPRECATED.
|
@@ -328,7 +328,7 @@ xmlIsIdeographic(unsigned int ch) {
|
|
328
328
|
* Returns true if argument valid, false otherwise
|
329
329
|
*/
|
330
330
|
int
|
331
|
-
|
331
|
+
nl_xmlIsPubidChar(unsigned int ch) {
|
332
332
|
return(xmlIsPubidCharQ(ch));
|
333
333
|
}
|
334
334
|
|