コード例 #1
0
ファイル: visitor.py プロジェクト: bjtucker/python-zeep
    def process_ref_attribute(self, node):
        ref = qname_attr(node, 'ref')
        if ref:

            # Some wsdl's reference to xs:schema, we ignore that for now. It
            # might be better in the future to process the actual schema file
            # so that it is handled correctly
            if ref.namespace == 'http://www.w3.org/2001/XMLSchema':
                return
            return xsd_elements.RefAttribute(node.tag, ref, self.schema)
コード例 #2
0
 def process_reference(self, node, **kwargs):
     ref = qname_attr(node, 'ref')
     if not ref:
         return
     if node.tag == tags.element:
         return xsd_elements.RefElement(node.tag, ref, self.schema,
                                        **kwargs)
     if node.tag == tags.attribute:
         return xsd_elements.RefAttribute(node.tag, ref, self.schema,
                                          **kwargs)
     if node.tag == tags.group:
         return xsd_elements.RefGroup(node.tag, ref, self.schema, **kwargs)
コード例 #3
0
ファイル: visitor.py プロジェクト: Rahulk1p/python_utility
    def process_ref_attribute(self, node, array_type=None):
        ref = qname_attr(node, "ref")
        if ref:
            ref = self._create_qname(ref)

            # Some wsdl's reference to xs:schema, we ignore that for now. It
            # might be better in the future to process the actual schema file
            # so that it is handled correctly
            if ref.namespace == "http://www.w3.org/2001/XMLSchema":
                return
            return xsd_elements.RefAttribute(
                node.tag, ref, self.schema, array_type=array_type
            )