Lines Matching refs:sdl

25 static int schema_simpleType(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr simpleType, sdlTypePtr cur_type…
26 static int schema_complexType(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr compType, sdlTypePtr cur_type);
27 static int schema_list(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr listType, sdlTypePtr cur_type);
28 static int schema_union(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr unionType, sdlTypePtr cur_type);
29 static int schema_simpleContent(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr simpCompType, sdlTypePtr cur…
30 static int schema_restriction_simpleContent(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr restType, sdlTyp…
31 static int schema_restriction_complexContent(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr restType, sdlTy…
32 static int schema_extension_simpleContent(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr extType, sdlTypePt…
33 static int schema_extension_complexContent(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr extType, sdlTypeP…
34 static int schema_sequence(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr seqType, sdlTypePtr cur_type, sdl…
35 static int schema_all(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr extType, sdlTypePtr cur_type, sdlConte…
36 static int schema_choice(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr choiceType, sdlTypePtr cur_type, sd…
37 static int schema_group(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr groupType, sdlTypePtr cur_type, sdlC…
38 static int schema_any(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr extType, sdlTypePtr cur_type, sdlConte…
39 static int schema_element(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr element, sdlTypePtr cur_type, sdlC…
40 static int schema_attribute(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr attrType, sdlTypePtr cur_type, s…
41 static int schema_attributeGroup(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr attrType, sdlTypePtr cur_ty…
49 static encodePtr create_encoder(sdlPtr sdl, sdlTypePtr cur_type, const xmlChar *ns, const xmlChar *… in create_encoder() argument
54 if (sdl->encoders == NULL) { in create_encoder()
55 sdl->encoders = emalloc(sizeof(HashTable)); in create_encoder()
56 zend_hash_init(sdl->encoders, 0, NULL, delete_encoder, 0); in create_encoder()
62 if (zend_hash_find(sdl->encoders, nscat.c, nscat.len + 1, (void**)&enc_ptr) == SUCCESS) { in create_encoder()
83 zend_hash_update(sdl->encoders, nscat.c, nscat.len + 1, &enc, sizeof(encodePtr), NULL); in create_encoder()
89 static encodePtr get_create_encoder(sdlPtr sdl, sdlTypePtr cur_type, const xmlChar *ns, const xmlCh… in get_create_encoder() argument
91 encodePtr enc = get_encoder(sdl, (char*)ns, (char*)type); in get_create_encoder()
93 enc = create_encoder(sdl, cur_type, ns, type); in get_create_encoder()
168 if (!ctx->sdl->types) { in load_schema()
169 ctx->sdl->types = emalloc(sizeof(HashTable)); in load_schema()
170 zend_hash_init(ctx->sdl->types, 0, NULL, delete_type, 0); in load_schema()
273 schema_simpleType(ctx->sdl, tns, trav, NULL); in load_schema()
275 schema_complexType(ctx->sdl, tns, trav, NULL); in load_schema()
277 schema_group(ctx->sdl, tns, trav, NULL, NULL); in load_schema()
279 schema_attributeGroup(ctx->sdl, tns, trav, NULL, ctx); in load_schema()
281 schema_element(ctx->sdl, tns, trav, NULL, NULL); in load_schema()
283 schema_attribute(ctx->sdl, tns, trav, NULL, ctx); in load_schema()
305 static int schema_simpleType(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr simpleType, sdlTypePtr cur_type) in schema_simpleType() argument
331 zend_hash_next_index_insert(sdl->types, &newType, sizeof(sdlTypePtr), (void **)&ptr); in schema_simpleType()
333 if (sdl->encoders == NULL) { in schema_simpleType()
334 sdl->encoders = emalloc(sizeof(HashTable)); in schema_simpleType()
335 zend_hash_init(sdl->encoders, 0, NULL, delete_encoder, 0); in schema_simpleType()
344 zend_hash_next_index_insert(sdl->encoders, &cur_type->encode, sizeof(encodePtr), NULL); in schema_simpleType()
358 zend_hash_next_index_insert(sdl->types, &newType, sizeof(sdlTypePtr), (void **)&ptr); in schema_simpleType()
368 create_encoder(sdl, cur_type, ns->children->content, name->children->content); in schema_simpleType()
380 schema_restriction_simpleContent(sdl, tns, trav, cur_type, 1); in schema_simpleType()
384 schema_list(sdl, tns, trav, cur_type); in schema_simpleType()
388 schema_union(sdl, tns, trav, cur_type); in schema_simpleType()
411 static int schema_list(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr listType, sdlTypePtr cur_type) in schema_list() argument
432 newType->encode = get_create_encoder(sdl, newType, nsptr->href, BAD_CAST(type)); in schema_list()
463 smart_str_append_long(&anonymous, zend_hash_num_elements(sdl->types)); in schema_list()
475 schema_simpleType(sdl, tns, trav, newType); in schema_list()
493 static int schema_union(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr unionType, sdlTypePtr cur_type) in schema_union() argument
527 newType->encode = get_create_encoder(sdl, newType, nsptr->href, BAD_CAST(type)); in schema_union()
559 smart_str_append_long(&anonymous, zend_hash_num_elements(sdl->types)); in schema_union()
571 schema_simpleType(sdl, tns, trav, newType); in schema_union()
591 static int schema_simpleContent(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr simpCompType, sdlTypePtr cur… in schema_simpleContent() argument
603 schema_restriction_simpleContent(sdl, tns, trav, cur_type, 0); in schema_simpleContent()
607 schema_extension_simpleContent(sdl, tns, trav, cur_type); in schema_simpleContent()
636 static int schema_restriction_simpleContent(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr restType, sdlTyp… in schema_restriction_simpleContent() argument
649 cur_type->encode = get_create_encoder(sdl, cur_type, nsptr->href, BAD_CAST(type)); in schema_restriction_simpleContent()
668 schema_simpleType(sdl, tns, trav, cur_type); in schema_restriction_simpleContent()
713 schema_attribute(sdl, tns, trav, cur_type, NULL); in schema_restriction_simpleContent()
715 schema_attributeGroup(sdl, tns, trav, cur_type, NULL); in schema_restriction_simpleContent()
741 static int schema_restriction_complexContent(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr restType, sdlTy… in schema_restriction_complexContent() argument
754 cur_type->encode = get_create_encoder(sdl, cur_type, nsptr->href, BAD_CAST(type)); in schema_restriction_complexContent()
769 schema_group(sdl, tns, trav, cur_type, NULL); in schema_restriction_complexContent()
772 schema_all(sdl, tns, trav, cur_type, NULL); in schema_restriction_complexContent()
775 schema_choice(sdl, tns, trav, cur_type, NULL); in schema_restriction_complexContent()
778 schema_sequence(sdl, tns, trav, cur_type, NULL); in schema_restriction_complexContent()
784 schema_attribute(sdl, tns, trav, cur_type, NULL); in schema_restriction_complexContent()
786 schema_attributeGroup(sdl, tns, trav, cur_type, NULL); in schema_restriction_complexContent()
866 static int schema_extension_simpleContent(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr extType, sdlTypePt… in schema_extension_simpleContent() argument
879 cur_type->encode = get_create_encoder(sdl, cur_type, nsptr->href, BAD_CAST(type)); in schema_extension_simpleContent()
894 schema_attribute(sdl, tns, trav, cur_type, NULL); in schema_extension_simpleContent()
896 schema_attributeGroup(sdl, tns, trav, cur_type, NULL); in schema_extension_simpleContent()
921 static int schema_extension_complexContent(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr extType, sdlTypeP… in schema_extension_complexContent() argument
934 cur_type->encode = get_create_encoder(sdl, cur_type, nsptr->href, BAD_CAST(type)); in schema_extension_complexContent()
949 schema_group(sdl, tns, trav, cur_type, NULL); in schema_extension_complexContent()
952 schema_all(sdl, tns, trav, cur_type, NULL); in schema_extension_complexContent()
955 schema_choice(sdl, tns, trav, cur_type, NULL); in schema_extension_complexContent()
958 schema_sequence(sdl, tns, trav, cur_type, NULL); in schema_extension_complexContent()
964 schema_attribute(sdl, tns, trav, cur_type, NULL); in schema_extension_complexContent()
966 schema_attributeGroup(sdl, tns, trav, cur_type, NULL); in schema_extension_complexContent()
1013 static int schema_all(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr all, sdlTypePtr cur_type, sdlContentMo… in schema_all() argument
1037 schema_element(sdl, tns, trav, cur_type, newModel); in schema_all()
1057 static int schema_group(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr groupType, sdlTypePtr cur_type, sdlC… in schema_group() argument
1121 if (sdl->groups == NULL) { in schema_group()
1122 sdl->groups = emalloc(sizeof(HashTable)); in schema_group()
1123 zend_hash_init(sdl->groups, 0, NULL, delete_type, 0); in schema_group()
1125 …if (zend_hash_add(sdl->groups, key.c, key.len+1, (void**)&newType, sizeof(sdlTypePtr), NULL) != SU… in schema_group()
1155 schema_choice(sdl, tns, trav, cur_type, newModel); in schema_group()
1162 schema_sequence(sdl, tns, trav, cur_type, newModel); in schema_group()
1169 schema_all(sdl, tns, trav, cur_type, newModel); in schema_group()
1189 static int schema_choice(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr choiceType, sdlTypePtr cur_type, sd… in schema_choice() argument
1213 schema_element(sdl, tns, trav, cur_type, newModel); in schema_choice()
1215 schema_group(sdl, tns, trav, cur_type, newModel); in schema_choice()
1217 schema_choice(sdl, tns, trav, cur_type, newModel); in schema_choice()
1219 schema_sequence(sdl, tns, trav, cur_type, newModel); in schema_choice()
1221 schema_any(sdl, tns, trav, cur_type, newModel); in schema_choice()
1239 static int schema_sequence(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr seqType, sdlTypePtr cur_type, sdl… in schema_sequence() argument
1263 schema_element(sdl, tns, trav, cur_type, newModel); in schema_sequence()
1265 schema_group(sdl, tns, trav, cur_type, newModel); in schema_sequence()
1267 schema_choice(sdl, tns, trav, cur_type, newModel); in schema_sequence()
1269 schema_sequence(sdl, tns, trav, cur_type, newModel); in schema_sequence()
1271 schema_any(sdl, tns, trav, cur_type, newModel); in schema_sequence()
1291 static int schema_any(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr anyType, sdlTypePtr cur_type, sdlConte… in schema_any() argument
1314 static int schema_complexContent(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr compCont, sdlTypePtr cur_ty… in schema_complexContent() argument
1326 schema_restriction_complexContent(sdl, tns, trav, cur_type); in schema_complexContent()
1330 schema_extension_complexContent(sdl, tns, trav, cur_type); in schema_complexContent()
1357 static int schema_complexType(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr compType, sdlTypePtr cur_type) in schema_complexType() argument
1384 zend_hash_next_index_insert(sdl->types, &newType, sizeof(sdlTypePtr), (void **)&ptr); in schema_complexType()
1386 if (sdl->encoders == NULL) { in schema_complexType()
1387 sdl->encoders = emalloc(sizeof(HashTable)); in schema_complexType()
1388 zend_hash_init(sdl->encoders, 0, NULL, delete_encoder, 0); in schema_complexType()
1397 zend_hash_next_index_insert(sdl->encoders, &cur_type->encode, sizeof(encodePtr), NULL); in schema_complexType()
1410 zend_hash_next_index_insert(sdl->types, &newType, sizeof(sdlTypePtr), (void **)&ptr); in schema_complexType()
1413 create_encoder(sdl, cur_type, ns->children->content, name->children->content); in schema_complexType()
1426 schema_simpleContent(sdl, tns, trav, cur_type); in schema_complexType()
1429 schema_complexContent(sdl, tns, trav, cur_type); in schema_complexType()
1433 schema_group(sdl, tns, trav, cur_type, NULL); in schema_complexType()
1436 schema_all(sdl, tns, trav, cur_type, NULL); in schema_complexType()
1439 schema_choice(sdl, tns, trav, cur_type, NULL); in schema_complexType()
1442 schema_sequence(sdl, tns, trav, cur_type, NULL); in schema_complexType()
1447 schema_attribute(sdl, tns, trav, cur_type, NULL); in schema_complexType()
1449 schema_attributeGroup(sdl, tns, trav, cur_type, NULL); in schema_complexType()
1486 static int schema_element(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr element, sdlTypePtr cur_type, sdlC… in schema_element() argument
1545 if (sdl->elements == NULL) { in schema_element()
1546 sdl->elements = emalloc(sizeof(HashTable)); in schema_element()
1547 zend_hash_init(sdl->elements, 0, NULL, delete_type, 0); in schema_element()
1549 addHash = sdl->elements; in schema_element()
1668 cur_type->encode = get_create_encoder(sdl, cur_type, nsptr->href, BAD_CAST(cptype)); in schema_element()
1686 schema_simpleType(sdl, tns, trav, cur_type); in schema_element()
1694 schema_complexType(sdl, tns, trav, cur_type); in schema_element()
1728 static int schema_attribute(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr attrType, sdlTypePtr cur_type, s… in schema_attribute() argument
1815 newAttr->encode = get_create_encoder(sdl, cur_type, nsptr->href, BAD_CAST(cptype)); in schema_attribute()
1928 smart_str_append_long(&anonymous, zend_hash_num_elements(sdl->types)); in schema_attribute()
1933 schema_simpleType(sdl, tns, trav, dummy_type); in schema_attribute()
1945 static int schema_attributeGroup(sdlPtr sdl, xmlAttrPtr tns, xmlNodePtr attrGroup, sdlTypePtr cur_t… in schema_attributeGroup() argument
2023 schema_attribute(sdl, tns, trav, cur_type, NULL); in schema_attributeGroup()
2028 schema_attributeGroup(sdl, tns, trav, cur_type, NULL); in schema_attributeGroup()
2189 …if (ctx->sdl->groups && zend_hash_find(ctx->sdl->groups, model->u.group_ref, strlen(model->u.group… in schema_content_model_fixup()
2238 if (ctx->sdl->elements != NULL) { in schema_type_fixup()
2239 tmp = (sdlTypePtr*)schema_find_by_ref(ctx->sdl->elements, type->ref); in schema_type_fixup()
2291 sdlPtr sdl = ctx->sdl; in schema_pass2() local
2309 if (sdl->elements) { in schema_pass2()
2310 zend_hash_internal_pointer_reset(sdl->elements); in schema_pass2()
2311 while (zend_hash_get_current_data(sdl->elements,(void**)&type) == SUCCESS) { in schema_pass2()
2313 zend_hash_move_forward(sdl->elements); in schema_pass2()
2316 if (sdl->groups) { in schema_pass2()
2317 zend_hash_internal_pointer_reset(sdl->groups); in schema_pass2()
2318 while (zend_hash_get_current_data(sdl->groups,(void**)&type) == SUCCESS) { in schema_pass2()
2320 zend_hash_move_forward(sdl->groups); in schema_pass2()
2323 if (sdl->types) { in schema_pass2()
2324 zend_hash_internal_pointer_reset(sdl->types); in schema_pass2()
2325 while (zend_hash_get_current_data(sdl->types,(void**)&type) == SUCCESS) { in schema_pass2()
2327 zend_hash_move_forward(sdl->types); in schema_pass2()