def getAttribute(self, attribute):
        """return attribute.
        If attribute is type and it's None, and no simple or complex content, 
        return the default type "xsd:anyType"
        """
        value = XMLSchemaComponent.getAttribute(self, attribute)
        if attribute != 'type' or value is not None:
            return value
        
        if self.content is not None:
            return None
        
        parent = self
        while 1:
            nsdict = parent.attributes[XMLSchemaComponent.xmlns]
            for k,v in nsdict.items():
                if v not in SCHEMA.XSD_LIST: continue
                return TypeDescriptionComponent((v, 'anyType'))
            
            if isinstance(parent, WSDLToolsAdapter)\
                or not hasattr(parent, '_parent'):
                break
            
            parent = parent._parent()
            
        raise SchemaError, 'failed to locate the XSD namespace'
return attribute.
        If attribute is type and it's None, and no simple or complex content, 
        return the default type "xsd:anyType"