repo stringlengths 7 55 | path stringlengths 4 223 | func_name stringlengths 1 134 | original_string stringlengths 75 104k | language stringclasses 1 value | code stringlengths 75 104k | code_tokens listlengths 19 28.4k | docstring stringlengths 1 46.9k | docstring_tokens listlengths 1 1.97k | sha stringlengths 40 40 | url stringlengths 87 315 | partition stringclasses 1 value |
|---|---|---|---|---|---|---|---|---|---|---|---|
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.removeID | def removeID(self, attr):
"""Remove the given attribute from the ID table maintained
internally. """
if attr is None: attr__o = None
else: attr__o = attr._o
ret = libxml2mod.xmlRemoveID(self._o, attr__o)
return ret | python | def removeID(self, attr):
"""Remove the given attribute from the ID table maintained
internally. """
if attr is None: attr__o = None
else: attr__o = attr._o
ret = libxml2mod.xmlRemoveID(self._o, attr__o)
return ret | [
"def",
"removeID",
"(",
"self",
",",
"attr",
")",
":",
"if",
"attr",
"is",
"None",
":",
"attr__o",
"=",
"None",
"else",
":",
"attr__o",
"=",
"attr",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlRemoveID",
"(",
"self",
".",
"_o",
",",
"attr__o",
")",
"return",
"ret"
] | Remove the given attribute from the ID table maintained
internally. | [
"Remove",
"the",
"given",
"attribute",
"from",
"the",
"ID",
"table",
"maintained",
"internally",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4629-L4635 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.removeRef | def removeRef(self, attr):
"""Remove the given attribute from the Ref table maintained
internally. """
if attr is None: attr__o = None
else: attr__o = attr._o
ret = libxml2mod.xmlRemoveRef(self._o, attr__o)
return ret | python | def removeRef(self, attr):
"""Remove the given attribute from the Ref table maintained
internally. """
if attr is None: attr__o = None
else: attr__o = attr._o
ret = libxml2mod.xmlRemoveRef(self._o, attr__o)
return ret | [
"def",
"removeRef",
"(",
"self",
",",
"attr",
")",
":",
"if",
"attr",
"is",
"None",
":",
"attr__o",
"=",
"None",
"else",
":",
"attr__o",
"=",
"attr",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlRemoveRef",
"(",
"self",
".",
"_o",
",",
"attr__o",
")",
"return",
"ret"
] | Remove the given attribute from the Ref table maintained
internally. | [
"Remove",
"the",
"given",
"attribute",
"from",
"the",
"Ref",
"table",
"maintained",
"internally",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4637-L4643 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validCtxtNormalizeAttributeValue | def validCtxtNormalizeAttributeValue(self, ctxt, elem, name, value):
"""Does the validation related extra step of the normalization
of attribute values: If the declared value is not CDATA,
then the XML processor must further process the normalized
attribute value by discarding any leading and trailing
space (#x20) characters, and by replacing sequences of
space (#x20) characters by single space (#x20) character.
Also check VC: Standalone Document Declaration in P32, and
update ctxt->valid accordingly """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlValidCtxtNormalizeAttributeValue(ctxt__o, self._o, elem__o, name, value)
return ret | python | def validCtxtNormalizeAttributeValue(self, ctxt, elem, name, value):
"""Does the validation related extra step of the normalization
of attribute values: If the declared value is not CDATA,
then the XML processor must further process the normalized
attribute value by discarding any leading and trailing
space (#x20) characters, and by replacing sequences of
space (#x20) characters by single space (#x20) character.
Also check VC: Standalone Document Declaration in P32, and
update ctxt->valid accordingly """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlValidCtxtNormalizeAttributeValue(ctxt__o, self._o, elem__o, name, value)
return ret | [
"def",
"validCtxtNormalizeAttributeValue",
"(",
"self",
",",
"ctxt",
",",
"elem",
",",
"name",
",",
"value",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"if",
"elem",
"is",
"None",
":",
"elem__o",
"=",
"None",
"else",
":",
"elem__o",
"=",
"elem",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidCtxtNormalizeAttributeValue",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
",",
"elem__o",
",",
"name",
",",
"value",
")",
"return",
"ret"
] | Does the validation related extra step of the normalization
of attribute values: If the declared value is not CDATA,
then the XML processor must further process the normalized
attribute value by discarding any leading and trailing
space (#x20) characters, and by replacing sequences of
space (#x20) characters by single space (#x20) character.
Also check VC: Standalone Document Declaration in P32, and
update ctxt->valid accordingly | [
"Does",
"the",
"validation",
"related",
"extra",
"step",
"of",
"the",
"normalization",
"of",
"attribute",
"values",
":",
"If",
"the",
"declared",
"value",
"is",
"not",
"CDATA",
"then",
"the",
"XML",
"processor",
"must",
"further",
"process",
"the",
"normalized",
"attribute",
"value",
"by",
"discarding",
"any",
"leading",
"and",
"trailing",
"space",
"(",
"#x20",
")",
"characters",
"and",
"by",
"replacing",
"sequences",
"of",
"space",
"(",
"#x20",
")",
"characters",
"by",
"single",
"space",
"(",
"#x20",
")",
"character",
".",
"Also",
"check",
"VC",
":",
"Standalone",
"Document",
"Declaration",
"in",
"P32",
"and",
"update",
"ctxt",
"-",
">",
"valid",
"accordingly"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4645-L4659 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validNormalizeAttributeValue | def validNormalizeAttributeValue(self, elem, name, value):
"""Does the validation related extra step of the normalization
of attribute values: If the declared value is not CDATA,
then the XML processor must further process the normalized
attribute value by discarding any leading and trailing
space (#x20) characters, and by replacing sequences of
space (#x20) characters by single space (#x20) character. """
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlValidNormalizeAttributeValue(self._o, elem__o, name, value)
return ret | python | def validNormalizeAttributeValue(self, elem, name, value):
"""Does the validation related extra step of the normalization
of attribute values: If the declared value is not CDATA,
then the XML processor must further process the normalized
attribute value by discarding any leading and trailing
space (#x20) characters, and by replacing sequences of
space (#x20) characters by single space (#x20) character. """
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlValidNormalizeAttributeValue(self._o, elem__o, name, value)
return ret | [
"def",
"validNormalizeAttributeValue",
"(",
"self",
",",
"elem",
",",
"name",
",",
"value",
")",
":",
"if",
"elem",
"is",
"None",
":",
"elem__o",
"=",
"None",
"else",
":",
"elem__o",
"=",
"elem",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidNormalizeAttributeValue",
"(",
"self",
".",
"_o",
",",
"elem__o",
",",
"name",
",",
"value",
")",
"return",
"ret"
] | Does the validation related extra step of the normalization
of attribute values: If the declared value is not CDATA,
then the XML processor must further process the normalized
attribute value by discarding any leading and trailing
space (#x20) characters, and by replacing sequences of
space (#x20) characters by single space (#x20) character. | [
"Does",
"the",
"validation",
"related",
"extra",
"step",
"of",
"the",
"normalization",
"of",
"attribute",
"values",
":",
"If",
"the",
"declared",
"value",
"is",
"not",
"CDATA",
"then",
"the",
"XML",
"processor",
"must",
"further",
"process",
"the",
"normalized",
"attribute",
"value",
"by",
"discarding",
"any",
"leading",
"and",
"trailing",
"space",
"(",
"#x20",
")",
"characters",
"and",
"by",
"replacing",
"sequences",
"of",
"space",
"(",
"#x20",
")",
"characters",
"by",
"single",
"space",
"(",
"#x20",
")",
"character",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4661-L4671 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validateDocument | def validateDocument(self, ctxt):
"""Try to validate the document instance basically it does
the all the checks described by the XML Rec i.e. validates
the internal and external subset (if present) and validate
the document tree. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
ret = libxml2mod.xmlValidateDocument(ctxt__o, self._o)
return ret | python | def validateDocument(self, ctxt):
"""Try to validate the document instance basically it does
the all the checks described by the XML Rec i.e. validates
the internal and external subset (if present) and validate
the document tree. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
ret = libxml2mod.xmlValidateDocument(ctxt__o, self._o)
return ret | [
"def",
"validateDocument",
"(",
"self",
",",
"ctxt",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidateDocument",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
")",
"return",
"ret"
] | Try to validate the document instance basically it does
the all the checks described by the XML Rec i.e. validates
the internal and external subset (if present) and validate
the document tree. | [
"Try",
"to",
"validate",
"the",
"document",
"instance",
"basically",
"it",
"does",
"the",
"all",
"the",
"checks",
"described",
"by",
"the",
"XML",
"Rec",
"i",
".",
"e",
".",
"validates",
"the",
"internal",
"and",
"external",
"subset",
"(",
"if",
"present",
")",
"and",
"validate",
"the",
"document",
"tree",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4673-L4681 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validateDocumentFinal | def validateDocumentFinal(self, ctxt):
"""Does the final step for the document validation once all
the incremental validation steps have been completed
basically it does the following checks described by the XML
Rec Check all the IDREF/IDREFS attributes definition for
validity """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
ret = libxml2mod.xmlValidateDocumentFinal(ctxt__o, self._o)
return ret | python | def validateDocumentFinal(self, ctxt):
"""Does the final step for the document validation once all
the incremental validation steps have been completed
basically it does the following checks described by the XML
Rec Check all the IDREF/IDREFS attributes definition for
validity """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
ret = libxml2mod.xmlValidateDocumentFinal(ctxt__o, self._o)
return ret | [
"def",
"validateDocumentFinal",
"(",
"self",
",",
"ctxt",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidateDocumentFinal",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
")",
"return",
"ret"
] | Does the final step for the document validation once all
the incremental validation steps have been completed
basically it does the following checks described by the XML
Rec Check all the IDREF/IDREFS attributes definition for
validity | [
"Does",
"the",
"final",
"step",
"for",
"the",
"document",
"validation",
"once",
"all",
"the",
"incremental",
"validation",
"steps",
"have",
"been",
"completed",
"basically",
"it",
"does",
"the",
"following",
"checks",
"described",
"by",
"the",
"XML",
"Rec",
"Check",
"all",
"the",
"IDREF",
"/",
"IDREFS",
"attributes",
"definition",
"for",
"validity"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4683-L4692 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validateDtd | def validateDtd(self, ctxt, dtd):
"""Try to validate the document against the dtd instance
Basically it does check all the definitions in the DtD.
Note the the internal subset (if present) is de-coupled
(i.e. not used), which could give problems if ID or IDREF
is present. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if dtd is None: dtd__o = None
else: dtd__o = dtd._o
ret = libxml2mod.xmlValidateDtd(ctxt__o, self._o, dtd__o)
return ret | python | def validateDtd(self, ctxt, dtd):
"""Try to validate the document against the dtd instance
Basically it does check all the definitions in the DtD.
Note the the internal subset (if present) is de-coupled
(i.e. not used), which could give problems if ID or IDREF
is present. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if dtd is None: dtd__o = None
else: dtd__o = dtd._o
ret = libxml2mod.xmlValidateDtd(ctxt__o, self._o, dtd__o)
return ret | [
"def",
"validateDtd",
"(",
"self",
",",
"ctxt",
",",
"dtd",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"if",
"dtd",
"is",
"None",
":",
"dtd__o",
"=",
"None",
"else",
":",
"dtd__o",
"=",
"dtd",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidateDtd",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
",",
"dtd__o",
")",
"return",
"ret"
] | Try to validate the document against the dtd instance
Basically it does check all the definitions in the DtD.
Note the the internal subset (if present) is de-coupled
(i.e. not used), which could give problems if ID or IDREF
is present. | [
"Try",
"to",
"validate",
"the",
"document",
"against",
"the",
"dtd",
"instance",
"Basically",
"it",
"does",
"check",
"all",
"the",
"definitions",
"in",
"the",
"DtD",
".",
"Note",
"the",
"the",
"internal",
"subset",
"(",
"if",
"present",
")",
"is",
"de",
"-",
"coupled",
"(",
"i",
".",
"e",
".",
"not",
"used",
")",
"which",
"could",
"give",
"problems",
"if",
"ID",
"or",
"IDREF",
"is",
"present",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4694-L4705 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validateDtdFinal | def validateDtdFinal(self, ctxt):
"""Does the final step for the dtds validation once all the
subsets have been parsed basically it does the following
checks described by the XML Rec - check that ENTITY and
ENTITIES type attributes default or possible values matches
one of the defined entities. - check that NOTATION type
attributes default or possible values matches one of the
defined notations. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
ret = libxml2mod.xmlValidateDtdFinal(ctxt__o, self._o)
return ret | python | def validateDtdFinal(self, ctxt):
"""Does the final step for the dtds validation once all the
subsets have been parsed basically it does the following
checks described by the XML Rec - check that ENTITY and
ENTITIES type attributes default or possible values matches
one of the defined entities. - check that NOTATION type
attributes default or possible values matches one of the
defined notations. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
ret = libxml2mod.xmlValidateDtdFinal(ctxt__o, self._o)
return ret | [
"def",
"validateDtdFinal",
"(",
"self",
",",
"ctxt",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidateDtdFinal",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
")",
"return",
"ret"
] | Does the final step for the dtds validation once all the
subsets have been parsed basically it does the following
checks described by the XML Rec - check that ENTITY and
ENTITIES type attributes default or possible values matches
one of the defined entities. - check that NOTATION type
attributes default or possible values matches one of the
defined notations. | [
"Does",
"the",
"final",
"step",
"for",
"the",
"dtds",
"validation",
"once",
"all",
"the",
"subsets",
"have",
"been",
"parsed",
"basically",
"it",
"does",
"the",
"following",
"checks",
"described",
"by",
"the",
"XML",
"Rec",
"-",
"check",
"that",
"ENTITY",
"and",
"ENTITIES",
"type",
"attributes",
"default",
"or",
"possible",
"values",
"matches",
"one",
"of",
"the",
"defined",
"entities",
".",
"-",
"check",
"that",
"NOTATION",
"type",
"attributes",
"default",
"or",
"possible",
"values",
"matches",
"one",
"of",
"the",
"defined",
"notations",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4707-L4718 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validateElement | def validateElement(self, ctxt, elem):
"""Try to validate the subtree under an element """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlValidateElement(ctxt__o, self._o, elem__o)
return ret | python | def validateElement(self, ctxt, elem):
"""Try to validate the subtree under an element """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlValidateElement(ctxt__o, self._o, elem__o)
return ret | [
"def",
"validateElement",
"(",
"self",
",",
"ctxt",
",",
"elem",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"if",
"elem",
"is",
"None",
":",
"elem__o",
"=",
"None",
"else",
":",
"elem__o",
"=",
"elem",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidateElement",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
",",
"elem__o",
")",
"return",
"ret"
] | Try to validate the subtree under an element | [
"Try",
"to",
"validate",
"the",
"subtree",
"under",
"an",
"element"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4720-L4727 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validateNotationUse | def validateNotationUse(self, ctxt, notationName):
"""Validate that the given name match a notation declaration.
- [ VC: Notation Declared ] """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
ret = libxml2mod.xmlValidateNotationUse(ctxt__o, self._o, notationName)
return ret | python | def validateNotationUse(self, ctxt, notationName):
"""Validate that the given name match a notation declaration.
- [ VC: Notation Declared ] """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
ret = libxml2mod.xmlValidateNotationUse(ctxt__o, self._o, notationName)
return ret | [
"def",
"validateNotationUse",
"(",
"self",
",",
"ctxt",
",",
"notationName",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidateNotationUse",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
",",
"notationName",
")",
"return",
"ret"
] | Validate that the given name match a notation declaration.
- [ VC: Notation Declared ] | [
"Validate",
"that",
"the",
"given",
"name",
"match",
"a",
"notation",
"declaration",
".",
"-",
"[",
"VC",
":",
"Notation",
"Declared",
"]"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4729-L4735 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validateOneAttribute | def validateOneAttribute(self, ctxt, elem, attr, value):
"""Try to validate a single attribute for an element basically
it does the following checks as described by the XML-1.0
recommendation: - [ VC: Attribute Value Type ] - [ VC:
Fixed Attribute Default ] - [ VC: Entity Name ] - [ VC:
Name Token ] - [ VC: ID ] - [ VC: IDREF ] - [ VC: Entity
Name ] - [ VC: Notation Attributes ] The ID/IDREF
uniqueness and matching are done separately """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
if attr is None: attr__o = None
else: attr__o = attr._o
ret = libxml2mod.xmlValidateOneAttribute(ctxt__o, self._o, elem__o, attr__o, value)
return ret | python | def validateOneAttribute(self, ctxt, elem, attr, value):
"""Try to validate a single attribute for an element basically
it does the following checks as described by the XML-1.0
recommendation: - [ VC: Attribute Value Type ] - [ VC:
Fixed Attribute Default ] - [ VC: Entity Name ] - [ VC:
Name Token ] - [ VC: ID ] - [ VC: IDREF ] - [ VC: Entity
Name ] - [ VC: Notation Attributes ] The ID/IDREF
uniqueness and matching are done separately """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
if attr is None: attr__o = None
else: attr__o = attr._o
ret = libxml2mod.xmlValidateOneAttribute(ctxt__o, self._o, elem__o, attr__o, value)
return ret | [
"def",
"validateOneAttribute",
"(",
"self",
",",
"ctxt",
",",
"elem",
",",
"attr",
",",
"value",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"if",
"elem",
"is",
"None",
":",
"elem__o",
"=",
"None",
"else",
":",
"elem__o",
"=",
"elem",
".",
"_o",
"if",
"attr",
"is",
"None",
":",
"attr__o",
"=",
"None",
"else",
":",
"attr__o",
"=",
"attr",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidateOneAttribute",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
",",
"elem__o",
",",
"attr__o",
",",
"value",
")",
"return",
"ret"
] | Try to validate a single attribute for an element basically
it does the following checks as described by the XML-1.0
recommendation: - [ VC: Attribute Value Type ] - [ VC:
Fixed Attribute Default ] - [ VC: Entity Name ] - [ VC:
Name Token ] - [ VC: ID ] - [ VC: IDREF ] - [ VC: Entity
Name ] - [ VC: Notation Attributes ] The ID/IDREF
uniqueness and matching are done separately | [
"Try",
"to",
"validate",
"a",
"single",
"attribute",
"for",
"an",
"element",
"basically",
"it",
"does",
"the",
"following",
"checks",
"as",
"described",
"by",
"the",
"XML",
"-",
"1",
".",
"0",
"recommendation",
":",
"-",
"[",
"VC",
":",
"Attribute",
"Value",
"Type",
"]",
"-",
"[",
"VC",
":",
"Fixed",
"Attribute",
"Default",
"]",
"-",
"[",
"VC",
":",
"Entity",
"Name",
"]",
"-",
"[",
"VC",
":",
"Name",
"Token",
"]",
"-",
"[",
"VC",
":",
"ID",
"]",
"-",
"[",
"VC",
":",
"IDREF",
"]",
"-",
"[",
"VC",
":",
"Entity",
"Name",
"]",
"-",
"[",
"VC",
":",
"Notation",
"Attributes",
"]",
"The",
"ID",
"/",
"IDREF",
"uniqueness",
"and",
"matching",
"are",
"done",
"separately"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4737-L4752 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validateOneElement | def validateOneElement(self, ctxt, elem):
"""Try to validate a single element and it's attributes,
basically it does the following checks as described by the
XML-1.0 recommendation: - [ VC: Element Valid ] - [ VC:
Required Attribute ] Then call xmlValidateOneAttribute()
for each attribute present. The ID/IDREF checkings are
done separately """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlValidateOneElement(ctxt__o, self._o, elem__o)
return ret | python | def validateOneElement(self, ctxt, elem):
"""Try to validate a single element and it's attributes,
basically it does the following checks as described by the
XML-1.0 recommendation: - [ VC: Element Valid ] - [ VC:
Required Attribute ] Then call xmlValidateOneAttribute()
for each attribute present. The ID/IDREF checkings are
done separately """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlValidateOneElement(ctxt__o, self._o, elem__o)
return ret | [
"def",
"validateOneElement",
"(",
"self",
",",
"ctxt",
",",
"elem",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"if",
"elem",
"is",
"None",
":",
"elem__o",
"=",
"None",
"else",
":",
"elem__o",
"=",
"elem",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidateOneElement",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
",",
"elem__o",
")",
"return",
"ret"
] | Try to validate a single element and it's attributes,
basically it does the following checks as described by the
XML-1.0 recommendation: - [ VC: Element Valid ] - [ VC:
Required Attribute ] Then call xmlValidateOneAttribute()
for each attribute present. The ID/IDREF checkings are
done separately | [
"Try",
"to",
"validate",
"a",
"single",
"element",
"and",
"it",
"s",
"attributes",
"basically",
"it",
"does",
"the",
"following",
"checks",
"as",
"described",
"by",
"the",
"XML",
"-",
"1",
".",
"0",
"recommendation",
":",
"-",
"[",
"VC",
":",
"Element",
"Valid",
"]",
"-",
"[",
"VC",
":",
"Required",
"Attribute",
"]",
"Then",
"call",
"xmlValidateOneAttribute",
"()",
"for",
"each",
"attribute",
"present",
".",
"The",
"ID",
"/",
"IDREF",
"checkings",
"are",
"done",
"separately"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4754-L4766 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validateOneNamespace | def validateOneNamespace(self, ctxt, elem, prefix, ns, value):
"""Try to validate a single namespace declaration for an
element basically it does the following checks as described
by the XML-1.0 recommendation: - [ VC: Attribute Value Type
] - [ VC: Fixed Attribute Default ] - [ VC: Entity Name ] -
[ VC: Name Token ] - [ VC: ID ] - [ VC: IDREF ] - [ VC:
Entity Name ] - [ VC: Notation Attributes ] The ID/IDREF
uniqueness and matching are done separately """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
if ns is None: ns__o = None
else: ns__o = ns._o
ret = libxml2mod.xmlValidateOneNamespace(ctxt__o, self._o, elem__o, prefix, ns__o, value)
return ret | python | def validateOneNamespace(self, ctxt, elem, prefix, ns, value):
"""Try to validate a single namespace declaration for an
element basically it does the following checks as described
by the XML-1.0 recommendation: - [ VC: Attribute Value Type
] - [ VC: Fixed Attribute Default ] - [ VC: Entity Name ] -
[ VC: Name Token ] - [ VC: ID ] - [ VC: IDREF ] - [ VC:
Entity Name ] - [ VC: Notation Attributes ] The ID/IDREF
uniqueness and matching are done separately """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
if ns is None: ns__o = None
else: ns__o = ns._o
ret = libxml2mod.xmlValidateOneNamespace(ctxt__o, self._o, elem__o, prefix, ns__o, value)
return ret | [
"def",
"validateOneNamespace",
"(",
"self",
",",
"ctxt",
",",
"elem",
",",
"prefix",
",",
"ns",
",",
"value",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"if",
"elem",
"is",
"None",
":",
"elem__o",
"=",
"None",
"else",
":",
"elem__o",
"=",
"elem",
".",
"_o",
"if",
"ns",
"is",
"None",
":",
"ns__o",
"=",
"None",
"else",
":",
"ns__o",
"=",
"ns",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidateOneNamespace",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
",",
"elem__o",
",",
"prefix",
",",
"ns__o",
",",
"value",
")",
"return",
"ret"
] | Try to validate a single namespace declaration for an
element basically it does the following checks as described
by the XML-1.0 recommendation: - [ VC: Attribute Value Type
] - [ VC: Fixed Attribute Default ] - [ VC: Entity Name ] -
[ VC: Name Token ] - [ VC: ID ] - [ VC: IDREF ] - [ VC:
Entity Name ] - [ VC: Notation Attributes ] The ID/IDREF
uniqueness and matching are done separately | [
"Try",
"to",
"validate",
"a",
"single",
"namespace",
"declaration",
"for",
"an",
"element",
"basically",
"it",
"does",
"the",
"following",
"checks",
"as",
"described",
"by",
"the",
"XML",
"-",
"1",
".",
"0",
"recommendation",
":",
"-",
"[",
"VC",
":",
"Attribute",
"Value",
"Type",
"]",
"-",
"[",
"VC",
":",
"Fixed",
"Attribute",
"Default",
"]",
"-",
"[",
"VC",
":",
"Entity",
"Name",
"]",
"-",
"[",
"VC",
":",
"Name",
"Token",
"]",
"-",
"[",
"VC",
":",
"ID",
"]",
"-",
"[",
"VC",
":",
"IDREF",
"]",
"-",
"[",
"VC",
":",
"Entity",
"Name",
"]",
"-",
"[",
"VC",
":",
"Notation",
"Attributes",
"]",
"The",
"ID",
"/",
"IDREF",
"uniqueness",
"and",
"matching",
"are",
"done",
"separately"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4768-L4783 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validatePopElement | def validatePopElement(self, ctxt, elem, qname):
"""Pop the element end from the validation stack. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlValidatePopElement(ctxt__o, self._o, elem__o, qname)
return ret | python | def validatePopElement(self, ctxt, elem, qname):
"""Pop the element end from the validation stack. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlValidatePopElement(ctxt__o, self._o, elem__o, qname)
return ret | [
"def",
"validatePopElement",
"(",
"self",
",",
"ctxt",
",",
"elem",
",",
"qname",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"if",
"elem",
"is",
"None",
":",
"elem__o",
"=",
"None",
"else",
":",
"elem__o",
"=",
"elem",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidatePopElement",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
",",
"elem__o",
",",
"qname",
")",
"return",
"ret"
] | Pop the element end from the validation stack. | [
"Pop",
"the",
"element",
"end",
"from",
"the",
"validation",
"stack",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4785-L4792 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validatePushElement | def validatePushElement(self, ctxt, elem, qname):
"""Push a new element start on the validation stack. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlValidatePushElement(ctxt__o, self._o, elem__o, qname)
return ret | python | def validatePushElement(self, ctxt, elem, qname):
"""Push a new element start on the validation stack. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlValidatePushElement(ctxt__o, self._o, elem__o, qname)
return ret | [
"def",
"validatePushElement",
"(",
"self",
",",
"ctxt",
",",
"elem",
",",
"qname",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"if",
"elem",
"is",
"None",
":",
"elem__o",
"=",
"None",
"else",
":",
"elem__o",
"=",
"elem",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidatePushElement",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
",",
"elem__o",
",",
"qname",
")",
"return",
"ret"
] | Push a new element start on the validation stack. | [
"Push",
"a",
"new",
"element",
"start",
"on",
"the",
"validation",
"stack",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4794-L4801 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.validateRoot | def validateRoot(self, ctxt):
"""Try to validate a the root element basically it does the
following check as described by the XML-1.0 recommendation:
- [ VC: Root Element Type ] it doesn't try to recurse or
apply other check to the element """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
ret = libxml2mod.xmlValidateRoot(ctxt__o, self._o)
return ret | python | def validateRoot(self, ctxt):
"""Try to validate a the root element basically it does the
following check as described by the XML-1.0 recommendation:
- [ VC: Root Element Type ] it doesn't try to recurse or
apply other check to the element """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
ret = libxml2mod.xmlValidateRoot(ctxt__o, self._o)
return ret | [
"def",
"validateRoot",
"(",
"self",
",",
"ctxt",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlValidateRoot",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
")",
"return",
"ret"
] | Try to validate a the root element basically it does the
following check as described by the XML-1.0 recommendation:
- [ VC: Root Element Type ] it doesn't try to recurse or
apply other check to the element | [
"Try",
"to",
"validate",
"a",
"the",
"root",
"element",
"basically",
"it",
"does",
"the",
"following",
"check",
"as",
"described",
"by",
"the",
"XML",
"-",
"1",
".",
"0",
"recommendation",
":",
"-",
"[",
"VC",
":",
"Root",
"Element",
"Type",
"]",
"it",
"doesn",
"t",
"try",
"to",
"recurse",
"or",
"apply",
"other",
"check",
"to",
"the",
"element"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4803-L4811 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.xincludeProcessFlags | def xincludeProcessFlags(self, flags):
"""Implement the XInclude substitution on the XML document @doc """
ret = libxml2mod.xmlXIncludeProcessFlags(self._o, flags)
return ret | python | def xincludeProcessFlags(self, flags):
"""Implement the XInclude substitution on the XML document @doc """
ret = libxml2mod.xmlXIncludeProcessFlags(self._o, flags)
return ret | [
"def",
"xincludeProcessFlags",
"(",
"self",
",",
"flags",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlXIncludeProcessFlags",
"(",
"self",
".",
"_o",
",",
"flags",
")",
"return",
"ret"
] | Implement the XInclude substitution on the XML document @doc | [
"Implement",
"the",
"XInclude",
"substitution",
"on",
"the",
"XML",
"document"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4822-L4825 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.NewWalker | def NewWalker(self, reader):
"""Setup an xmltextReader to parse a preparsed XML document.
This reuses the existing @reader xmlTextReader. """
if reader is None: reader__o = None
else: reader__o = reader._o
ret = libxml2mod.xmlReaderNewWalker(reader__o, self._o)
return ret | python | def NewWalker(self, reader):
"""Setup an xmltextReader to parse a preparsed XML document.
This reuses the existing @reader xmlTextReader. """
if reader is None: reader__o = None
else: reader__o = reader._o
ret = libxml2mod.xmlReaderNewWalker(reader__o, self._o)
return ret | [
"def",
"NewWalker",
"(",
"self",
",",
"reader",
")",
":",
"if",
"reader",
"is",
"None",
":",
"reader__o",
"=",
"None",
"else",
":",
"reader__o",
"=",
"reader",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlReaderNewWalker",
"(",
"reader__o",
",",
"self",
".",
"_o",
")",
"return",
"ret"
] | Setup an xmltextReader to parse a preparsed XML document.
This reuses the existing @reader xmlTextReader. | [
"Setup",
"an",
"xmltextReader",
"to",
"parse",
"a",
"preparsed",
"XML",
"document",
".",
"This",
"reuses",
"the",
"existing"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4831-L4837 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.readerWalker | def readerWalker(self):
"""Create an xmltextReader for a preparsed document. """
ret = libxml2mod.xmlReaderWalker(self._o)
if ret is None:raise treeError('xmlReaderWalker() failed')
__tmp = xmlTextReader(_obj=ret)
return __tmp | python | def readerWalker(self):
"""Create an xmltextReader for a preparsed document. """
ret = libxml2mod.xmlReaderWalker(self._o)
if ret is None:raise treeError('xmlReaderWalker() failed')
__tmp = xmlTextReader(_obj=ret)
return __tmp | [
"def",
"readerWalker",
"(",
"self",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlReaderWalker",
"(",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlReaderWalker() failed'",
")",
"__tmp",
"=",
"xmlTextReader",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Create an xmltextReader for a preparsed document. | [
"Create",
"an",
"xmltextReader",
"for",
"a",
"preparsed",
"document",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4839-L4844 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.schemaNewDocParserCtxt | def schemaNewDocParserCtxt(self):
"""Create an XML Schemas parse context for that document. NB.
The document may be modified during the parsing process. """
ret = libxml2mod.xmlSchemaNewDocParserCtxt(self._o)
if ret is None:raise parserError('xmlSchemaNewDocParserCtxt() failed')
__tmp = SchemaParserCtxt(_obj=ret)
return __tmp | python | def schemaNewDocParserCtxt(self):
"""Create an XML Schemas parse context for that document. NB.
The document may be modified during the parsing process. """
ret = libxml2mod.xmlSchemaNewDocParserCtxt(self._o)
if ret is None:raise parserError('xmlSchemaNewDocParserCtxt() failed')
__tmp = SchemaParserCtxt(_obj=ret)
return __tmp | [
"def",
"schemaNewDocParserCtxt",
"(",
"self",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlSchemaNewDocParserCtxt",
"(",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"parserError",
"(",
"'xmlSchemaNewDocParserCtxt() failed'",
")",
"__tmp",
"=",
"SchemaParserCtxt",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Create an XML Schemas parse context for that document. NB.
The document may be modified during the parsing process. | [
"Create",
"an",
"XML",
"Schemas",
"parse",
"context",
"for",
"that",
"document",
".",
"NB",
".",
"The",
"document",
"may",
"be",
"modified",
"during",
"the",
"parsing",
"process",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4850-L4856 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.schemaValidateDoc | def schemaValidateDoc(self, ctxt):
"""Validate a document tree in memory. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
ret = libxml2mod.xmlSchemaValidateDoc(ctxt__o, self._o)
return ret | python | def schemaValidateDoc(self, ctxt):
"""Validate a document tree in memory. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
ret = libxml2mod.xmlSchemaValidateDoc(ctxt__o, self._o)
return ret | [
"def",
"schemaValidateDoc",
"(",
"self",
",",
"ctxt",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlSchemaValidateDoc",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
")",
"return",
"ret"
] | Validate a document tree in memory. | [
"Validate",
"a",
"document",
"tree",
"in",
"memory",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4858-L4863 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.xpathNewContext | def xpathNewContext(self):
"""Create a new xmlXPathContext """
ret = libxml2mod.xmlXPathNewContext(self._o)
if ret is None:raise xpathError('xmlXPathNewContext() failed')
__tmp = xpathContext(_obj=ret)
return __tmp | python | def xpathNewContext(self):
"""Create a new xmlXPathContext """
ret = libxml2mod.xmlXPathNewContext(self._o)
if ret is None:raise xpathError('xmlXPathNewContext() failed')
__tmp = xpathContext(_obj=ret)
return __tmp | [
"def",
"xpathNewContext",
"(",
"self",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlXPathNewContext",
"(",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"xpathError",
"(",
"'xmlXPathNewContext() failed'",
")",
"__tmp",
"=",
"xpathContext",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Create a new xmlXPathContext | [
"Create",
"a",
"new",
"xmlXPathContext"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4869-L4874 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDoc.xpointerNewContext | def xpointerNewContext(self, here, origin):
"""Create a new XPointer context """
if here is None: here__o = None
else: here__o = here._o
if origin is None: origin__o = None
else: origin__o = origin._o
ret = libxml2mod.xmlXPtrNewContext(self._o, here__o, origin__o)
if ret is None:raise treeError('xmlXPtrNewContext() failed')
__tmp = xpathContext(_obj=ret)
return __tmp | python | def xpointerNewContext(self, here, origin):
"""Create a new XPointer context """
if here is None: here__o = None
else: here__o = here._o
if origin is None: origin__o = None
else: origin__o = origin._o
ret = libxml2mod.xmlXPtrNewContext(self._o, here__o, origin__o)
if ret is None:raise treeError('xmlXPtrNewContext() failed')
__tmp = xpathContext(_obj=ret)
return __tmp | [
"def",
"xpointerNewContext",
"(",
"self",
",",
"here",
",",
"origin",
")",
":",
"if",
"here",
"is",
"None",
":",
"here__o",
"=",
"None",
"else",
":",
"here__o",
"=",
"here",
".",
"_o",
"if",
"origin",
"is",
"None",
":",
"origin__o",
"=",
"None",
"else",
":",
"origin__o",
"=",
"origin",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlXPtrNewContext",
"(",
"self",
".",
"_o",
",",
"here__o",
",",
"origin__o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlXPtrNewContext() failed'",
")",
"__tmp",
"=",
"xpathContext",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Create a new XPointer context | [
"Create",
"a",
"new",
"XPointer",
"context"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4890-L4899 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.doc | def doc(self):
"""Get the document tree from a parser context. """
ret = libxml2mod.xmlParserGetDoc(self._o)
if ret is None:raise parserError('xmlParserGetDoc() failed')
__tmp = xmlDoc(_obj=ret)
return __tmp | python | def doc(self):
"""Get the document tree from a parser context. """
ret = libxml2mod.xmlParserGetDoc(self._o)
if ret is None:raise parserError('xmlParserGetDoc() failed')
__tmp = xmlDoc(_obj=ret)
return __tmp | [
"def",
"doc",
"(",
"self",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlParserGetDoc",
"(",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"parserError",
"(",
"'xmlParserGetDoc() failed'",
")",
"__tmp",
"=",
"xmlDoc",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Get the document tree from a parser context. | [
"Get",
"the",
"document",
"tree",
"from",
"a",
"parser",
"context",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4912-L4917 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.htmlCtxtReadDoc | def htmlCtxtReadDoc(self, cur, URL, encoding, options):
"""parse an XML in-memory document and build a tree. This
reuses the existing @ctxt parser context """
ret = libxml2mod.htmlCtxtReadDoc(self._o, cur, URL, encoding, options)
if ret is None:raise treeError('htmlCtxtReadDoc() failed')
__tmp = xmlDoc(_obj=ret)
return __tmp | python | def htmlCtxtReadDoc(self, cur, URL, encoding, options):
"""parse an XML in-memory document and build a tree. This
reuses the existing @ctxt parser context """
ret = libxml2mod.htmlCtxtReadDoc(self._o, cur, URL, encoding, options)
if ret is None:raise treeError('htmlCtxtReadDoc() failed')
__tmp = xmlDoc(_obj=ret)
return __tmp | [
"def",
"htmlCtxtReadDoc",
"(",
"self",
",",
"cur",
",",
"URL",
",",
"encoding",
",",
"options",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"htmlCtxtReadDoc",
"(",
"self",
".",
"_o",
",",
"cur",
",",
"URL",
",",
"encoding",
",",
"options",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'htmlCtxtReadDoc() failed'",
")",
"__tmp",
"=",
"xmlDoc",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | parse an XML in-memory document and build a tree. This
reuses the existing @ctxt parser context | [
"parse",
"an",
"XML",
"in",
"-",
"memory",
"document",
"and",
"build",
"a",
"tree",
".",
"This",
"reuses",
"the",
"existing"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4953-L4959 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.htmlCtxtReadFd | def htmlCtxtReadFd(self, fd, URL, encoding, options):
"""parse an XML from a file descriptor and build a tree. This
reuses the existing @ctxt parser context """
ret = libxml2mod.htmlCtxtReadFd(self._o, fd, URL, encoding, options)
if ret is None:raise treeError('htmlCtxtReadFd() failed')
__tmp = xmlDoc(_obj=ret)
return __tmp | python | def htmlCtxtReadFd(self, fd, URL, encoding, options):
"""parse an XML from a file descriptor and build a tree. This
reuses the existing @ctxt parser context """
ret = libxml2mod.htmlCtxtReadFd(self._o, fd, URL, encoding, options)
if ret is None:raise treeError('htmlCtxtReadFd() failed')
__tmp = xmlDoc(_obj=ret)
return __tmp | [
"def",
"htmlCtxtReadFd",
"(",
"self",
",",
"fd",
",",
"URL",
",",
"encoding",
",",
"options",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"htmlCtxtReadFd",
"(",
"self",
".",
"_o",
",",
"fd",
",",
"URL",
",",
"encoding",
",",
"options",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'htmlCtxtReadFd() failed'",
")",
"__tmp",
"=",
"xmlDoc",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | parse an XML from a file descriptor and build a tree. This
reuses the existing @ctxt parser context | [
"parse",
"an",
"XML",
"from",
"a",
"file",
"descriptor",
"and",
"build",
"a",
"tree",
".",
"This",
"reuses",
"the",
"existing"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4961-L4967 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.htmlCtxtReadFile | def htmlCtxtReadFile(self, filename, encoding, options):
"""parse an XML file from the filesystem or the network. This
reuses the existing @ctxt parser context """
ret = libxml2mod.htmlCtxtReadFile(self._o, filename, encoding, options)
if ret is None:raise treeError('htmlCtxtReadFile() failed')
__tmp = xmlDoc(_obj=ret)
return __tmp | python | def htmlCtxtReadFile(self, filename, encoding, options):
"""parse an XML file from the filesystem or the network. This
reuses the existing @ctxt parser context """
ret = libxml2mod.htmlCtxtReadFile(self._o, filename, encoding, options)
if ret is None:raise treeError('htmlCtxtReadFile() failed')
__tmp = xmlDoc(_obj=ret)
return __tmp | [
"def",
"htmlCtxtReadFile",
"(",
"self",
",",
"filename",
",",
"encoding",
",",
"options",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"htmlCtxtReadFile",
"(",
"self",
".",
"_o",
",",
"filename",
",",
"encoding",
",",
"options",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'htmlCtxtReadFile() failed'",
")",
"__tmp",
"=",
"xmlDoc",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | parse an XML file from the filesystem or the network. This
reuses the existing @ctxt parser context | [
"parse",
"an",
"XML",
"file",
"from",
"the",
"filesystem",
"or",
"the",
"network",
".",
"This",
"reuses",
"the",
"existing"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4969-L4975 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.htmlCtxtUseOptions | def htmlCtxtUseOptions(self, options):
"""Applies the options to the parser context """
ret = libxml2mod.htmlCtxtUseOptions(self._o, options)
return ret | python | def htmlCtxtUseOptions(self, options):
"""Applies the options to the parser context """
ret = libxml2mod.htmlCtxtUseOptions(self._o, options)
return ret | [
"def",
"htmlCtxtUseOptions",
"(",
"self",
",",
"options",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"htmlCtxtUseOptions",
"(",
"self",
".",
"_o",
",",
"options",
")",
"return",
"ret"
] | Applies the options to the parser context | [
"Applies",
"the",
"options",
"to",
"the",
"parser",
"context"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L4989-L4992 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.htmlParseChunk | def htmlParseChunk(self, chunk, size, terminate):
"""Parse a Chunk of memory """
ret = libxml2mod.htmlParseChunk(self._o, chunk, size, terminate)
return ret | python | def htmlParseChunk(self, chunk, size, terminate):
"""Parse a Chunk of memory """
ret = libxml2mod.htmlParseChunk(self._o, chunk, size, terminate)
return ret | [
"def",
"htmlParseChunk",
"(",
"self",
",",
"chunk",
",",
"size",
",",
"terminate",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"htmlParseChunk",
"(",
"self",
".",
"_o",
",",
"chunk",
",",
"size",
",",
"terminate",
")",
"return",
"ret"
] | Parse a Chunk of memory | [
"Parse",
"a",
"Chunk",
"of",
"memory"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5005-L5008 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.ctxtReadFile | def ctxtReadFile(self, filename, encoding, options):
"""parse an XML file from the filesystem or the network. This
reuses the existing @ctxt parser context """
ret = libxml2mod.xmlCtxtReadFile(self._o, filename, encoding, options)
if ret is None:raise treeError('xmlCtxtReadFile() failed')
__tmp = xmlDoc(_obj=ret)
return __tmp | python | def ctxtReadFile(self, filename, encoding, options):
"""parse an XML file from the filesystem or the network. This
reuses the existing @ctxt parser context """
ret = libxml2mod.xmlCtxtReadFile(self._o, filename, encoding, options)
if ret is None:raise treeError('xmlCtxtReadFile() failed')
__tmp = xmlDoc(_obj=ret)
return __tmp | [
"def",
"ctxtReadFile",
"(",
"self",
",",
"filename",
",",
"encoding",
",",
"options",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlCtxtReadFile",
"(",
"self",
".",
"_o",
",",
"filename",
",",
"encoding",
",",
"options",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlCtxtReadFile() failed'",
")",
"__tmp",
"=",
"xmlDoc",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | parse an XML file from the filesystem or the network. This
reuses the existing @ctxt parser context | [
"parse",
"an",
"XML",
"file",
"from",
"the",
"filesystem",
"or",
"the",
"network",
".",
"This",
"reuses",
"the",
"existing"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5060-L5066 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.ctxtReadMemory | def ctxtReadMemory(self, buffer, size, URL, encoding, options):
"""parse an XML in-memory document and build a tree. This
reuses the existing @ctxt parser context """
ret = libxml2mod.xmlCtxtReadMemory(self._o, buffer, size, URL, encoding, options)
if ret is None:raise treeError('xmlCtxtReadMemory() failed')
__tmp = xmlDoc(_obj=ret)
return __tmp | python | def ctxtReadMemory(self, buffer, size, URL, encoding, options):
"""parse an XML in-memory document and build a tree. This
reuses the existing @ctxt parser context """
ret = libxml2mod.xmlCtxtReadMemory(self._o, buffer, size, URL, encoding, options)
if ret is None:raise treeError('xmlCtxtReadMemory() failed')
__tmp = xmlDoc(_obj=ret)
return __tmp | [
"def",
"ctxtReadMemory",
"(",
"self",
",",
"buffer",
",",
"size",
",",
"URL",
",",
"encoding",
",",
"options",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlCtxtReadMemory",
"(",
"self",
".",
"_o",
",",
"buffer",
",",
"size",
",",
"URL",
",",
"encoding",
",",
"options",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlCtxtReadMemory() failed'",
")",
"__tmp",
"=",
"xmlDoc",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | parse an XML in-memory document and build a tree. This
reuses the existing @ctxt parser context | [
"parse",
"an",
"XML",
"in",
"-",
"memory",
"document",
"and",
"build",
"a",
"tree",
".",
"This",
"reuses",
"the",
"existing"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5068-L5074 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.ctxtResetPush | def ctxtResetPush(self, chunk, size, filename, encoding):
"""Reset a push parser context """
ret = libxml2mod.xmlCtxtResetPush(self._o, chunk, size, filename, encoding)
return ret | python | def ctxtResetPush(self, chunk, size, filename, encoding):
"""Reset a push parser context """
ret = libxml2mod.xmlCtxtResetPush(self._o, chunk, size, filename, encoding)
return ret | [
"def",
"ctxtResetPush",
"(",
"self",
",",
"chunk",
",",
"size",
",",
"filename",
",",
"encoding",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlCtxtResetPush",
"(",
"self",
".",
"_o",
",",
"chunk",
",",
"size",
",",
"filename",
",",
"encoding",
")",
"return",
"ret"
] | Reset a push parser context | [
"Reset",
"a",
"push",
"parser",
"context"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5080-L5083 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.ctxtUseOptions | def ctxtUseOptions(self, options):
"""Applies the options to the parser context """
ret = libxml2mod.xmlCtxtUseOptions(self._o, options)
return ret | python | def ctxtUseOptions(self, options):
"""Applies the options to the parser context """
ret = libxml2mod.xmlCtxtUseOptions(self._o, options)
return ret | [
"def",
"ctxtUseOptions",
"(",
"self",
",",
"options",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlCtxtUseOptions",
"(",
"self",
".",
"_o",
",",
"options",
")",
"return",
"ret"
] | Applies the options to the parser context | [
"Applies",
"the",
"options",
"to",
"the",
"parser",
"context"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5085-L5088 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.parseChunk | def parseChunk(self, chunk, size, terminate):
"""Parse a Chunk of memory """
ret = libxml2mod.xmlParseChunk(self._o, chunk, size, terminate)
return ret | python | def parseChunk(self, chunk, size, terminate):
"""Parse a Chunk of memory """
ret = libxml2mod.xmlParseChunk(self._o, chunk, size, terminate)
return ret | [
"def",
"parseChunk",
"(",
"self",
",",
"chunk",
",",
"size",
",",
"terminate",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlParseChunk",
"(",
"self",
".",
"_o",
",",
"chunk",
",",
"size",
",",
"terminate",
")",
"return",
"ret"
] | Parse a Chunk of memory | [
"Parse",
"a",
"Chunk",
"of",
"memory"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5095-L5098 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.setupParserForBuffer | def setupParserForBuffer(self, buffer, filename):
"""Setup the parser context to parse a new buffer; Clears any
prior contents from the parser context. The buffer
parameter must not be None, but the filename parameter can
be """
libxml2mod.xmlSetupParserForBuffer(self._o, buffer, filename) | python | def setupParserForBuffer(self, buffer, filename):
"""Setup the parser context to parse a new buffer; Clears any
prior contents from the parser context. The buffer
parameter must not be None, but the filename parameter can
be """
libxml2mod.xmlSetupParserForBuffer(self._o, buffer, filename) | [
"def",
"setupParserForBuffer",
"(",
"self",
",",
"buffer",
",",
"filename",
")",
":",
"libxml2mod",
".",
"xmlSetupParserForBuffer",
"(",
"self",
".",
"_o",
",",
"buffer",
",",
"filename",
")"
] | Setup the parser context to parse a new buffer; Clears any
prior contents from the parser context. The buffer
parameter must not be None, but the filename parameter can
be | [
"Setup",
"the",
"parser",
"context",
"to",
"parse",
"a",
"new",
"buffer",
";",
"Clears",
"any",
"prior",
"contents",
"from",
"the",
"parser",
"context",
".",
"The",
"buffer",
"parameter",
"must",
"not",
"be",
"None",
"but",
"the",
"filename",
"parameter",
"can",
"be"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5114-L5119 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.decodeEntities | def decodeEntities(self, len, what, end, end2, end3):
"""This function is deprecated, we now always process entities
content through xmlStringDecodeEntities TODO: remove it in
next major release. [67] Reference ::= EntityRef | CharRef
[69] PEReference ::= '%' Name ';' """
ret = libxml2mod.xmlDecodeEntities(self._o, len, what, end, end2, end3)
return ret | python | def decodeEntities(self, len, what, end, end2, end3):
"""This function is deprecated, we now always process entities
content through xmlStringDecodeEntities TODO: remove it in
next major release. [67] Reference ::= EntityRef | CharRef
[69] PEReference ::= '%' Name ';' """
ret = libxml2mod.xmlDecodeEntities(self._o, len, what, end, end2, end3)
return ret | [
"def",
"decodeEntities",
"(",
"self",
",",
"len",
",",
"what",
",",
"end",
",",
"end2",
",",
"end3",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlDecodeEntities",
"(",
"self",
".",
"_o",
",",
"len",
",",
"what",
",",
"end",
",",
"end2",
",",
"end3",
")",
"return",
"ret"
] | This function is deprecated, we now always process entities
content through xmlStringDecodeEntities TODO: remove it in
next major release. [67] Reference ::= EntityRef | CharRef
[69] PEReference ::= '%' Name ';' | [
"This",
"function",
"is",
"deprecated",
"we",
"now",
"always",
"process",
"entities",
"content",
"through",
"xmlStringDecodeEntities",
"TODO",
":",
"remove",
"it",
"in",
"next",
"major",
"release",
".",
"[",
"67",
"]",
"Reference",
"::",
"=",
"EntityRef",
"|",
"CharRef",
"[",
"69",
"]",
"PEReference",
"::",
"=",
"%",
"Name",
";"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5129-L5135 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.handleEntity | def handleEntity(self, entity):
"""Default handling of defined entities, when should we define
a new input stream ? When do we just handle that as a set
of chars ? OBSOLETE: to be removed at some point. """
if entity is None: entity__o = None
else: entity__o = entity._o
libxml2mod.xmlHandleEntity(self._o, entity__o) | python | def handleEntity(self, entity):
"""Default handling of defined entities, when should we define
a new input stream ? When do we just handle that as a set
of chars ? OBSOLETE: to be removed at some point. """
if entity is None: entity__o = None
else: entity__o = entity._o
libxml2mod.xmlHandleEntity(self._o, entity__o) | [
"def",
"handleEntity",
"(",
"self",
",",
"entity",
")",
":",
"if",
"entity",
"is",
"None",
":",
"entity__o",
"=",
"None",
"else",
":",
"entity__o",
"=",
"entity",
".",
"_o",
"libxml2mod",
".",
"xmlHandleEntity",
"(",
"self",
".",
"_o",
",",
"entity__o",
")"
] | Default handling of defined entities, when should we define
a new input stream ? When do we just handle that as a set
of chars ? OBSOLETE: to be removed at some point. | [
"Default",
"handling",
"of",
"defined",
"entities",
"when",
"should",
"we",
"define",
"a",
"new",
"input",
"stream",
"?",
"When",
"do",
"we",
"just",
"handle",
"that",
"as",
"a",
"set",
"of",
"chars",
"?",
"OBSOLETE",
":",
"to",
"be",
"removed",
"at",
"some",
"point",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5137-L5143 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.parseEntityRef | def parseEntityRef(self):
"""parse ENTITY references declarations [68] EntityRef ::=
'&' Name ';' [ WFC: Entity Declared ] In a document
without any DTD, a document with only an internal DTD
subset which contains no parameter entity references, or a
document with "standalone='yes'", the Name given in the
entity reference must match that in an entity declaration,
except that well-formed documents need not declare any of
the following entities: amp, lt, gt, apos, quot. The
declaration of a parameter entity must precede any
reference to it. Similarly, the declaration of a general
entity must precede any reference to it which appears in a
default value in an attribute-list declaration. Note that
if entities are declared in the external subset or in
external parameter entities, a non-validating processor is
not obligated to read and process their declarations; for
such documents, the rule that an entity must be declared is
a well-formedness constraint only if standalone='yes'. [
WFC: Parsed Entity ] An entity reference must not contain
the name of an unparsed entity """
ret = libxml2mod.xmlParseEntityRef(self._o)
if ret is None:raise parserError('xmlParseEntityRef() failed')
__tmp = xmlEntity(_obj=ret)
return __tmp | python | def parseEntityRef(self):
"""parse ENTITY references declarations [68] EntityRef ::=
'&' Name ';' [ WFC: Entity Declared ] In a document
without any DTD, a document with only an internal DTD
subset which contains no parameter entity references, or a
document with "standalone='yes'", the Name given in the
entity reference must match that in an entity declaration,
except that well-formed documents need not declare any of
the following entities: amp, lt, gt, apos, quot. The
declaration of a parameter entity must precede any
reference to it. Similarly, the declaration of a general
entity must precede any reference to it which appears in a
default value in an attribute-list declaration. Note that
if entities are declared in the external subset or in
external parameter entities, a non-validating processor is
not obligated to read and process their declarations; for
such documents, the rule that an entity must be declared is
a well-formedness constraint only if standalone='yes'. [
WFC: Parsed Entity ] An entity reference must not contain
the name of an unparsed entity """
ret = libxml2mod.xmlParseEntityRef(self._o)
if ret is None:raise parserError('xmlParseEntityRef() failed')
__tmp = xmlEntity(_obj=ret)
return __tmp | [
"def",
"parseEntityRef",
"(",
"self",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlParseEntityRef",
"(",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"parserError",
"(",
"'xmlParseEntityRef() failed'",
")",
"__tmp",
"=",
"xmlEntity",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | parse ENTITY references declarations [68] EntityRef ::=
'&' Name ';' [ WFC: Entity Declared ] In a document
without any DTD, a document with only an internal DTD
subset which contains no parameter entity references, or a
document with "standalone='yes'", the Name given in the
entity reference must match that in an entity declaration,
except that well-formed documents need not declare any of
the following entities: amp, lt, gt, apos, quot. The
declaration of a parameter entity must precede any
reference to it. Similarly, the declaration of a general
entity must precede any reference to it which appears in a
default value in an attribute-list declaration. Note that
if entities are declared in the external subset or in
external parameter entities, a non-validating processor is
not obligated to read and process their declarations; for
such documents, the rule that an entity must be declared is
a well-formedness constraint only if standalone='yes'. [
WFC: Parsed Entity ] An entity reference must not contain
the name of an unparsed entity | [
"parse",
"ENTITY",
"references",
"declarations",
"[",
"68",
"]",
"EntityRef",
"::",
"=",
"&",
"Name",
";",
"[",
"WFC",
":",
"Entity",
"Declared",
"]",
"In",
"a",
"document",
"without",
"any",
"DTD",
"a",
"document",
"with",
"only",
"an",
"internal",
"DTD",
"subset",
"which",
"contains",
"no",
"parameter",
"entity",
"references",
"or",
"a",
"document",
"with",
"standalone",
"=",
"yes",
"the",
"Name",
"given",
"in",
"the",
"entity",
"reference",
"must",
"match",
"that",
"in",
"an",
"entity",
"declaration",
"except",
"that",
"well",
"-",
"formed",
"documents",
"need",
"not",
"declare",
"any",
"of",
"the",
"following",
"entities",
":",
"amp",
"lt",
"gt",
"apos",
"quot",
".",
"The",
"declaration",
"of",
"a",
"parameter",
"entity",
"must",
"precede",
"any",
"reference",
"to",
"it",
".",
"Similarly",
"the",
"declaration",
"of",
"a",
"general",
"entity",
"must",
"precede",
"any",
"reference",
"to",
"it",
"which",
"appears",
"in",
"a",
"default",
"value",
"in",
"an",
"attribute",
"-",
"list",
"declaration",
".",
"Note",
"that",
"if",
"entities",
"are",
"declared",
"in",
"the",
"external",
"subset",
"or",
"in",
"external",
"parameter",
"entities",
"a",
"non",
"-",
"validating",
"processor",
"is",
"not",
"obligated",
"to",
"read",
"and",
"process",
"their",
"declarations",
";",
"for",
"such",
"documents",
"the",
"rule",
"that",
"an",
"entity",
"must",
"be",
"declared",
"is",
"a",
"well",
"-",
"formedness",
"constraint",
"only",
"if",
"standalone",
"=",
"yes",
".",
"[",
"WFC",
":",
"Parsed",
"Entity",
"]",
"An",
"entity",
"reference",
"must",
"not",
"contain",
"the",
"name",
"of",
"an",
"unparsed",
"entity"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5288-L5311 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.parseExternalSubset | def parseExternalSubset(self, ExternalID, SystemID):
"""parse Markup declarations from an external subset [30]
extSubset ::= textDecl? extSubsetDecl [31] extSubsetDecl
::= (markupdecl | conditionalSect | PEReference | S) * """
libxml2mod.xmlParseExternalSubset(self._o, ExternalID, SystemID) | python | def parseExternalSubset(self, ExternalID, SystemID):
"""parse Markup declarations from an external subset [30]
extSubset ::= textDecl? extSubsetDecl [31] extSubsetDecl
::= (markupdecl | conditionalSect | PEReference | S) * """
libxml2mod.xmlParseExternalSubset(self._o, ExternalID, SystemID) | [
"def",
"parseExternalSubset",
"(",
"self",
",",
"ExternalID",
",",
"SystemID",
")",
":",
"libxml2mod",
".",
"xmlParseExternalSubset",
"(",
"self",
".",
"_o",
",",
"ExternalID",
",",
"SystemID",
")"
] | parse Markup declarations from an external subset [30]
extSubset ::= textDecl? extSubsetDecl [31] extSubsetDecl
::= (markupdecl | conditionalSect | PEReference | S) * | [
"parse",
"Markup",
"declarations",
"from",
"an",
"external",
"subset",
"[",
"30",
"]",
"extSubset",
"::",
"=",
"textDecl?",
"extSubsetDecl",
"[",
"31",
"]",
"extSubsetDecl",
"::",
"=",
"(",
"markupdecl",
"|",
"conditionalSect",
"|",
"PEReference",
"|",
"S",
")",
"*"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5313-L5317 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.stringDecodeEntities | def stringDecodeEntities(self, str, what, end, end2, end3):
"""Takes a entity string content and process to do the
adequate substitutions. [67] Reference ::= EntityRef |
CharRef [69] PEReference ::= '%' Name ';' """
ret = libxml2mod.xmlStringDecodeEntities(self._o, str, what, end, end2, end3)
return ret | python | def stringDecodeEntities(self, str, what, end, end2, end3):
"""Takes a entity string content and process to do the
adequate substitutions. [67] Reference ::= EntityRef |
CharRef [69] PEReference ::= '%' Name ';' """
ret = libxml2mod.xmlStringDecodeEntities(self._o, str, what, end, end2, end3)
return ret | [
"def",
"stringDecodeEntities",
"(",
"self",
",",
"str",
",",
"what",
",",
"end",
",",
"end2",
",",
"end3",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlStringDecodeEntities",
"(",
"self",
".",
"_o",
",",
"str",
",",
"what",
",",
"end",
",",
"end2",
",",
"end3",
")",
"return",
"ret"
] | Takes a entity string content and process to do the
adequate substitutions. [67] Reference ::= EntityRef |
CharRef [69] PEReference ::= '%' Name ';' | [
"Takes",
"a",
"entity",
"string",
"content",
"and",
"process",
"to",
"do",
"the",
"adequate",
"substitutions",
".",
"[",
"67",
"]",
"Reference",
"::",
"=",
"EntityRef",
"|",
"CharRef",
"[",
"69",
"]",
"PEReference",
"::",
"=",
"%",
"Name",
";"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5546-L5551 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | parserCtxt.stringLenDecodeEntities | def stringLenDecodeEntities(self, str, len, what, end, end2, end3):
"""Takes a entity string content and process to do the
adequate substitutions. [67] Reference ::= EntityRef |
CharRef [69] PEReference ::= '%' Name ';' """
ret = libxml2mod.xmlStringLenDecodeEntities(self._o, str, len, what, end, end2, end3)
return ret | python | def stringLenDecodeEntities(self, str, len, what, end, end2, end3):
"""Takes a entity string content and process to do the
adequate substitutions. [67] Reference ::= EntityRef |
CharRef [69] PEReference ::= '%' Name ';' """
ret = libxml2mod.xmlStringLenDecodeEntities(self._o, str, len, what, end, end2, end3)
return ret | [
"def",
"stringLenDecodeEntities",
"(",
"self",
",",
"str",
",",
"len",
",",
"what",
",",
"end",
",",
"end2",
",",
"end3",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlStringLenDecodeEntities",
"(",
"self",
".",
"_o",
",",
"str",
",",
"len",
",",
"what",
",",
"end",
",",
"end2",
",",
"end3",
")",
"return",
"ret"
] | Takes a entity string content and process to do the
adequate substitutions. [67] Reference ::= EntityRef |
CharRef [69] PEReference ::= '%' Name ';' | [
"Takes",
"a",
"entity",
"string",
"content",
"and",
"process",
"to",
"do",
"the",
"adequate",
"substitutions",
".",
"[",
"67",
"]",
"Reference",
"::",
"=",
"EntityRef",
"|",
"CharRef",
"[",
"69",
"]",
"PEReference",
"::",
"=",
"%",
"Name",
";"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5553-L5558 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlAttr.debugDumpAttr | def debugDumpAttr(self, output, depth):
"""Dumps debug information for the attribute """
libxml2mod.xmlDebugDumpAttr(output, self._o, depth) | python | def debugDumpAttr(self, output, depth):
"""Dumps debug information for the attribute """
libxml2mod.xmlDebugDumpAttr(output, self._o, depth) | [
"def",
"debugDumpAttr",
"(",
"self",
",",
"output",
",",
"depth",
")",
":",
"libxml2mod",
".",
"xmlDebugDumpAttr",
"(",
"output",
",",
"self",
".",
"_o",
",",
"depth",
")"
] | Dumps debug information for the attribute | [
"Dumps",
"debug",
"information",
"for",
"the",
"attribute"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5573-L5575 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlAttr.debugDumpAttrList | def debugDumpAttrList(self, output, depth):
"""Dumps debug information for the attribute list """
libxml2mod.xmlDebugDumpAttrList(output, self._o, depth) | python | def debugDumpAttrList(self, output, depth):
"""Dumps debug information for the attribute list """
libxml2mod.xmlDebugDumpAttrList(output, self._o, depth) | [
"def",
"debugDumpAttrList",
"(",
"self",
",",
"output",
",",
"depth",
")",
":",
"libxml2mod",
".",
"xmlDebugDumpAttrList",
"(",
"output",
",",
"self",
".",
"_o",
",",
"depth",
")"
] | Dumps debug information for the attribute list | [
"Dumps",
"debug",
"information",
"for",
"the",
"attribute",
"list"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5577-L5579 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlAttr.copyProp | def copyProp(self, target):
"""Do a copy of the attribute. """
if target is None: target__o = None
else: target__o = target._o
ret = libxml2mod.xmlCopyProp(target__o, self._o)
if ret is None:raise treeError('xmlCopyProp() failed')
__tmp = xmlAttr(_obj=ret)
return __tmp | python | def copyProp(self, target):
"""Do a copy of the attribute. """
if target is None: target__o = None
else: target__o = target._o
ret = libxml2mod.xmlCopyProp(target__o, self._o)
if ret is None:raise treeError('xmlCopyProp() failed')
__tmp = xmlAttr(_obj=ret)
return __tmp | [
"def",
"copyProp",
"(",
"self",
",",
"target",
")",
":",
"if",
"target",
"is",
"None",
":",
"target__o",
"=",
"None",
"else",
":",
"target__o",
"=",
"target",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlCopyProp",
"(",
"target__o",
",",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlCopyProp() failed'",
")",
"__tmp",
"=",
"xmlAttr",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Do a copy of the attribute. | [
"Do",
"a",
"copy",
"of",
"the",
"attribute",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5585-L5592 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlAttr.copyPropList | def copyPropList(self, target):
"""Do a copy of an attribute list. """
if target is None: target__o = None
else: target__o = target._o
ret = libxml2mod.xmlCopyPropList(target__o, self._o)
if ret is None:raise treeError('xmlCopyPropList() failed')
__tmp = xmlAttr(_obj=ret)
return __tmp | python | def copyPropList(self, target):
"""Do a copy of an attribute list. """
if target is None: target__o = None
else: target__o = target._o
ret = libxml2mod.xmlCopyPropList(target__o, self._o)
if ret is None:raise treeError('xmlCopyPropList() failed')
__tmp = xmlAttr(_obj=ret)
return __tmp | [
"def",
"copyPropList",
"(",
"self",
",",
"target",
")",
":",
"if",
"target",
"is",
"None",
":",
"target__o",
"=",
"None",
"else",
":",
"target__o",
"=",
"target",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlCopyPropList",
"(",
"target__o",
",",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlCopyPropList() failed'",
")",
"__tmp",
"=",
"xmlAttr",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Do a copy of an attribute list. | [
"Do",
"a",
"copy",
"of",
"an",
"attribute",
"list",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5594-L5601 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlAttr.removeID | def removeID(self, doc):
"""Remove the given attribute from the ID table maintained
internally. """
if doc is None: doc__o = None
else: doc__o = doc._o
ret = libxml2mod.xmlRemoveID(doc__o, self._o)
return ret | python | def removeID(self, doc):
"""Remove the given attribute from the ID table maintained
internally. """
if doc is None: doc__o = None
else: doc__o = doc._o
ret = libxml2mod.xmlRemoveID(doc__o, self._o)
return ret | [
"def",
"removeID",
"(",
"self",
",",
"doc",
")",
":",
"if",
"doc",
"is",
"None",
":",
"doc__o",
"=",
"None",
"else",
":",
"doc__o",
"=",
"doc",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlRemoveID",
"(",
"doc__o",
",",
"self",
".",
"_o",
")",
"return",
"ret"
] | Remove the given attribute from the ID table maintained
internally. | [
"Remove",
"the",
"given",
"attribute",
"from",
"the",
"ID",
"table",
"maintained",
"internally",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5622-L5628 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlAttr.removeRef | def removeRef(self, doc):
"""Remove the given attribute from the Ref table maintained
internally. """
if doc is None: doc__o = None
else: doc__o = doc._o
ret = libxml2mod.xmlRemoveRef(doc__o, self._o)
return ret | python | def removeRef(self, doc):
"""Remove the given attribute from the Ref table maintained
internally. """
if doc is None: doc__o = None
else: doc__o = doc._o
ret = libxml2mod.xmlRemoveRef(doc__o, self._o)
return ret | [
"def",
"removeRef",
"(",
"self",
",",
"doc",
")",
":",
"if",
"doc",
"is",
"None",
":",
"doc__o",
"=",
"None",
"else",
":",
"doc__o",
"=",
"doc",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlRemoveRef",
"(",
"doc__o",
",",
"self",
".",
"_o",
")",
"return",
"ret"
] | Remove the given attribute from the Ref table maintained
internally. | [
"Remove",
"the",
"given",
"attribute",
"from",
"the",
"Ref",
"table",
"maintained",
"internally",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5630-L5636 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | catalog.add | def add(self, type, orig, replace):
"""Add an entry in the catalog, it may overwrite existing but
different entries. """
ret = libxml2mod.xmlACatalogAdd(self._o, type, orig, replace)
return ret | python | def add(self, type, orig, replace):
"""Add an entry in the catalog, it may overwrite existing but
different entries. """
ret = libxml2mod.xmlACatalogAdd(self._o, type, orig, replace)
return ret | [
"def",
"add",
"(",
"self",
",",
"type",
",",
"orig",
",",
"replace",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlACatalogAdd",
"(",
"self",
".",
"_o",
",",
"type",
",",
"orig",
",",
"replace",
")",
"return",
"ret"
] | Add an entry in the catalog, it may overwrite existing but
different entries. | [
"Add",
"an",
"entry",
"in",
"the",
"catalog",
"it",
"may",
"overwrite",
"existing",
"but",
"different",
"entries",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5661-L5665 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | catalog.remove | def remove(self, value):
"""Remove an entry from the catalog """
ret = libxml2mod.xmlACatalogRemove(self._o, value)
return ret | python | def remove(self, value):
"""Remove an entry from the catalog """
ret = libxml2mod.xmlACatalogRemove(self._o, value)
return ret | [
"def",
"remove",
"(",
"self",
",",
"value",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlACatalogRemove",
"(",
"self",
".",
"_o",
",",
"value",
")",
"return",
"ret"
] | Remove an entry from the catalog | [
"Remove",
"an",
"entry",
"from",
"the",
"catalog"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5681-L5684 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | catalog.resolve | def resolve(self, pubID, sysID):
"""Do a complete resolution lookup of an External Identifier """
ret = libxml2mod.xmlACatalogResolve(self._o, pubID, sysID)
return ret | python | def resolve(self, pubID, sysID):
"""Do a complete resolution lookup of an External Identifier """
ret = libxml2mod.xmlACatalogResolve(self._o, pubID, sysID)
return ret | [
"def",
"resolve",
"(",
"self",
",",
"pubID",
",",
"sysID",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlACatalogResolve",
"(",
"self",
".",
"_o",
",",
"pubID",
",",
"sysID",
")",
"return",
"ret"
] | Do a complete resolution lookup of an External Identifier | [
"Do",
"a",
"complete",
"resolution",
"lookup",
"of",
"an",
"External",
"Identifier"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5686-L5689 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | catalog.resolvePublic | def resolvePublic(self, pubID):
"""Try to lookup the catalog local reference associated to a
public ID in that catalog """
ret = libxml2mod.xmlACatalogResolvePublic(self._o, pubID)
return ret | python | def resolvePublic(self, pubID):
"""Try to lookup the catalog local reference associated to a
public ID in that catalog """
ret = libxml2mod.xmlACatalogResolvePublic(self._o, pubID)
return ret | [
"def",
"resolvePublic",
"(",
"self",
",",
"pubID",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlACatalogResolvePublic",
"(",
"self",
".",
"_o",
",",
"pubID",
")",
"return",
"ret"
] | Try to lookup the catalog local reference associated to a
public ID in that catalog | [
"Try",
"to",
"lookup",
"the",
"catalog",
"local",
"reference",
"associated",
"to",
"a",
"public",
"ID",
"in",
"that",
"catalog"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5691-L5695 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | catalog.resolveSystem | def resolveSystem(self, sysID):
"""Try to lookup the catalog resource for a system ID """
ret = libxml2mod.xmlACatalogResolveSystem(self._o, sysID)
return ret | python | def resolveSystem(self, sysID):
"""Try to lookup the catalog resource for a system ID """
ret = libxml2mod.xmlACatalogResolveSystem(self._o, sysID)
return ret | [
"def",
"resolveSystem",
"(",
"self",
",",
"sysID",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlACatalogResolveSystem",
"(",
"self",
".",
"_o",
",",
"sysID",
")",
"return",
"ret"
] | Try to lookup the catalog resource for a system ID | [
"Try",
"to",
"lookup",
"the",
"catalog",
"resource",
"for",
"a",
"system",
"ID"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5697-L5700 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | catalog.resolveURI | def resolveURI(self, URI):
"""Do a complete resolution lookup of an URI """
ret = libxml2mod.xmlACatalogResolveURI(self._o, URI)
return ret | python | def resolveURI(self, URI):
"""Do a complete resolution lookup of an URI """
ret = libxml2mod.xmlACatalogResolveURI(self._o, URI)
return ret | [
"def",
"resolveURI",
"(",
"self",
",",
"URI",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlACatalogResolveURI",
"(",
"self",
".",
"_o",
",",
"URI",
")",
"return",
"ret"
] | Do a complete resolution lookup of an URI | [
"Do",
"a",
"complete",
"resolution",
"lookup",
"of",
"an",
"URI"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5702-L5705 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDtd.copyDtd | def copyDtd(self):
"""Do a copy of the dtd. """
ret = libxml2mod.xmlCopyDtd(self._o)
if ret is None:raise treeError('xmlCopyDtd() failed')
__tmp = xmlDtd(_obj=ret)
return __tmp | python | def copyDtd(self):
"""Do a copy of the dtd. """
ret = libxml2mod.xmlCopyDtd(self._o)
if ret is None:raise treeError('xmlCopyDtd() failed')
__tmp = xmlDtd(_obj=ret)
return __tmp | [
"def",
"copyDtd",
"(",
"self",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlCopyDtd",
"(",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlCopyDtd() failed'",
")",
"__tmp",
"=",
"xmlDtd",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Do a copy of the dtd. | [
"Do",
"a",
"copy",
"of",
"the",
"dtd",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5728-L5733 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDtd.dtdAttrDesc | def dtdAttrDesc(self, elem, name):
"""Search the DTD for the description of this attribute on
this element. """
ret = libxml2mod.xmlGetDtdAttrDesc(self._o, elem, name)
if ret is None:raise treeError('xmlGetDtdAttrDesc() failed')
__tmp = xmlAttribute(_obj=ret)
return __tmp | python | def dtdAttrDesc(self, elem, name):
"""Search the DTD for the description of this attribute on
this element. """
ret = libxml2mod.xmlGetDtdAttrDesc(self._o, elem, name)
if ret is None:raise treeError('xmlGetDtdAttrDesc() failed')
__tmp = xmlAttribute(_obj=ret)
return __tmp | [
"def",
"dtdAttrDesc",
"(",
"self",
",",
"elem",
",",
"name",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlGetDtdAttrDesc",
"(",
"self",
".",
"_o",
",",
"elem",
",",
"name",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlGetDtdAttrDesc() failed'",
")",
"__tmp",
"=",
"xmlAttribute",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Search the DTD for the description of this attribute on
this element. | [
"Search",
"the",
"DTD",
"for",
"the",
"description",
"of",
"this",
"attribute",
"on",
"this",
"element",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5743-L5749 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDtd.dtdElementDesc | def dtdElementDesc(self, name):
"""Search the DTD for the description of this element """
ret = libxml2mod.xmlGetDtdElementDesc(self._o, name)
if ret is None:raise treeError('xmlGetDtdElementDesc() failed')
__tmp = xmlElement(_obj=ret)
return __tmp | python | def dtdElementDesc(self, name):
"""Search the DTD for the description of this element """
ret = libxml2mod.xmlGetDtdElementDesc(self._o, name)
if ret is None:raise treeError('xmlGetDtdElementDesc() failed')
__tmp = xmlElement(_obj=ret)
return __tmp | [
"def",
"dtdElementDesc",
"(",
"self",
",",
"name",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlGetDtdElementDesc",
"(",
"self",
".",
"_o",
",",
"name",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlGetDtdElementDesc() failed'",
")",
"__tmp",
"=",
"xmlElement",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Search the DTD for the description of this element | [
"Search",
"the",
"DTD",
"for",
"the",
"description",
"of",
"this",
"element"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5751-L5756 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDtd.dtdQAttrDesc | def dtdQAttrDesc(self, elem, name, prefix):
"""Search the DTD for the description of this qualified
attribute on this element. """
ret = libxml2mod.xmlGetDtdQAttrDesc(self._o, elem, name, prefix)
if ret is None:raise treeError('xmlGetDtdQAttrDesc() failed')
__tmp = xmlAttribute(_obj=ret)
return __tmp | python | def dtdQAttrDesc(self, elem, name, prefix):
"""Search the DTD for the description of this qualified
attribute on this element. """
ret = libxml2mod.xmlGetDtdQAttrDesc(self._o, elem, name, prefix)
if ret is None:raise treeError('xmlGetDtdQAttrDesc() failed')
__tmp = xmlAttribute(_obj=ret)
return __tmp | [
"def",
"dtdQAttrDesc",
"(",
"self",
",",
"elem",
",",
"name",
",",
"prefix",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlGetDtdQAttrDesc",
"(",
"self",
".",
"_o",
",",
"elem",
",",
"name",
",",
"prefix",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlGetDtdQAttrDesc() failed'",
")",
"__tmp",
"=",
"xmlAttribute",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Search the DTD for the description of this qualified
attribute on this element. | [
"Search",
"the",
"DTD",
"for",
"the",
"description",
"of",
"this",
"qualified",
"attribute",
"on",
"this",
"element",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5758-L5764 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlDtd.dtdQElementDesc | def dtdQElementDesc(self, name, prefix):
"""Search the DTD for the description of this element """
ret = libxml2mod.xmlGetDtdQElementDesc(self._o, name, prefix)
if ret is None:raise treeError('xmlGetDtdQElementDesc() failed')
__tmp = xmlElement(_obj=ret)
return __tmp | python | def dtdQElementDesc(self, name, prefix):
"""Search the DTD for the description of this element """
ret = libxml2mod.xmlGetDtdQElementDesc(self._o, name, prefix)
if ret is None:raise treeError('xmlGetDtdQElementDesc() failed')
__tmp = xmlElement(_obj=ret)
return __tmp | [
"def",
"dtdQElementDesc",
"(",
"self",
",",
"name",
",",
"prefix",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlGetDtdQElementDesc",
"(",
"self",
".",
"_o",
",",
"name",
",",
"prefix",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlGetDtdQElementDesc() failed'",
")",
"__tmp",
"=",
"xmlElement",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Search the DTD for the description of this element | [
"Search",
"the",
"DTD",
"for",
"the",
"description",
"of",
"this",
"element"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5766-L5771 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlEntity.handleEntity | def handleEntity(self, ctxt):
"""Default handling of defined entities, when should we define
a new input stream ? When do we just handle that as a set
of chars ? OBSOLETE: to be removed at some point. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
libxml2mod.xmlHandleEntity(ctxt__o, self._o) | python | def handleEntity(self, ctxt):
"""Default handling of defined entities, when should we define
a new input stream ? When do we just handle that as a set
of chars ? OBSOLETE: to be removed at some point. """
if ctxt is None: ctxt__o = None
else: ctxt__o = ctxt._o
libxml2mod.xmlHandleEntity(ctxt__o, self._o) | [
"def",
"handleEntity",
"(",
"self",
",",
"ctxt",
")",
":",
"if",
"ctxt",
"is",
"None",
":",
"ctxt__o",
"=",
"None",
"else",
":",
"ctxt__o",
"=",
"ctxt",
".",
"_o",
"libxml2mod",
".",
"xmlHandleEntity",
"(",
"ctxt__o",
",",
"self",
".",
"_o",
")"
] | Default handling of defined entities, when should we define
a new input stream ? When do we just handle that as a set
of chars ? OBSOLETE: to be removed at some point. | [
"Default",
"handling",
"of",
"defined",
"entities",
"when",
"should",
"we",
"define",
"a",
"new",
"input",
"stream",
"?",
"When",
"do",
"we",
"just",
"handle",
"that",
"as",
"a",
"set",
"of",
"chars",
"?",
"OBSOLETE",
":",
"to",
"be",
"removed",
"at",
"some",
"point",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5795-L5801 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | Error.copyError | def copyError(self, to):
"""Save the original error to the new place. """
if to is None: to__o = None
else: to__o = to._o
ret = libxml2mod.xmlCopyError(self._o, to__o)
return ret | python | def copyError(self, to):
"""Save the original error to the new place. """
if to is None: to__o = None
else: to__o = to._o
ret = libxml2mod.xmlCopyError(self._o, to__o)
return ret | [
"def",
"copyError",
"(",
"self",
",",
"to",
")",
":",
"if",
"to",
"is",
"None",
":",
"to__o",
"=",
"None",
"else",
":",
"to__o",
"=",
"to",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlCopyError",
"(",
"self",
".",
"_o",
",",
"to__o",
")",
"return",
"ret"
] | Save the original error to the new place. | [
"Save",
"the",
"original",
"error",
"to",
"the",
"new",
"place",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5843-L5848 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.copyNamespace | def copyNamespace(self):
"""Do a copy of the namespace. """
ret = libxml2mod.xmlCopyNamespace(self._o)
if ret is None:raise treeError('xmlCopyNamespace() failed')
__tmp = xmlNs(_obj=ret)
return __tmp | python | def copyNamespace(self):
"""Do a copy of the namespace. """
ret = libxml2mod.xmlCopyNamespace(self._o)
if ret is None:raise treeError('xmlCopyNamespace() failed')
__tmp = xmlNs(_obj=ret)
return __tmp | [
"def",
"copyNamespace",
"(",
"self",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlCopyNamespace",
"(",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlCopyNamespace() failed'",
")",
"__tmp",
"=",
"xmlNs",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Do a copy of the namespace. | [
"Do",
"a",
"copy",
"of",
"the",
"namespace",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5867-L5872 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.copyNamespaceList | def copyNamespaceList(self):
"""Do a copy of an namespace list. """
ret = libxml2mod.xmlCopyNamespaceList(self._o)
if ret is None:raise treeError('xmlCopyNamespaceList() failed')
__tmp = xmlNs(_obj=ret)
return __tmp | python | def copyNamespaceList(self):
"""Do a copy of an namespace list. """
ret = libxml2mod.xmlCopyNamespaceList(self._o)
if ret is None:raise treeError('xmlCopyNamespaceList() failed')
__tmp = xmlNs(_obj=ret)
return __tmp | [
"def",
"copyNamespaceList",
"(",
"self",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlCopyNamespaceList",
"(",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlCopyNamespaceList() failed'",
")",
"__tmp",
"=",
"xmlNs",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Do a copy of an namespace list. | [
"Do",
"a",
"copy",
"of",
"an",
"namespace",
"list",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5874-L5879 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.newChild | def newChild(self, parent, name, content):
"""Creation of a new child element, added at the end of
@parent children list. @ns and @content parameters are
optional (None). If @ns is None, the newly created element
inherits the namespace of @parent. If @content is non None,
a child list containing the TEXTs and ENTITY_REFs node will
be created. NOTE: @content is supposed to be a piece of XML
CDATA, so it allows entity references. XML special chars
must be escaped first by using
xmlEncodeEntitiesReentrant(), or xmlNewTextChild() should
be used. """
if parent is None: parent__o = None
else: parent__o = parent._o
ret = libxml2mod.xmlNewChild(parent__o, self._o, name, content)
if ret is None:raise treeError('xmlNewChild() failed')
__tmp = xmlNode(_obj=ret)
return __tmp | python | def newChild(self, parent, name, content):
"""Creation of a new child element, added at the end of
@parent children list. @ns and @content parameters are
optional (None). If @ns is None, the newly created element
inherits the namespace of @parent. If @content is non None,
a child list containing the TEXTs and ENTITY_REFs node will
be created. NOTE: @content is supposed to be a piece of XML
CDATA, so it allows entity references. XML special chars
must be escaped first by using
xmlEncodeEntitiesReentrant(), or xmlNewTextChild() should
be used. """
if parent is None: parent__o = None
else: parent__o = parent._o
ret = libxml2mod.xmlNewChild(parent__o, self._o, name, content)
if ret is None:raise treeError('xmlNewChild() failed')
__tmp = xmlNode(_obj=ret)
return __tmp | [
"def",
"newChild",
"(",
"self",
",",
"parent",
",",
"name",
",",
"content",
")",
":",
"if",
"parent",
"is",
"None",
":",
"parent__o",
"=",
"None",
"else",
":",
"parent__o",
"=",
"parent",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlNewChild",
"(",
"parent__o",
",",
"self",
".",
"_o",
",",
"name",
",",
"content",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlNewChild() failed'",
")",
"__tmp",
"=",
"xmlNode",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Creation of a new child element, added at the end of
@parent children list. @ns and @content parameters are
optional (None). If @ns is None, the newly created element
inherits the namespace of @parent. If @content is non None,
a child list containing the TEXTs and ENTITY_REFs node will
be created. NOTE: @content is supposed to be a piece of XML
CDATA, so it allows entity references. XML special chars
must be escaped first by using
xmlEncodeEntitiesReentrant(), or xmlNewTextChild() should
be used. | [
"Creation",
"of",
"a",
"new",
"child",
"element",
"added",
"at",
"the",
"end",
"of"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5890-L5906 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.newDocNode | def newDocNode(self, doc, name, content):
"""Creation of a new node element within a document. @ns and
@content are optional (None). NOTE: @content is supposed to
be a piece of XML CDATA, so it allow entities references,
but XML special chars need to be escaped first by using
xmlEncodeEntitiesReentrant(). Use xmlNewDocRawNode() if you
don't need entities support. """
if doc is None: doc__o = None
else: doc__o = doc._o
ret = libxml2mod.xmlNewDocNode(doc__o, self._o, name, content)
if ret is None:raise treeError('xmlNewDocNode() failed')
__tmp = xmlNode(_obj=ret)
return __tmp | python | def newDocNode(self, doc, name, content):
"""Creation of a new node element within a document. @ns and
@content are optional (None). NOTE: @content is supposed to
be a piece of XML CDATA, so it allow entities references,
but XML special chars need to be escaped first by using
xmlEncodeEntitiesReentrant(). Use xmlNewDocRawNode() if you
don't need entities support. """
if doc is None: doc__o = None
else: doc__o = doc._o
ret = libxml2mod.xmlNewDocNode(doc__o, self._o, name, content)
if ret is None:raise treeError('xmlNewDocNode() failed')
__tmp = xmlNode(_obj=ret)
return __tmp | [
"def",
"newDocNode",
"(",
"self",
",",
"doc",
",",
"name",
",",
"content",
")",
":",
"if",
"doc",
"is",
"None",
":",
"doc__o",
"=",
"None",
"else",
":",
"doc__o",
"=",
"doc",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlNewDocNode",
"(",
"doc__o",
",",
"self",
".",
"_o",
",",
"name",
",",
"content",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlNewDocNode() failed'",
")",
"__tmp",
"=",
"xmlNode",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Creation of a new node element within a document. @ns and
@content are optional (None). NOTE: @content is supposed to
be a piece of XML CDATA, so it allow entities references,
but XML special chars need to be escaped first by using
xmlEncodeEntitiesReentrant(). Use xmlNewDocRawNode() if you
don't need entities support. | [
"Creation",
"of",
"a",
"new",
"node",
"element",
"within",
"a",
"document",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5908-L5920 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.newDocNodeEatName | def newDocNodeEatName(self, doc, name, content):
"""Creation of a new node element within a document. @ns and
@content are optional (None). NOTE: @content is supposed to
be a piece of XML CDATA, so it allow entities references,
but XML special chars need to be escaped first by using
xmlEncodeEntitiesReentrant(). Use xmlNewDocRawNode() if you
don't need entities support. """
if doc is None: doc__o = None
else: doc__o = doc._o
ret = libxml2mod.xmlNewDocNodeEatName(doc__o, self._o, name, content)
if ret is None:raise treeError('xmlNewDocNodeEatName() failed')
__tmp = xmlNode(_obj=ret)
return __tmp | python | def newDocNodeEatName(self, doc, name, content):
"""Creation of a new node element within a document. @ns and
@content are optional (None). NOTE: @content is supposed to
be a piece of XML CDATA, so it allow entities references,
but XML special chars need to be escaped first by using
xmlEncodeEntitiesReentrant(). Use xmlNewDocRawNode() if you
don't need entities support. """
if doc is None: doc__o = None
else: doc__o = doc._o
ret = libxml2mod.xmlNewDocNodeEatName(doc__o, self._o, name, content)
if ret is None:raise treeError('xmlNewDocNodeEatName() failed')
__tmp = xmlNode(_obj=ret)
return __tmp | [
"def",
"newDocNodeEatName",
"(",
"self",
",",
"doc",
",",
"name",
",",
"content",
")",
":",
"if",
"doc",
"is",
"None",
":",
"doc__o",
"=",
"None",
"else",
":",
"doc__o",
"=",
"doc",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlNewDocNodeEatName",
"(",
"doc__o",
",",
"self",
".",
"_o",
",",
"name",
",",
"content",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlNewDocNodeEatName() failed'",
")",
"__tmp",
"=",
"xmlNode",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Creation of a new node element within a document. @ns and
@content are optional (None). NOTE: @content is supposed to
be a piece of XML CDATA, so it allow entities references,
but XML special chars need to be escaped first by using
xmlEncodeEntitiesReentrant(). Use xmlNewDocRawNode() if you
don't need entities support. | [
"Creation",
"of",
"a",
"new",
"node",
"element",
"within",
"a",
"document",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5922-L5934 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.newDocRawNode | def newDocRawNode(self, doc, name, content):
"""Creation of a new node element within a document. @ns and
@content are optional (None). """
if doc is None: doc__o = None
else: doc__o = doc._o
ret = libxml2mod.xmlNewDocRawNode(doc__o, self._o, name, content)
if ret is None:raise treeError('xmlNewDocRawNode() failed')
__tmp = xmlNode(_obj=ret)
return __tmp | python | def newDocRawNode(self, doc, name, content):
"""Creation of a new node element within a document. @ns and
@content are optional (None). """
if doc is None: doc__o = None
else: doc__o = doc._o
ret = libxml2mod.xmlNewDocRawNode(doc__o, self._o, name, content)
if ret is None:raise treeError('xmlNewDocRawNode() failed')
__tmp = xmlNode(_obj=ret)
return __tmp | [
"def",
"newDocRawNode",
"(",
"self",
",",
"doc",
",",
"name",
",",
"content",
")",
":",
"if",
"doc",
"is",
"None",
":",
"doc__o",
"=",
"None",
"else",
":",
"doc__o",
"=",
"doc",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlNewDocRawNode",
"(",
"doc__o",
",",
"self",
".",
"_o",
",",
"name",
",",
"content",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlNewDocRawNode() failed'",
")",
"__tmp",
"=",
"xmlNode",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Creation of a new node element within a document. @ns and
@content are optional (None). | [
"Creation",
"of",
"a",
"new",
"node",
"element",
"within",
"a",
"document",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5936-L5944 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.newNodeEatName | def newNodeEatName(self, name):
"""Creation of a new node element. @ns is optional (None). """
ret = libxml2mod.xmlNewNodeEatName(self._o, name)
if ret is None:raise treeError('xmlNewNodeEatName() failed')
__tmp = xmlNode(_obj=ret)
return __tmp | python | def newNodeEatName(self, name):
"""Creation of a new node element. @ns is optional (None). """
ret = libxml2mod.xmlNewNodeEatName(self._o, name)
if ret is None:raise treeError('xmlNewNodeEatName() failed')
__tmp = xmlNode(_obj=ret)
return __tmp | [
"def",
"newNodeEatName",
"(",
"self",
",",
"name",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlNewNodeEatName",
"(",
"self",
".",
"_o",
",",
"name",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlNewNodeEatName() failed'",
")",
"__tmp",
"=",
"xmlNode",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Creation of a new node element. @ns is optional (None). | [
"Creation",
"of",
"a",
"new",
"node",
"element",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5946-L5951 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.newNsProp | def newNsProp(self, node, name, value):
"""Create a new property tagged with a namespace and carried
by a node. """
if node is None: node__o = None
else: node__o = node._o
ret = libxml2mod.xmlNewNsProp(node__o, self._o, name, value)
if ret is None:raise treeError('xmlNewNsProp() failed')
__tmp = xmlAttr(_obj=ret)
return __tmp | python | def newNsProp(self, node, name, value):
"""Create a new property tagged with a namespace and carried
by a node. """
if node is None: node__o = None
else: node__o = node._o
ret = libxml2mod.xmlNewNsProp(node__o, self._o, name, value)
if ret is None:raise treeError('xmlNewNsProp() failed')
__tmp = xmlAttr(_obj=ret)
return __tmp | [
"def",
"newNsProp",
"(",
"self",
",",
"node",
",",
"name",
",",
"value",
")",
":",
"if",
"node",
"is",
"None",
":",
"node__o",
"=",
"None",
"else",
":",
"node__o",
"=",
"node",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlNewNsProp",
"(",
"node__o",
",",
"self",
".",
"_o",
",",
"name",
",",
"value",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlNewNsProp() failed'",
")",
"__tmp",
"=",
"xmlAttr",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Create a new property tagged with a namespace and carried
by a node. | [
"Create",
"a",
"new",
"property",
"tagged",
"with",
"a",
"namespace",
"and",
"carried",
"by",
"a",
"node",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5953-L5961 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.newNsPropEatName | def newNsPropEatName(self, node, name, value):
"""Create a new property tagged with a namespace and carried
by a node. """
if node is None: node__o = None
else: node__o = node._o
ret = libxml2mod.xmlNewNsPropEatName(node__o, self._o, name, value)
if ret is None:raise treeError('xmlNewNsPropEatName() failed')
__tmp = xmlAttr(_obj=ret)
return __tmp | python | def newNsPropEatName(self, node, name, value):
"""Create a new property tagged with a namespace and carried
by a node. """
if node is None: node__o = None
else: node__o = node._o
ret = libxml2mod.xmlNewNsPropEatName(node__o, self._o, name, value)
if ret is None:raise treeError('xmlNewNsPropEatName() failed')
__tmp = xmlAttr(_obj=ret)
return __tmp | [
"def",
"newNsPropEatName",
"(",
"self",
",",
"node",
",",
"name",
",",
"value",
")",
":",
"if",
"node",
"is",
"None",
":",
"node__o",
"=",
"None",
"else",
":",
"node__o",
"=",
"node",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlNewNsPropEatName",
"(",
"node__o",
",",
"self",
".",
"_o",
",",
"name",
",",
"value",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlNewNsPropEatName() failed'",
")",
"__tmp",
"=",
"xmlAttr",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Create a new property tagged with a namespace and carried
by a node. | [
"Create",
"a",
"new",
"property",
"tagged",
"with",
"a",
"namespace",
"and",
"carried",
"by",
"a",
"node",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5963-L5971 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.newTextChild | def newTextChild(self, parent, name, content):
"""Creation of a new child element, added at the end of
@parent children list. @ns and @content parameters are
optional (None). If @ns is None, the newly created element
inherits the namespace of @parent. If @content is non None,
a child TEXT node will be created containing the string
@content. NOTE: Use xmlNewChild() if @content will contain
entities that need to be preserved. Use this function,
xmlNewTextChild(), if you need to ensure that reserved XML
chars that might appear in @content, such as the ampersand,
greater-than or less-than signs, are automatically replaced
by their XML escaped entity representations. """
if parent is None: parent__o = None
else: parent__o = parent._o
ret = libxml2mod.xmlNewTextChild(parent__o, self._o, name, content)
if ret is None:raise treeError('xmlNewTextChild() failed')
__tmp = xmlNode(_obj=ret)
return __tmp | python | def newTextChild(self, parent, name, content):
"""Creation of a new child element, added at the end of
@parent children list. @ns and @content parameters are
optional (None). If @ns is None, the newly created element
inherits the namespace of @parent. If @content is non None,
a child TEXT node will be created containing the string
@content. NOTE: Use xmlNewChild() if @content will contain
entities that need to be preserved. Use this function,
xmlNewTextChild(), if you need to ensure that reserved XML
chars that might appear in @content, such as the ampersand,
greater-than or less-than signs, are automatically replaced
by their XML escaped entity representations. """
if parent is None: parent__o = None
else: parent__o = parent._o
ret = libxml2mod.xmlNewTextChild(parent__o, self._o, name, content)
if ret is None:raise treeError('xmlNewTextChild() failed')
__tmp = xmlNode(_obj=ret)
return __tmp | [
"def",
"newTextChild",
"(",
"self",
",",
"parent",
",",
"name",
",",
"content",
")",
":",
"if",
"parent",
"is",
"None",
":",
"parent__o",
"=",
"None",
"else",
":",
"parent__o",
"=",
"parent",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlNewTextChild",
"(",
"parent__o",
",",
"self",
".",
"_o",
",",
"name",
",",
"content",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlNewTextChild() failed'",
")",
"__tmp",
"=",
"xmlNode",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Creation of a new child element, added at the end of
@parent children list. @ns and @content parameters are
optional (None). If @ns is None, the newly created element
inherits the namespace of @parent. If @content is non None,
a child TEXT node will be created containing the string
@content. NOTE: Use xmlNewChild() if @content will contain
entities that need to be preserved. Use this function,
xmlNewTextChild(), if you need to ensure that reserved XML
chars that might appear in @content, such as the ampersand,
greater-than or less-than signs, are automatically replaced
by their XML escaped entity representations. | [
"Creation",
"of",
"a",
"new",
"child",
"element",
"added",
"at",
"the",
"end",
"of"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5973-L5990 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.setNs | def setNs(self, node):
"""Associate a namespace to a node, a posteriori. """
if node is None: node__o = None
else: node__o = node._o
libxml2mod.xmlSetNs(node__o, self._o) | python | def setNs(self, node):
"""Associate a namespace to a node, a posteriori. """
if node is None: node__o = None
else: node__o = node._o
libxml2mod.xmlSetNs(node__o, self._o) | [
"def",
"setNs",
"(",
"self",
",",
"node",
")",
":",
"if",
"node",
"is",
"None",
":",
"node__o",
"=",
"None",
"else",
":",
"node__o",
"=",
"node",
".",
"_o",
"libxml2mod",
".",
"xmlSetNs",
"(",
"node__o",
",",
"self",
".",
"_o",
")"
] | Associate a namespace to a node, a posteriori. | [
"Associate",
"a",
"namespace",
"to",
"a",
"node",
"a",
"posteriori",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5992-L5996 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.setNsProp | def setNsProp(self, node, name, value):
"""Set (or reset) an attribute carried by a node. The ns
structure must be in scope, this is not checked """
if node is None: node__o = None
else: node__o = node._o
ret = libxml2mod.xmlSetNsProp(node__o, self._o, name, value)
if ret is None:raise treeError('xmlSetNsProp() failed')
__tmp = xmlAttr(_obj=ret)
return __tmp | python | def setNsProp(self, node, name, value):
"""Set (or reset) an attribute carried by a node. The ns
structure must be in scope, this is not checked """
if node is None: node__o = None
else: node__o = node._o
ret = libxml2mod.xmlSetNsProp(node__o, self._o, name, value)
if ret is None:raise treeError('xmlSetNsProp() failed')
__tmp = xmlAttr(_obj=ret)
return __tmp | [
"def",
"setNsProp",
"(",
"self",
",",
"node",
",",
"name",
",",
"value",
")",
":",
"if",
"node",
"is",
"None",
":",
"node__o",
"=",
"None",
"else",
":",
"node__o",
"=",
"node",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlSetNsProp",
"(",
"node__o",
",",
"self",
".",
"_o",
",",
"name",
",",
"value",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlSetNsProp() failed'",
")",
"__tmp",
"=",
"xmlAttr",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | Set (or reset) an attribute carried by a node. The ns
structure must be in scope, this is not checked | [
"Set",
"(",
"or",
"reset",
")",
"an",
"attribute",
"carried",
"by",
"a",
"node",
".",
"The",
"ns",
"structure",
"must",
"be",
"in",
"scope",
"this",
"is",
"not",
"checked"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L5998-L6006 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlNs.unsetNsProp | def unsetNsProp(self, node, name):
"""Remove an attribute carried by a node. """
if node is None: node__o = None
else: node__o = node._o
ret = libxml2mod.xmlUnsetNsProp(node__o, self._o, name)
return ret | python | def unsetNsProp(self, node, name):
"""Remove an attribute carried by a node. """
if node is None: node__o = None
else: node__o = node._o
ret = libxml2mod.xmlUnsetNsProp(node__o, self._o, name)
return ret | [
"def",
"unsetNsProp",
"(",
"self",
",",
"node",
",",
"name",
")",
":",
"if",
"node",
"is",
"None",
":",
"node__o",
"=",
"None",
"else",
":",
"node__o",
"=",
"node",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlUnsetNsProp",
"(",
"node__o",
",",
"self",
".",
"_o",
",",
"name",
")",
"return",
"ret"
] | Remove an attribute carried by a node. | [
"Remove",
"an",
"attribute",
"carried",
"by",
"a",
"node",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6008-L6013 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | outputBuffer.htmlDocContentDumpFormatOutput | def htmlDocContentDumpFormatOutput(self, cur, encoding, format):
"""Dump an HTML document. """
if cur is None: cur__o = None
else: cur__o = cur._o
libxml2mod.htmlDocContentDumpFormatOutput(self._o, cur__o, encoding, format) | python | def htmlDocContentDumpFormatOutput(self, cur, encoding, format):
"""Dump an HTML document. """
if cur is None: cur__o = None
else: cur__o = cur._o
libxml2mod.htmlDocContentDumpFormatOutput(self._o, cur__o, encoding, format) | [
"def",
"htmlDocContentDumpFormatOutput",
"(",
"self",
",",
"cur",
",",
"encoding",
",",
"format",
")",
":",
"if",
"cur",
"is",
"None",
":",
"cur__o",
"=",
"None",
"else",
":",
"cur__o",
"=",
"cur",
".",
"_o",
"libxml2mod",
".",
"htmlDocContentDumpFormatOutput",
"(",
"self",
".",
"_o",
",",
"cur__o",
",",
"encoding",
",",
"format",
")"
] | Dump an HTML document. | [
"Dump",
"an",
"HTML",
"document",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6035-L6039 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | outputBuffer.htmlDocContentDumpOutput | def htmlDocContentDumpOutput(self, cur, encoding):
"""Dump an HTML document. Formating return/spaces are added. """
if cur is None: cur__o = None
else: cur__o = cur._o
libxml2mod.htmlDocContentDumpOutput(self._o, cur__o, encoding) | python | def htmlDocContentDumpOutput(self, cur, encoding):
"""Dump an HTML document. Formating return/spaces are added. """
if cur is None: cur__o = None
else: cur__o = cur._o
libxml2mod.htmlDocContentDumpOutput(self._o, cur__o, encoding) | [
"def",
"htmlDocContentDumpOutput",
"(",
"self",
",",
"cur",
",",
"encoding",
")",
":",
"if",
"cur",
"is",
"None",
":",
"cur__o",
"=",
"None",
"else",
":",
"cur__o",
"=",
"cur",
".",
"_o",
"libxml2mod",
".",
"htmlDocContentDumpOutput",
"(",
"self",
".",
"_o",
",",
"cur__o",
",",
"encoding",
")"
] | Dump an HTML document. Formating return/spaces are added. | [
"Dump",
"an",
"HTML",
"document",
".",
"Formating",
"return",
"/",
"spaces",
"are",
"added",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6041-L6045 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | outputBuffer.htmlNodeDumpFormatOutput | def htmlNodeDumpFormatOutput(self, doc, cur, encoding, format):
"""Dump an HTML node, recursive behaviour,children are printed
too. """
if doc is None: doc__o = None
else: doc__o = doc._o
if cur is None: cur__o = None
else: cur__o = cur._o
libxml2mod.htmlNodeDumpFormatOutput(self._o, doc__o, cur__o, encoding, format) | python | def htmlNodeDumpFormatOutput(self, doc, cur, encoding, format):
"""Dump an HTML node, recursive behaviour,children are printed
too. """
if doc is None: doc__o = None
else: doc__o = doc._o
if cur is None: cur__o = None
else: cur__o = cur._o
libxml2mod.htmlNodeDumpFormatOutput(self._o, doc__o, cur__o, encoding, format) | [
"def",
"htmlNodeDumpFormatOutput",
"(",
"self",
",",
"doc",
",",
"cur",
",",
"encoding",
",",
"format",
")",
":",
"if",
"doc",
"is",
"None",
":",
"doc__o",
"=",
"None",
"else",
":",
"doc__o",
"=",
"doc",
".",
"_o",
"if",
"cur",
"is",
"None",
":",
"cur__o",
"=",
"None",
"else",
":",
"cur__o",
"=",
"cur",
".",
"_o",
"libxml2mod",
".",
"htmlNodeDumpFormatOutput",
"(",
"self",
".",
"_o",
",",
"doc__o",
",",
"cur__o",
",",
"encoding",
",",
"format",
")"
] | Dump an HTML node, recursive behaviour,children are printed
too. | [
"Dump",
"an",
"HTML",
"node",
"recursive",
"behaviour",
"children",
"are",
"printed",
"too",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6047-L6054 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | outputBuffer.htmlNodeDumpOutput | def htmlNodeDumpOutput(self, doc, cur, encoding):
"""Dump an HTML node, recursive behaviour,children are printed
too, and formatting returns/spaces are added. """
if doc is None: doc__o = None
else: doc__o = doc._o
if cur is None: cur__o = None
else: cur__o = cur._o
libxml2mod.htmlNodeDumpOutput(self._o, doc__o, cur__o, encoding) | python | def htmlNodeDumpOutput(self, doc, cur, encoding):
"""Dump an HTML node, recursive behaviour,children are printed
too, and formatting returns/spaces are added. """
if doc is None: doc__o = None
else: doc__o = doc._o
if cur is None: cur__o = None
else: cur__o = cur._o
libxml2mod.htmlNodeDumpOutput(self._o, doc__o, cur__o, encoding) | [
"def",
"htmlNodeDumpOutput",
"(",
"self",
",",
"doc",
",",
"cur",
",",
"encoding",
")",
":",
"if",
"doc",
"is",
"None",
":",
"doc__o",
"=",
"None",
"else",
":",
"doc__o",
"=",
"doc",
".",
"_o",
"if",
"cur",
"is",
"None",
":",
"cur__o",
"=",
"None",
"else",
":",
"cur__o",
"=",
"cur",
".",
"_o",
"libxml2mod",
".",
"htmlNodeDumpOutput",
"(",
"self",
".",
"_o",
",",
"doc__o",
",",
"cur__o",
",",
"encoding",
")"
] | Dump an HTML node, recursive behaviour,children are printed
too, and formatting returns/spaces are added. | [
"Dump",
"an",
"HTML",
"node",
"recursive",
"behaviour",
"children",
"are",
"printed",
"too",
"and",
"formatting",
"returns",
"/",
"spaces",
"are",
"added",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6056-L6063 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | outputBuffer.nodeDumpOutput | def nodeDumpOutput(self, doc, cur, level, format, encoding):
"""Dump an XML node, recursive behaviour, children are printed
too. Note that @format = 1 provide node indenting only if
xmlIndentTreeOutput = 1 or xmlKeepBlanksDefault(0) was
called """
if doc is None: doc__o = None
else: doc__o = doc._o
if cur is None: cur__o = None
else: cur__o = cur._o
libxml2mod.xmlNodeDumpOutput(self._o, doc__o, cur__o, level, format, encoding) | python | def nodeDumpOutput(self, doc, cur, level, format, encoding):
"""Dump an XML node, recursive behaviour, children are printed
too. Note that @format = 1 provide node indenting only if
xmlIndentTreeOutput = 1 or xmlKeepBlanksDefault(0) was
called """
if doc is None: doc__o = None
else: doc__o = doc._o
if cur is None: cur__o = None
else: cur__o = cur._o
libxml2mod.xmlNodeDumpOutput(self._o, doc__o, cur__o, level, format, encoding) | [
"def",
"nodeDumpOutput",
"(",
"self",
",",
"doc",
",",
"cur",
",",
"level",
",",
"format",
",",
"encoding",
")",
":",
"if",
"doc",
"is",
"None",
":",
"doc__o",
"=",
"None",
"else",
":",
"doc__o",
"=",
"doc",
".",
"_o",
"if",
"cur",
"is",
"None",
":",
"cur__o",
"=",
"None",
"else",
":",
"cur__o",
"=",
"cur",
".",
"_o",
"libxml2mod",
".",
"xmlNodeDumpOutput",
"(",
"self",
".",
"_o",
",",
"doc__o",
",",
"cur__o",
",",
"level",
",",
"format",
",",
"encoding",
")"
] | Dump an XML node, recursive behaviour, children are printed
too. Note that @format = 1 provide node indenting only if
xmlIndentTreeOutput = 1 or xmlKeepBlanksDefault(0) was
called | [
"Dump",
"an",
"XML",
"node",
"recursive",
"behaviour",
"children",
"are",
"printed",
"too",
".",
"Note",
"that"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6069-L6078 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | outputBuffer.saveFileTo | def saveFileTo(self, cur, encoding):
"""Dump an XML document to an I/O buffer. Warning ! This call
xmlOutputBufferClose() on buf which is not available after
this call. """
if cur is None: cur__o = None
else: cur__o = cur._o
ret = libxml2mod.xmlSaveFileTo(self._o, cur__o, encoding)
return ret | python | def saveFileTo(self, cur, encoding):
"""Dump an XML document to an I/O buffer. Warning ! This call
xmlOutputBufferClose() on buf which is not available after
this call. """
if cur is None: cur__o = None
else: cur__o = cur._o
ret = libxml2mod.xmlSaveFileTo(self._o, cur__o, encoding)
return ret | [
"def",
"saveFileTo",
"(",
"self",
",",
"cur",
",",
"encoding",
")",
":",
"if",
"cur",
"is",
"None",
":",
"cur__o",
"=",
"None",
"else",
":",
"cur__o",
"=",
"cur",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlSaveFileTo",
"(",
"self",
".",
"_o",
",",
"cur__o",
",",
"encoding",
")",
"return",
"ret"
] | Dump an XML document to an I/O buffer. Warning ! This call
xmlOutputBufferClose() on buf which is not available after
this call. | [
"Dump",
"an",
"XML",
"document",
"to",
"an",
"I",
"/",
"O",
"buffer",
".",
"Warning",
"!",
"This",
"call",
"xmlOutputBufferClose",
"()",
"on",
"buf",
"which",
"is",
"not",
"available",
"after",
"this",
"call",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6080-L6087 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | outputBuffer.saveFormatFileTo | def saveFormatFileTo(self, cur, encoding, format):
"""Dump an XML document to an I/O buffer. Warning ! This call
xmlOutputBufferClose() on buf which is not available after
this call. """
if cur is None: cur__o = None
else: cur__o = cur._o
ret = libxml2mod.xmlSaveFormatFileTo(self._o, cur__o, encoding, format)
return ret | python | def saveFormatFileTo(self, cur, encoding, format):
"""Dump an XML document to an I/O buffer. Warning ! This call
xmlOutputBufferClose() on buf which is not available after
this call. """
if cur is None: cur__o = None
else: cur__o = cur._o
ret = libxml2mod.xmlSaveFormatFileTo(self._o, cur__o, encoding, format)
return ret | [
"def",
"saveFormatFileTo",
"(",
"self",
",",
"cur",
",",
"encoding",
",",
"format",
")",
":",
"if",
"cur",
"is",
"None",
":",
"cur__o",
"=",
"None",
"else",
":",
"cur__o",
"=",
"cur",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlSaveFormatFileTo",
"(",
"self",
".",
"_o",
",",
"cur__o",
",",
"encoding",
",",
"format",
")",
"return",
"ret"
] | Dump an XML document to an I/O buffer. Warning ! This call
xmlOutputBufferClose() on buf which is not available after
this call. | [
"Dump",
"an",
"XML",
"document",
"to",
"an",
"I",
"/",
"O",
"buffer",
".",
"Warning",
"!",
"This",
"call",
"xmlOutputBufferClose",
"()",
"on",
"buf",
"which",
"is",
"not",
"available",
"after",
"this",
"call",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6089-L6096 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | outputBuffer.write | def write(self, len, buf):
"""Write the content of the array in the output I/O buffer
This routine handle the I18N transcoding from internal
UTF-8 The buffer is lossless, i.e. will store in case of
partial or delayed writes. """
ret = libxml2mod.xmlOutputBufferWrite(self._o, len, buf)
return ret | python | def write(self, len, buf):
"""Write the content of the array in the output I/O buffer
This routine handle the I18N transcoding from internal
UTF-8 The buffer is lossless, i.e. will store in case of
partial or delayed writes. """
ret = libxml2mod.xmlOutputBufferWrite(self._o, len, buf)
return ret | [
"def",
"write",
"(",
"self",
",",
"len",
",",
"buf",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlOutputBufferWrite",
"(",
"self",
".",
"_o",
",",
"len",
",",
"buf",
")",
"return",
"ret"
] | Write the content of the array in the output I/O buffer
This routine handle the I18N transcoding from internal
UTF-8 The buffer is lossless, i.e. will store in case of
partial or delayed writes. | [
"Write",
"the",
"content",
"of",
"the",
"array",
"in",
"the",
"output",
"I",
"/",
"O",
"buffer",
"This",
"routine",
"handle",
"the",
"I18N",
"transcoding",
"from",
"internal",
"UTF",
"-",
"8",
"The",
"buffer",
"is",
"lossless",
"i",
".",
"e",
".",
"will",
"store",
"in",
"case",
"of",
"partial",
"or",
"delayed",
"writes",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6108-L6114 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | outputBuffer.writeString | def writeString(self, str):
"""Write the content of the string in the output I/O buffer
This routine handle the I18N transcoding from internal
UTF-8 The buffer is lossless, i.e. will store in case of
partial or delayed writes. """
ret = libxml2mod.xmlOutputBufferWriteString(self._o, str)
return ret | python | def writeString(self, str):
"""Write the content of the string in the output I/O buffer
This routine handle the I18N transcoding from internal
UTF-8 The buffer is lossless, i.e. will store in case of
partial or delayed writes. """
ret = libxml2mod.xmlOutputBufferWriteString(self._o, str)
return ret | [
"def",
"writeString",
"(",
"self",
",",
"str",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlOutputBufferWriteString",
"(",
"self",
".",
"_o",
",",
"str",
")",
"return",
"ret"
] | Write the content of the string in the output I/O buffer
This routine handle the I18N transcoding from internal
UTF-8 The buffer is lossless, i.e. will store in case of
partial or delayed writes. | [
"Write",
"the",
"content",
"of",
"the",
"string",
"in",
"the",
"output",
"I",
"/",
"O",
"buffer",
"This",
"routine",
"handle",
"the",
"I18N",
"transcoding",
"from",
"internal",
"UTF",
"-",
"8",
"The",
"buffer",
"is",
"lossless",
"i",
".",
"e",
".",
"will",
"store",
"in",
"case",
"of",
"partial",
"or",
"delayed",
"writes",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6116-L6122 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | inputBuffer.grow | def grow(self, len):
"""Grow up the content of the input buffer, the old data are
preserved This routine handle the I18N transcoding to
internal UTF-8 This routine is used when operating the
parser in normal (pull) mode TODO: one should be able to
remove one extra copy by copying directly onto in->buffer
or in->raw """
ret = libxml2mod.xmlParserInputBufferGrow(self._o, len)
return ret | python | def grow(self, len):
"""Grow up the content of the input buffer, the old data are
preserved This routine handle the I18N transcoding to
internal UTF-8 This routine is used when operating the
parser in normal (pull) mode TODO: one should be able to
remove one extra copy by copying directly onto in->buffer
or in->raw """
ret = libxml2mod.xmlParserInputBufferGrow(self._o, len)
return ret | [
"def",
"grow",
"(",
"self",
",",
"len",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlParserInputBufferGrow",
"(",
"self",
".",
"_o",
",",
"len",
")",
"return",
"ret"
] | Grow up the content of the input buffer, the old data are
preserved This routine handle the I18N transcoding to
internal UTF-8 This routine is used when operating the
parser in normal (pull) mode TODO: one should be able to
remove one extra copy by copying directly onto in->buffer
or in->raw | [
"Grow",
"up",
"the",
"content",
"of",
"the",
"input",
"buffer",
"the",
"old",
"data",
"are",
"preserved",
"This",
"routine",
"handle",
"the",
"I18N",
"transcoding",
"to",
"internal",
"UTF",
"-",
"8",
"This",
"routine",
"is",
"used",
"when",
"operating",
"the",
"parser",
"in",
"normal",
"(",
"pull",
")",
"mode",
"TODO",
":",
"one",
"should",
"be",
"able",
"to",
"remove",
"one",
"extra",
"copy",
"by",
"copying",
"directly",
"onto",
"in",
"-",
">",
"buffer",
"or",
"in",
"-",
">",
"raw"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6138-L6146 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | inputBuffer.push | def push(self, len, buf):
"""Push the content of the arry in the input buffer This
routine handle the I18N transcoding to internal UTF-8 This
is used when operating the parser in progressive (push)
mode. """
ret = libxml2mod.xmlParserInputBufferPush(self._o, len, buf)
return ret | python | def push(self, len, buf):
"""Push the content of the arry in the input buffer This
routine handle the I18N transcoding to internal UTF-8 This
is used when operating the parser in progressive (push)
mode. """
ret = libxml2mod.xmlParserInputBufferPush(self._o, len, buf)
return ret | [
"def",
"push",
"(",
"self",
",",
"len",
",",
"buf",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlParserInputBufferPush",
"(",
"self",
".",
"_o",
",",
"len",
",",
"buf",
")",
"return",
"ret"
] | Push the content of the arry in the input buffer This
routine handle the I18N transcoding to internal UTF-8 This
is used when operating the parser in progressive (push)
mode. | [
"Push",
"the",
"content",
"of",
"the",
"arry",
"in",
"the",
"input",
"buffer",
"This",
"routine",
"handle",
"the",
"I18N",
"transcoding",
"to",
"internal",
"UTF",
"-",
"8",
"This",
"is",
"used",
"when",
"operating",
"the",
"parser",
"in",
"progressive",
"(",
"push",
")",
"mode",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6148-L6154 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | inputBuffer.read | def read(self, len):
"""Refresh the content of the input buffer, the old data are
considered consumed This routine handle the I18N
transcoding to internal UTF-8 """
ret = libxml2mod.xmlParserInputBufferRead(self._o, len)
return ret | python | def read(self, len):
"""Refresh the content of the input buffer, the old data are
considered consumed This routine handle the I18N
transcoding to internal UTF-8 """
ret = libxml2mod.xmlParserInputBufferRead(self._o, len)
return ret | [
"def",
"read",
"(",
"self",
",",
"len",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlParserInputBufferRead",
"(",
"self",
".",
"_o",
",",
"len",
")",
"return",
"ret"
] | Refresh the content of the input buffer, the old data are
considered consumed This routine handle the I18N
transcoding to internal UTF-8 | [
"Refresh",
"the",
"content",
"of",
"the",
"input",
"buffer",
"the",
"old",
"data",
"are",
"considered",
"consumed",
"This",
"routine",
"handle",
"the",
"I18N",
"transcoding",
"to",
"internal",
"UTF",
"-",
"8"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6156-L6161 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | inputBuffer.Setup | def Setup(self, reader, URL, encoding, options):
"""Setup an XML reader with new options """
if reader is None: reader__o = None
else: reader__o = reader._o
ret = libxml2mod.xmlTextReaderSetup(reader__o, self._o, URL, encoding, options)
return ret | python | def Setup(self, reader, URL, encoding, options):
"""Setup an XML reader with new options """
if reader is None: reader__o = None
else: reader__o = reader._o
ret = libxml2mod.xmlTextReaderSetup(reader__o, self._o, URL, encoding, options)
return ret | [
"def",
"Setup",
"(",
"self",
",",
"reader",
",",
"URL",
",",
"encoding",
",",
"options",
")",
":",
"if",
"reader",
"is",
"None",
":",
"reader__o",
"=",
"None",
"else",
":",
"reader__o",
"=",
"reader",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlTextReaderSetup",
"(",
"reader__o",
",",
"self",
".",
"_o",
",",
"URL",
",",
"encoding",
",",
"options",
")",
"return",
"ret"
] | Setup an XML reader with new options | [
"Setup",
"an",
"XML",
"reader",
"with",
"new",
"options"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6167-L6172 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | inputBuffer.newTextReader | def newTextReader(self, URI):
"""Create an xmlTextReader structure fed with @input """
ret = libxml2mod.xmlNewTextReader(self._o, URI)
if ret is None:raise treeError('xmlNewTextReader() failed')
__tmp = xmlTextReader(_obj=ret)
__tmp.input = self
return __tmp | python | def newTextReader(self, URI):
"""Create an xmlTextReader structure fed with @input """
ret = libxml2mod.xmlNewTextReader(self._o, URI)
if ret is None:raise treeError('xmlNewTextReader() failed')
__tmp = xmlTextReader(_obj=ret)
__tmp.input = self
return __tmp | [
"def",
"newTextReader",
"(",
"self",
",",
"URI",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlNewTextReader",
"(",
"self",
".",
"_o",
",",
"URI",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlNewTextReader() failed'",
")",
"__tmp",
"=",
"xmlTextReader",
"(",
"_obj",
"=",
"ret",
")",
"__tmp",
".",
"input",
"=",
"self",
"return",
"__tmp"
] | Create an xmlTextReader structure fed with @input | [
"Create",
"an",
"xmlTextReader",
"structure",
"fed",
"with"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6174-L6180 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | xmlReg.regexpExec | def regexpExec(self, content):
"""Check if the regular expression generates the value """
ret = libxml2mod.xmlRegexpExec(self._o, content)
return ret | python | def regexpExec(self, content):
"""Check if the regular expression generates the value """
ret = libxml2mod.xmlRegexpExec(self._o, content)
return ret | [
"def",
"regexpExec",
"(",
"self",
",",
"content",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlRegexpExec",
"(",
"self",
".",
"_o",
",",
"content",
")",
"return",
"ret"
] | Check if the regular expression generates the value | [
"Check",
"if",
"the",
"regular",
"expression",
"generates",
"the",
"value"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6196-L6199 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | relaxNgParserCtxt.relaxNGParse | def relaxNGParse(self):
"""parse a schema definition resource and build an internal
XML Shema struture which can be used to validate instances. """
ret = libxml2mod.xmlRelaxNGParse(self._o)
if ret is None:raise parserError('xmlRelaxNGParse() failed')
__tmp = relaxNgSchema(_obj=ret)
return __tmp | python | def relaxNGParse(self):
"""parse a schema definition resource and build an internal
XML Shema struture which can be used to validate instances. """
ret = libxml2mod.xmlRelaxNGParse(self._o)
if ret is None:raise parserError('xmlRelaxNGParse() failed')
__tmp = relaxNgSchema(_obj=ret)
return __tmp | [
"def",
"relaxNGParse",
"(",
"self",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlRelaxNGParse",
"(",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"parserError",
"(",
"'xmlRelaxNGParse() failed'",
")",
"__tmp",
"=",
"relaxNgSchema",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | parse a schema definition resource and build an internal
XML Shema struture which can be used to validate instances. | [
"parse",
"a",
"schema",
"definition",
"resource",
"and",
"build",
"an",
"internal",
"XML",
"Shema",
"struture",
"which",
"can",
"be",
"used",
"to",
"validate",
"instances",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6224-L6230 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | relaxNgParserCtxt.relaxParserSetFlag | def relaxParserSetFlag(self, flags):
"""Semi private function used to pass informations to a parser
context which are a combination of xmlRelaxNGParserFlag . """
ret = libxml2mod.xmlRelaxParserSetFlag(self._o, flags)
return ret | python | def relaxParserSetFlag(self, flags):
"""Semi private function used to pass informations to a parser
context which are a combination of xmlRelaxNGParserFlag . """
ret = libxml2mod.xmlRelaxParserSetFlag(self._o, flags)
return ret | [
"def",
"relaxParserSetFlag",
"(",
"self",
",",
"flags",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlRelaxParserSetFlag",
"(",
"self",
".",
"_o",
",",
"flags",
")",
"return",
"ret"
] | Semi private function used to pass informations to a parser
context which are a combination of xmlRelaxNGParserFlag . | [
"Semi",
"private",
"function",
"used",
"to",
"pass",
"informations",
"to",
"a",
"parser",
"context",
"which",
"are",
"a",
"combination",
"of",
"xmlRelaxNGParserFlag",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6232-L6236 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | relaxNgSchema.relaxNGNewValidCtxt | def relaxNGNewValidCtxt(self):
"""Create an XML RelaxNGs validation context based on the
given schema """
ret = libxml2mod.xmlRelaxNGNewValidCtxt(self._o)
if ret is None:raise treeError('xmlRelaxNGNewValidCtxt() failed')
__tmp = relaxNgValidCtxt(_obj=ret)
__tmp.schema = self
return __tmp | python | def relaxNGNewValidCtxt(self):
"""Create an XML RelaxNGs validation context based on the
given schema """
ret = libxml2mod.xmlRelaxNGNewValidCtxt(self._o)
if ret is None:raise treeError('xmlRelaxNGNewValidCtxt() failed')
__tmp = relaxNgValidCtxt(_obj=ret)
__tmp.schema = self
return __tmp | [
"def",
"relaxNGNewValidCtxt",
"(",
"self",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlRelaxNGNewValidCtxt",
"(",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"treeError",
"(",
"'xmlRelaxNGNewValidCtxt() failed'",
")",
"__tmp",
"=",
"relaxNgValidCtxt",
"(",
"_obj",
"=",
"ret",
")",
"__tmp",
".",
"schema",
"=",
"self",
"return",
"__tmp"
] | Create an XML RelaxNGs validation context based on the
given schema | [
"Create",
"an",
"XML",
"RelaxNGs",
"validation",
"context",
"based",
"on",
"the",
"given",
"schema"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6260-L6267 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | relaxNgSchema.RelaxNGSetSchema | def RelaxNGSetSchema(self, reader):
"""Use RelaxNG to validate the document as it is processed.
Activation is only possible before the first Read(). if
@schema is None, then RelaxNG validation is desactivated. @
The @schema should not be freed until the reader is
deallocated or its use has been deactivated. """
if reader is None: reader__o = None
else: reader__o = reader._o
ret = libxml2mod.xmlTextReaderRelaxNGSetSchema(reader__o, self._o)
return ret | python | def RelaxNGSetSchema(self, reader):
"""Use RelaxNG to validate the document as it is processed.
Activation is only possible before the first Read(). if
@schema is None, then RelaxNG validation is desactivated. @
The @schema should not be freed until the reader is
deallocated or its use has been deactivated. """
if reader is None: reader__o = None
else: reader__o = reader._o
ret = libxml2mod.xmlTextReaderRelaxNGSetSchema(reader__o, self._o)
return ret | [
"def",
"RelaxNGSetSchema",
"(",
"self",
",",
"reader",
")",
":",
"if",
"reader",
"is",
"None",
":",
"reader__o",
"=",
"None",
"else",
":",
"reader__o",
"=",
"reader",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlTextReaderRelaxNGSetSchema",
"(",
"reader__o",
",",
"self",
".",
"_o",
")",
"return",
"ret"
] | Use RelaxNG to validate the document as it is processed.
Activation is only possible before the first Read(). if
@schema is None, then RelaxNG validation is desactivated. @
The @schema should not be freed until the reader is
deallocated or its use has been deactivated. | [
"Use",
"RelaxNG",
"to",
"validate",
"the",
"document",
"as",
"it",
"is",
"processed",
".",
"Activation",
"is",
"only",
"possible",
"before",
"the",
"first",
"Read",
"()",
".",
"if"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6273-L6282 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | relaxNgValidCtxt.relaxNGValidateDoc | def relaxNGValidateDoc(self, doc):
"""Validate a document tree in memory. """
if doc is None: doc__o = None
else: doc__o = doc._o
ret = libxml2mod.xmlRelaxNGValidateDoc(self._o, doc__o)
return ret | python | def relaxNGValidateDoc(self, doc):
"""Validate a document tree in memory. """
if doc is None: doc__o = None
else: doc__o = doc._o
ret = libxml2mod.xmlRelaxNGValidateDoc(self._o, doc__o)
return ret | [
"def",
"relaxNGValidateDoc",
"(",
"self",
",",
"doc",
")",
":",
"if",
"doc",
"is",
"None",
":",
"doc__o",
"=",
"None",
"else",
":",
"doc__o",
"=",
"doc",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlRelaxNGValidateDoc",
"(",
"self",
".",
"_o",
",",
"doc__o",
")",
"return",
"ret"
] | Validate a document tree in memory. | [
"Validate",
"a",
"document",
"tree",
"in",
"memory",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6299-L6304 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | relaxNgValidCtxt.relaxNGValidateFullElement | def relaxNGValidateFullElement(self, doc, elem):
"""Validate a full subtree when
xmlRelaxNGValidatePushElement() returned 0 and the content
of the node has been expanded. """
if doc is None: doc__o = None
else: doc__o = doc._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlRelaxNGValidateFullElement(self._o, doc__o, elem__o)
return ret | python | def relaxNGValidateFullElement(self, doc, elem):
"""Validate a full subtree when
xmlRelaxNGValidatePushElement() returned 0 and the content
of the node has been expanded. """
if doc is None: doc__o = None
else: doc__o = doc._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlRelaxNGValidateFullElement(self._o, doc__o, elem__o)
return ret | [
"def",
"relaxNGValidateFullElement",
"(",
"self",
",",
"doc",
",",
"elem",
")",
":",
"if",
"doc",
"is",
"None",
":",
"doc__o",
"=",
"None",
"else",
":",
"doc__o",
"=",
"doc",
".",
"_o",
"if",
"elem",
"is",
"None",
":",
"elem__o",
"=",
"None",
"else",
":",
"elem__o",
"=",
"elem",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlRelaxNGValidateFullElement",
"(",
"self",
".",
"_o",
",",
"doc__o",
",",
"elem__o",
")",
"return",
"ret"
] | Validate a full subtree when
xmlRelaxNGValidatePushElement() returned 0 and the content
of the node has been expanded. | [
"Validate",
"a",
"full",
"subtree",
"when",
"xmlRelaxNGValidatePushElement",
"()",
"returned",
"0",
"and",
"the",
"content",
"of",
"the",
"node",
"has",
"been",
"expanded",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6306-L6315 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | relaxNgValidCtxt.relaxNGValidatePopElement | def relaxNGValidatePopElement(self, doc, elem):
"""Pop the element end from the RelaxNG validation stack. """
if doc is None: doc__o = None
else: doc__o = doc._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlRelaxNGValidatePopElement(self._o, doc__o, elem__o)
return ret | python | def relaxNGValidatePopElement(self, doc, elem):
"""Pop the element end from the RelaxNG validation stack. """
if doc is None: doc__o = None
else: doc__o = doc._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlRelaxNGValidatePopElement(self._o, doc__o, elem__o)
return ret | [
"def",
"relaxNGValidatePopElement",
"(",
"self",
",",
"doc",
",",
"elem",
")",
":",
"if",
"doc",
"is",
"None",
":",
"doc__o",
"=",
"None",
"else",
":",
"doc__o",
"=",
"doc",
".",
"_o",
"if",
"elem",
"is",
"None",
":",
"elem__o",
"=",
"None",
"else",
":",
"elem__o",
"=",
"elem",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlRelaxNGValidatePopElement",
"(",
"self",
".",
"_o",
",",
"doc__o",
",",
"elem__o",
")",
"return",
"ret"
] | Pop the element end from the RelaxNG validation stack. | [
"Pop",
"the",
"element",
"end",
"from",
"the",
"RelaxNG",
"validation",
"stack",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6317-L6324 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | relaxNgValidCtxt.relaxNGValidatePushCData | def relaxNGValidatePushCData(self, data, len):
"""check the CData parsed for validation in the current stack """
ret = libxml2mod.xmlRelaxNGValidatePushCData(self._o, data, len)
return ret | python | def relaxNGValidatePushCData(self, data, len):
"""check the CData parsed for validation in the current stack """
ret = libxml2mod.xmlRelaxNGValidatePushCData(self._o, data, len)
return ret | [
"def",
"relaxNGValidatePushCData",
"(",
"self",
",",
"data",
",",
"len",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlRelaxNGValidatePushCData",
"(",
"self",
".",
"_o",
",",
"data",
",",
"len",
")",
"return",
"ret"
] | check the CData parsed for validation in the current stack | [
"check",
"the",
"CData",
"parsed",
"for",
"validation",
"in",
"the",
"current",
"stack"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6326-L6329 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | relaxNgValidCtxt.relaxNGValidatePushElement | def relaxNGValidatePushElement(self, doc, elem):
"""Push a new element start on the RelaxNG validation stack. """
if doc is None: doc__o = None
else: doc__o = doc._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlRelaxNGValidatePushElement(self._o, doc__o, elem__o)
return ret | python | def relaxNGValidatePushElement(self, doc, elem):
"""Push a new element start on the RelaxNG validation stack. """
if doc is None: doc__o = None
else: doc__o = doc._o
if elem is None: elem__o = None
else: elem__o = elem._o
ret = libxml2mod.xmlRelaxNGValidatePushElement(self._o, doc__o, elem__o)
return ret | [
"def",
"relaxNGValidatePushElement",
"(",
"self",
",",
"doc",
",",
"elem",
")",
":",
"if",
"doc",
"is",
"None",
":",
"doc__o",
"=",
"None",
"else",
":",
"doc__o",
"=",
"doc",
".",
"_o",
"if",
"elem",
"is",
"None",
":",
"elem__o",
"=",
"None",
"else",
":",
"elem__o",
"=",
"elem",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlRelaxNGValidatePushElement",
"(",
"self",
".",
"_o",
",",
"doc__o",
",",
"elem__o",
")",
"return",
"ret"
] | Push a new element start on the RelaxNG validation stack. | [
"Push",
"a",
"new",
"element",
"start",
"on",
"the",
"RelaxNG",
"validation",
"stack",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6331-L6338 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | relaxNgValidCtxt.RelaxNGValidateCtxt | def RelaxNGValidateCtxt(self, reader, options):
"""Use RelaxNG schema context to validate the document as it
is processed. Activation is only possible before the first
Read(). If @ctxt is None, then RelaxNG schema validation is
deactivated. """
if reader is None: reader__o = None
else: reader__o = reader._o
ret = libxml2mod.xmlTextReaderRelaxNGValidateCtxt(reader__o, self._o, options)
return ret | python | def RelaxNGValidateCtxt(self, reader, options):
"""Use RelaxNG schema context to validate the document as it
is processed. Activation is only possible before the first
Read(). If @ctxt is None, then RelaxNG schema validation is
deactivated. """
if reader is None: reader__o = None
else: reader__o = reader._o
ret = libxml2mod.xmlTextReaderRelaxNGValidateCtxt(reader__o, self._o, options)
return ret | [
"def",
"RelaxNGValidateCtxt",
"(",
"self",
",",
"reader",
",",
"options",
")",
":",
"if",
"reader",
"is",
"None",
":",
"reader__o",
"=",
"None",
"else",
":",
"reader__o",
"=",
"reader",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlTextReaderRelaxNGValidateCtxt",
"(",
"reader__o",
",",
"self",
".",
"_o",
",",
"options",
")",
"return",
"ret"
] | Use RelaxNG schema context to validate the document as it
is processed. Activation is only possible before the first
Read(). If @ctxt is None, then RelaxNG schema validation is
deactivated. | [
"Use",
"RelaxNG",
"schema",
"context",
"to",
"validate",
"the",
"document",
"as",
"it",
"is",
"processed",
".",
"Activation",
"is",
"only",
"possible",
"before",
"the",
"first",
"Read",
"()",
".",
"If"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6344-L6352 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | SchemaParserCtxt.schemaParse | def schemaParse(self):
"""parse a schema definition resource and build an internal
XML Shema struture which can be used to validate instances. """
ret = libxml2mod.xmlSchemaParse(self._o)
if ret is None:raise parserError('xmlSchemaParse() failed')
__tmp = Schema(_obj=ret)
return __tmp | python | def schemaParse(self):
"""parse a schema definition resource and build an internal
XML Shema struture which can be used to validate instances. """
ret = libxml2mod.xmlSchemaParse(self._o)
if ret is None:raise parserError('xmlSchemaParse() failed')
__tmp = Schema(_obj=ret)
return __tmp | [
"def",
"schemaParse",
"(",
"self",
")",
":",
"ret",
"=",
"libxml2mod",
".",
"xmlSchemaParse",
"(",
"self",
".",
"_o",
")",
"if",
"ret",
"is",
"None",
":",
"raise",
"parserError",
"(",
"'xmlSchemaParse() failed'",
")",
"__tmp",
"=",
"Schema",
"(",
"_obj",
"=",
"ret",
")",
"return",
"__tmp"
] | parse a schema definition resource and build an internal
XML Shema struture which can be used to validate instances. | [
"parse",
"a",
"schema",
"definition",
"resource",
"and",
"build",
"an",
"internal",
"XML",
"Shema",
"struture",
"which",
"can",
"be",
"used",
"to",
"validate",
"instances",
"."
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6368-L6374 | train |
apple/turicreate | deps/src/libxml2-2.9.1/python/libxml2.py | Schema.SetSchema | def SetSchema(self, reader):
"""Use XSD Schema to validate the document as it is processed.
Activation is only possible before the first Read(). if
@schema is None, then Schema validation is desactivated. @
The @schema should not be freed until the reader is
deallocated or its use has been deactivated. """
if reader is None: reader__o = None
else: reader__o = reader._o
ret = libxml2mod.xmlTextReaderSetSchema(reader__o, self._o)
return ret | python | def SetSchema(self, reader):
"""Use XSD Schema to validate the document as it is processed.
Activation is only possible before the first Read(). if
@schema is None, then Schema validation is desactivated. @
The @schema should not be freed until the reader is
deallocated or its use has been deactivated. """
if reader is None: reader__o = None
else: reader__o = reader._o
ret = libxml2mod.xmlTextReaderSetSchema(reader__o, self._o)
return ret | [
"def",
"SetSchema",
"(",
"self",
",",
"reader",
")",
":",
"if",
"reader",
"is",
"None",
":",
"reader__o",
"=",
"None",
"else",
":",
"reader__o",
"=",
"reader",
".",
"_o",
"ret",
"=",
"libxml2mod",
".",
"xmlTextReaderSetSchema",
"(",
"reader__o",
",",
"self",
".",
"_o",
")",
"return",
"ret"
] | Use XSD Schema to validate the document as it is processed.
Activation is only possible before the first Read(). if
@schema is None, then Schema validation is desactivated. @
The @schema should not be freed until the reader is
deallocated or its use has been deactivated. | [
"Use",
"XSD",
"Schema",
"to",
"validate",
"the",
"document",
"as",
"it",
"is",
"processed",
".",
"Activation",
"is",
"only",
"possible",
"before",
"the",
"first",
"Read",
"()",
".",
"if"
] | 74514c3f99e25b46f22c6e02977fe3da69221c2e | https://github.com/apple/turicreate/blob/74514c3f99e25b46f22c6e02977fe3da69221c2e/deps/src/libxml2-2.9.1/python/libxml2.py#L6390-L6399 | train |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.