code: def fromBasicServiceEndpoint(cls, endpoint):
          
          type_uris = endpoint.matchTypes(cls.openid_type_uris)
  
          # If any Type URIs match and there is an endpoint URI
          # specified, then this is an OpenID endpoint
          if type_uris and endpoint.uri is not None:
              openid_endpoint = cls()
              openid_endpoint.parseService(
                  endpoint.yadis_url,
                  endpoint.uri,
                  endpoint.type_uris,
                  endpoint.service_element)
          else:
              openid_endpoint = None
  
          return openid_endpoint
docs: Create a new instance of this class from the endpoint
          object passed in.
  
          @return: None or OpenIDServiceEndpoint for this endpoint object